Huge iowait during checkpoint finish - Mailing list pgsql-general

From Anton Belyaev
Subject Huge iowait during checkpoint finish
Date
Msg-id d7e834b1001081016g10c92c36hbcc073c45c08d8d7@mail.gmail.com
Whole thread Raw
Responses Re: Huge iowait during checkpoint finish  (Greg Smith <greg@2ndquadrant.com>)
List pgsql-general
Hello dear list members,

I have strange problem with my new 8.4 deployment, which I never
encountered on previous 8.3 deployment.
IOwait values are extremely high exactly when Postgres finishes a checkpoint.
During the checkpoint itself (which is quite lengthy) IOwait is very low.
Why does this happen and how to fix it?

Take a look at this chart:

http://kpox.s3.amazonaws.com/cpu-day.png

The lates (rightest) IOwait peak corresponds to this log entry:

2010-01-08 18:40:36 CET LOG:  checkpoint complete: wrote 46357 buffers
(35.4%); 0 transaction log file(s) added, 0 removed, 40 recycled;
write=2502.800 s, sync=79.972 s, total=2583.184 s

IOwait peak starts about 18:39:30 and finishes at 18:40:30.
I think all the IOwait comes during sync time, which is 80 s,
according to the log entry.

Config details that might be related to the problem:

bgwriter_lru_maxpages = 0 # BG writer is off
checkpoint_segments = 45
checkpoint_timeout = 60min
checkpoint_completion_target = 0.9

I had mostly the same config with my 8.3 deployment.
But hardware is different:
Disk is software RAID-5 with 3 hard drives.

Operating system is Ubuntu 9.10 Server x64.

Thanks.
Anton.

pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Table appears on listing but can't drop it
Next
From: Adrian Klaver
Date:
Subject: Re: Table appears on listing but can't drop it