Log notice that checkpoint is to be written on shutdown

From: Michael Banck <michael(dot)banck(at)credativ(dot)de>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Log notice that checkpoint is to be written on shutdown
Date: 2014-10-02 13:21:48
Message-ID: 1412256108.5984.23.camel@hartree.muc.credativ.lan
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

we have seen repeatedly that users can be confused about why PostgreSQL
is not shutting down even though they requested it. Usually, this is
because `log_checkpoints' is not enabled and the final checkpoint is
being written, delaying shutdown. As no message besides "shutting down"
is written to the server log in this case, we even had users believing
the server was hanging and pondering killing it manually.

In order to alert those users that a checkpoint is being written, I
propose to add a log message "waiting for checkpoint ..." on shutdown,
even if log_checkpoints is disabled, as this particular checkpoint might
be important information.

I've attached a trivial patch for this, should it be added to the next
commitfest?

Cheers,

Michael

--
Michael Banck
Projektleiter / Berater
Tel.: +49 (2161) 4643-171
Fax: +49 (2161) 4643-100
Email: michael(dot)banck(at)credativ(dot)de

credativ GmbH, HRB Mönchengladbach 12080
USt-ID-Nummer: DE204566209
Hohenzollernstr. 133, 41061 Mönchengladbach
Geschäftsführung: Dr. Michael Meskes, Jörg Folz, Sascha Heuer

Attachment Content-Type Size
shutdown_checkpoint_notice.patch text/x-patch 827 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2014-10-02 13:48:01 Re: NEXT VALUE FOR <sequence>
Previous Message Stephen Frost 2014-10-02 13:11:19 Re: pg_background (and more parallelism infrastructure patches)