Re: Archiver behavior at shutdown

From: Greg Smith <gsmith(at)gregsmith(dot)com>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Archiver behavior at shutdown
Date: 2007-12-29 01:20:38
Message-ID: Pine.GSO.4.64.0712282014360.10077@westnet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

On Sat, 29 Dec 2007, Simon Riggs wrote:

> System Shutdown
> System shuts down, postmaster shuts down, archiver works furiously until
> the end trying to archive things away. Archiver gets caught half way
> through copy, so crashes, leaving archiver.pid. Subsequent startup sees
> archiver.pid, postmaster reads file to get pid, then sends signal to
> archiver to see if it is still alive, it isn't so remove archiver.pid
> and allow next archiver to start.

Isn't it possible some other process may have started with that pid if the
database server was down for long enough? In that case sending a signal
presuming it's the archive process that used to have that pid might be bad
form.

--
* Greg Smith gsmith(at)gregsmith(dot)com http://www.gregsmith.com Baltimore, MD

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2007-12-29 01:26:06 Re: minimal update
Previous Message Simon Riggs 2007-12-29 00:04:44 Re: Archiver behavior at shutdown

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2007-12-29 04:15:57 Re: Doc-patch: PAM authentication fails for local UNIX users
Previous Message Simon Riggs 2007-12-29 00:04:44 Re: Archiver behavior at shutdown