Search Postgresql Archives

Re: Postgres: Packaging & Server Startup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



CM J wrote:
> Hi,
> 
> I don't have multiple postgres installed.

Hmm. OK.

> Anyway, tried your suggestion
> to use the full path name and here is what i get:
> 
> D:\pgsql\bin>D:\pgsql\bin\pg_ctl.exe -U postgres -P <mypasswd> -w start
> -D:\pgsql\data

You've got a typo here - the "-D" has run into "D:\..."

> pg_ctl: could not open PID file ":/pgsql/data/postmaster.pid": Invalid
> argument
> 
>        There is no data directory created by default (i used
> no-installer-zip file to install postgres), so i went ahead and created a
> dummy data directory which gave the same result as above. Any suggestions ??

It's probably worth checking the permissions on that directory, but I
don't think it's the problem here. You have run "initdb" on that
directory though, haven't you? If not, do that before worrying about the
rest of this email.

>>> pg_ctl.exe -U postgres -P <mypasswd>  -w start -D D:\pgsql\data
>>>
>>>         However, i get the following error message:
>>>
>>> waiting for server to start...FATAL:  postgres: could not locate matching
>>> postgres executable

Reading the error message and searching the source-code for it (always
worth having a copy of the source, even if you don't read "C") I found
that the error message isn't being produced by pg_ctl. It's being
produced by "postgres" - the backend itself.

It's checking that it's version number matches the version number
reported by running /path/to/my/dir/postgres.exe -V (grab the source and
have a look in port/exec.c at about line 395).

Now, that means one of three things:
1. It can't reach the "current directory" (permissions)
2. It can't run postgres (permissions)
3. The version-string is incorrect.

I don't see how #2 is possible (pg_ctl has started postgres.exe fine) so
that leaves #1 or #3. The third is easy to check run "postgres.exe -V"
yourself and see what it says.

-- 
  Richard Huxton
  Archonet Ltd

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux