Emit "checkpoint skipped because system is idle" message at LOG level if log_checkpoints is set

From: Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Emit "checkpoint skipped because system is idle" message at LOG level if log_checkpoints is set
Date: 2022-01-05 04:54:25
Message-ID: CALj2ACX9LPadCNACDZ3JykDT-6sfPrPchXTLyNHP3cbwyJYjsg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

Postgres server emits a message at DEBUG1 level when it skips a
checkpoint. At times, developers might be surprised after figuring out
from server logs that there were no checkpoints happening at all
during a certain period of time when DEBUG1 messages aren't captured.
How about emitting the message at LOG level if log_checkpoints is set?
Patch attached.

Thoughts?

Regards,
Bharath Rupireddy.

Attachment Content-Type Size
v1-0001-Emit-checkpoint-skipped-message-at-LOG-level.patch application/octet-stream 902 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alexander Lakhin 2022-01-05 05:00:00 Re: Index-only scan for btree_gist turns bpchar to char
Previous Message Andrey V. Lepikhov 2022-01-05 04:37:33 Re: pg_stat_statements and "IN" conditions