Re: Occasional Slow Commit

From: "David Rees" <drees76(at)gmail(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: Occasional Slow Commit
Date: 2008-11-06 03:25:31
Message-ID: 72dbd3150811051925n50ead40cn30354990ebb8bfb6@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Fri, Oct 31, 2008 at 4:14 PM, David Rees <drees76(at)gmail(dot)com> wrote:
> Well, I'm pretty sure the delays are not checkpoint related. None of
> the slow commits line up at all with the end of checkpoints.
>
> The period of high delays occur during the same period of time each
> week, but it's not during a particularly high load period on the
> systems.
>
> It really seems like there must be something running in the background
> that is not showing up on the system activity logs, like a background
> RAID scrub or something.

OK, I finally had a chance to dig at this problem some more, and after
futzing around with the MegaCli tools (major PITA, btw), I was able to
confirm that there is a feature called "Patrol Read" on this LSI
Megaraid SAS card which runs a weekly background read scan of the
disks looking for errors. It is during this time period that I get
lots of slow commits and transactions.

FWIW, the card identifies itself from lspci as this:

LSI Logic / Symbios Logic MegaRAID SAS
Subsystem: Intel Corporation SROMBSAS18E RAID Controller

I also found that my write cache was set to WriteThrough instead of
WriteBack, defeating the purpose of having a BBU and that my secondary
server apparently doesn't have a BBU on it. :-(

Anyway, has anyone done any benchmarking of MegaRAID SAS controllers?
I am configuring my arrays to use these settings:

Read Policy: Normal (Normal, Read ahead & Adaptive read head)
Write Policy: Writeback (Writeback, Writethrough)
Disable Writeback if bad BBU
IO Policy: Direct (Direct, Cached)
Disk Cache: Enable (Enable, Disable, Unchanged)

The only setting I'm really concerned about is the Disk Cache setting
- is it safe to assume that the controller will do the right thing
with regards to flushing the disk cache when appropriate to avoid data
loss? LSI RAID cards seem to be pretty well respected, so I'd have to
guess yes.

Thanks

Dave

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message praveen 2008-11-06 05:22:22 Re: Installation Error of postgresql-8.1.5 with perl.
Previous Message Tom Lane 2008-11-06 01:35:12 Re: Create and drop temp table in 8.3.4