From: Michael Paquier <michael@paquier.xyz>
To: Justin Pryzby <pryzby@telsasoft.com>
Cc: k.jamison@fujitsu.com
Cc: pgsql-hackers@postgresql.org
Subject: Re: please update ps display for recovery checkpoint
Date: Thu, 10 Sep 2020 13:37:10 +0900
Message-ID: <20200910043710.GD2743@paquier.xyz> (raw)
In-Reply-To: <20200910020050.GB18552@telsasoft.com>
References: <20200818225238.GP17022@telsasoft.com>
<OSBPR01MB2341D2D3141FB3E4C97A0B4DEF5D0@OSBPR01MB2341.jpnprd01.prod.outlook.com>
<20200820080905.GA10353@paquier.xyz>
<20200831065244.GB6555@paquier.xyz>
<20200910020050.GB18552@telsasoft.com>
On Wed, Sep 09, 2020 at 09:00:50PM -0500, Justin Pryzby wrote:
> What would you want the checkpointer's ps to say ?
>
> Normally it just says:
> postgres 3468 3151 0 Aug27 ? 00:20:57 postgres: checkpointer
Note that CreateCheckPoint() can also be called from the startup
process if the bgwriter has not been launched once recovery finishes.
> Or do you mean do the same thing as now, but one layer lower, like:
>
> @@ -8728,6 +8725,9 @@ CreateCheckPoint(int flags)
> + if (flags & CHECKPOINT_END_OF_RECOVERY)
> + set_ps_display("recovery checkpoint");
For the use-case discussed here, that would be fine. Now the
difficult point is how much information we can actually display
without bloating ps while still have something meaningful. Showing
all the information from LogCheckpointStart() would bloat the output a
lot for example. So, thinking about that, my take would be to have ps
display the following at the beginning of CreateCheckpoint() and
CreateRestartPoint():
- restartpoint or checkpoint
- shutdown
- end-of-recovery
The output also needs to be cleared once the routines finish or if
there is a skip, of course.
--
Michael
Attachments:
[application/pgp-signature] signature.asc (832B, ../20200910043710.GD2743@paquier.xyz/2-signature.asc)
download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: michael@paquier.xyz, pryzby@telsasoft.com, k.jamison@fujitsu.com
Subject: Re: please update ps display for recovery checkpoint
In-Reply-To: <20200910043710.GD2743@paquier.xyz>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox