Re: backend hangs at immediate shutdown (Re: Back-branch update releases coming in a couple weeks) - Mailing list pgsql-hackers

From Hitoshi Harada
Subject Re: backend hangs at immediate shutdown (Re: Back-branch update releases coming in a couple weeks)
Date
Msg-id CAP7QgmnSW+ktWRnixXrt4g958NjqjR7Q1XNYDObmJp27npjW=Q@mail.gmail.com
Whole thread Raw
In response to Re: backend hangs at immediate shutdown (Re: Back-branch update releases coming in a couple weeks)  ("MauMau" <maumau307@gmail.com>)
List pgsql-hackers



On Thu, Jun 20, 2013 at 3:40 PM, MauMau <maumau307@gmail.com> wrote: 
Here, "reliable" means that the database server is certainly shut
down when pg_ctl returns, not telling a lie that "I shut down the
server processes for you, so you do not have to be worried that some
postgres process might still remain and write to disk".  I suppose
reliable shutdown is crucial especially in HA cluster.  If pg_ctl
stop -mi gets stuck forever when there is an unkillable process (in
what situations does this happen? OS bug, or NFS hard mount?), I
think the DBA has to notice this situation from the unfinished
pg_ctl, investigate the cause, and take corrective action.

So you're suggesting that keeping postmaster up is a useful sign that
the shutdown is not going well?  I'm not really sure about this.  What
do others think?

I think you are right, and there is no harm in leaving postgres processes in unkillable state.  I'd like to leave the decision to you and/or others.


+1 for leaving processes, not waiting for long (or possibly forever, remember not all people are running postgres on such cluster ware).  I'm sure some users rely on the current behavior of immediate shutdown.  If someone wants to ensure processes are finished when pg_ctl returns, is it fast shutdown, not immediate shutdown?  To me the current immediate shutdown is reliable, in that it without doubt returns control back to terminal, after killing postmaster at least.
 
Thanks,
--
Hitoshi Harada

pgsql-hackers by date:

Previous
From: Dean Rasheed
Date:
Subject: Re: Review: UNNEST (and other functions) WITH ORDINALITY
Next
From: Dean Rasheed
Date:
Subject: Re: Review: UNNEST (and other functions) WITH ORDINALITY