Обсуждение: 9.6 write time
Hi,
I am looking at a postgres 9.6 on rh7
I see that checkpoint_write_time is huge which looks quite strange as the average amount of data written is not that big.
For example in 5:30 hours today, data from pg_stat_bgwriter view, comparing values at 11AM and 4h30PM :
checkpoint_write_time 6986324
buffers_checkpoint 182447
so, to my understanding, it takes almost 2 hours to write 1.6 GB of data.
Can someone either correct my understanding, or shed some light on what can cause this ??
thanks,
Marc Millas <marc.millas@mokadb.com> writes: > I am looking at a postgres 9.6 on rh7 > I see that checkpoint_write_time is huge which looks quite strange as the > average amount of data written is not that big. checkpoint_write_time is not the amount of time spent doing I/O; it's the elapsed wall-clock time in the write phase. If the I/O is being throttled because of an un-aggressive checkpoint completion target, it could be a lot more than the actual I/O time. What have you got your checkpoint parameters set to? regards, tom lane
On Tue, Dec 28, 2021 at 6:46 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
Marc Millas <marc.millas@mokadb.com> writes:
> I am looking at a postgres 9.6 on rh7
> I see that checkpoint_write_time is huge which looks quite strange as the
> average amount of data written is not that big.
checkpoint_write_time is not the amount of time spent doing I/O;
it's the elapsed wall-clock time in the write phase. If the I/O
is being throttled because of an un-aggressive checkpoint completion
target, it could be a lot more than the actual I/O time. What have
you got your checkpoint parameters set to?
regards, tom lane
Marc Millas <marc.millas@mokadb.com> writes: > checkpoint completion target is 0.9 checkpoint_timeout is the more interesting number here. regards, tom lane
Default ie. 5 minutes
Le mar. 28 déc. 2021 à 19:34, Tom Lane <tgl@sss.pgh.pa.us> a écrit :
Marc Millas <marc.millas@mokadb.com> writes:
> checkpoint completion target is 0.9
checkpoint_timeout is the more interesting number here.
regards, tom lane