From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Greg Stark <stark(at)mit(dot)edu> |
Cc: | Peter Eisentraut <peter_e(at)gmx(dot)net>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, "Mr(dot) Aaron W(dot) Swenson" <titanofold(at)gentoo(dot)org>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Bug with pg_ctl -w/wait and config-only directories |
Date: | 2011-10-04 21:18:05 |
Message-ID: | 201110042118.p94LI5k05974@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Greg Stark wrote:
> On Tue, Oct 4, 2011 at 2:42 PM, Bruce Momjian <bruce(at)momjian(dot)us> wrote:
> > Because pg_ctl 9.1 will read postmaster.pid and find the port number,
> > socket location, and listen host for wait mode --- I doubt someone would
> > do that work in a script.
>
> But this is the whole difference between them. An init.d script
> *shouldn't* do all that. It *knows* how the system daemon is
> configured and should only be used to start and stop that process. And
> it can't wait, it's not an interactive tool, it has to implement the
> standard init.d interface.
>
> An interactive tool can dwim automatically but that isn't appropriate
> for a startup script. A startupt script should always do the same
> thing exactly and do that based on the OS policy, not based on
> inspecting what programs are actually running on the machine.
I agree, except the Gentoo script does exactly that --- wait for
completion using pg_ctl -w.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ It's impossible for everything to be true. +
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2011-10-04 21:49:07 | Re: Bug with pg_ctl -w/wait and config-only directories |
Previous Message | Tom Lane | 2011-10-04 20:36:29 | Re: Does pg_settings.sourcefile/sourceline work on Windows? |