RE: Service reboot leaves postmaster.pid
От | Henshall, Stuart - WCP |
---|---|
Тема | RE: Service reboot leaves postmaster.pid |
Дата | |
Msg-id | E2870D8CE1CCD311BAF50008C71EDE8E01F745EB@MAIL_EXCHANGE обсуждение исходный текст |
Ответ на | Service reboot leaves postmaster.pid ("Henshall, Stuart - WCP" <SHenshall@westcountrypublications.co.uk>) |
Ответы |
Re: Service reboot leaves postmaster.pid
|
Список | pgsql-cygwin |
Thanks for the info, do you have a patch for ignoring SIGHUP? If not I guess it'll be time to delve into the source :). - Stuart > -----Original Message----- > From: Fred Yankowski [SMTP:fred@ontosys.com] > Sent: Thursday, June 14, 2001 4:28 PM > To: Henshall, Stuart - WCP > Cc: 'pgsql-cygwin@postgresql.org' > Subject: Re: [CYGWIN] Service reboot leaves postmaster.pid > > I've seen this same problem when using a patched version of postmaster > that directly incorporates the service-management functions also > provided by cygrunsrv. I eventually got around the problem by > changing the postmaster and postgres code to ignore the SIGHUP signal. > > SIGHUP normally causes postmaster to reread its configuration file. > Unfortunately, cygwin code linked into postmaster catches a > window-shutdown event during NT shutdown and sends a SIGHUP signal to > its own process, causing postmaster to start up its process of > rereading the config file. Something about this coincidence causes > postmaster to end up in the state where postmaster.pid is still > around after restart. I suspect that the reconfiguration process > hangs or is aborted during shutdown. > > I'm planning to submit a patch to cygrunsrv that will give it an > optional feature to notice the event of NT shutdown and send a signal > to the managed process, much as is done for a manual stop with the > '--termsig' option. This will allow us to do the equivalent of > 'pg_ctl -m fast stop' or 'pg_ctl -m immediate stop' at that time. But > my experiences with a prototype suggest that it's still necessary to > ignore SIGHUP in postmaster and postgres in that case because SIGHUP > can otherwise still interfere with shutdown. > > On Thu, Jun 14, 2001 at 01:16:00PM +0100, Henshall, Stuart - WCP wrote: > > I'm running the postmaster as a service using cygrunsrv and this > > seems to go fine apart from when I reboot it doesn't seem to remove the > > postmaster.pid file, meaning it fails to start automatically after > reboot. > > -- > Fred Yankowski fred@OntoSys.com tel: +1.630.879.1312 > Principal Consultant www.OntoSys.com fax: +1.630.879.1370 > OntoSys, Inc 38W242 Deerpath Rd, Batavia, IL 60510, USA > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://www.postgresql.org/search.mpl
В списке pgsql-cygwin по дате отправления: