Skip site navigation (1) Skip section navigation (2)

Re: moving postgresql.conf: pg_ctl can't find postmaster.pid anymore

From: Ludo Smissaert <ludo(at)ludikidee(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: moving postgresql.conf: pg_ctl can't find postmaster.pid anymore
Date: 2009-11-02 15:43:34
Message-ID: 4AEEFE26.30201@ludikidee.com (view raw or flat)
Thread:
Lists: pgsql-admin
Tom Lane wrote:
> Ludo Smissaert <ludo(at)ludikidee(dot)com> writes:
>> Both methods works fine on server startup, but the first method gives
>> problems when stopping the server with pg_ctl.
> 
> Yeah, pg_ctl is far too stupid to cope with such things --- it expects
> that PGDATA points at the data directory.  Short of teaching it to parse
> the config file it's not clear what we could do about that.

Thanks. Summarizing:

$ ls /etc/postgresql
postgresql.conf pg_hba.conf pg_ident.conf

$ pg_ctl -D /var/postgresql/data -o "-D /etc/postgresql" start -l ...

... server started

$ pg_ctl -D /var/postgresql/data -o "-D /etc/postgresql" stop -m fast

works for the first method, and for the second:

$ pg_ctl -D /var/postgresql/data/ \
   -o "-c config_file='/etc/postgresql/postgresql.conf'" -l ... start

and for stopping the same.

Have a nice day/night,
	
Ludo

In response to

pgsql-admin by date

Next:From: wstrzalkaDate: 2009-11-02 15:54:29
Subject: Re: How can I know ./configure options for binary installation
Previous:From: wstrzalkaDate: 2009-11-02 15:33:11
Subject: Re: How can I know ./configure options for binary installation

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group