Re: Revised patch for fixing archiver shutdown behavior - Mailing list pgsql-patches

From Alvaro Herrera
Subject Re: Revised patch for fixing archiver shutdown behavior
Date
Msg-id 20080110003020.GC22548@alvh.no-ip.org
Whole thread Raw
In response to Revised patch for fixing archiver shutdown behavior  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Revised patch for fixing archiver shutdown behavior
List pgsql-patches
Tom Lane wrote:
> The attached patch fixes archiver shutdown in what seems to me to be
> a sane way.  With the patch, we send SIGQUIT to the archiver only for
> panic-stop situations (backend crash or immediate-mode shutdown).
> This is important because the postmaster is coded to send SIGQUIT
> to the entire process group, meaning we'd also ungracefully terminate
> any currently-running archive command, which does not seem like a good
> idea for normal exit.  Instead, the shutdown protocol is that *after*
> the bgwriter has quit, we send SIGUSR1 (ie, the normal archiver wakeup
> signal) to the archiver.  This ensures that it will do a normal
> archiving cycle after the last possible creation of WAL entries.

Hmm, so the postmaster is gone during the last archiving cycle?  What
about syslogger?  Is the archiver able to log stuff in the last cycle?

The comment in line 2180 seems a bit bogus ...?

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Revised patch for fixing archiver shutdown behavior
Next
From: Tom Lane
Date:
Subject: Re: Revised patch for fixing archiver shutdown behavior