From: Bruce Momjian <bruce@momjian.us>
To: Craig James <craig_james@emolecules.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: David Rees <drees76@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Occasional giant spikes in CPU load
Date: Wed, 14 Apr 2010 17:58:33 -0400 (EDT)
Message-ID: <201004142158.o3ELwXL09621@momjian.us> (raw)
In-Reply-To: <4BBD3A17.90209@emolecules.com>
Craig James wrote:
> On 4/7/10 5:47 PM, Robert Haas wrote:
> > On Wed, Apr 7, 2010 at 6:56 PM, David Rees<drees76@gmail.com> wrote:
> >>> max_fsm_pages = 16000000
> >>> max_fsm_relations = 625000
> >>> synchronous_commit = off
> >>
> >> You are playing with fire here. You should never turn this off unless
> >> you do not care if your data becomes irrecoverably corrupted.
> >
> > That is not correct. Turning off synchronous_commit is sensible if
> > you don't mind losing the last few transactions on a crash. What will
> > corrupt your database is if you turn off fsync.
>
> A bit off the original topic, but ...
>
> I set it this way because I was advised that with a battery-backed
> RAID controller, this was a safe setting. Is that not the case?
To get good performance, you can either get a battery-backed RAID
controller or risk losing a few transaction with synchronous_commit =
off. If you already have a battery-backed RAID controller, there is
little benefit to turning synchronous_commit off, and some major
downsides (possible data loss).
--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-performance@postgresql.org
Cc: bruce@momjian.us, craig_james@emolecules.com, robertmhaas@gmail.com, drees76@gmail.com
Subject: Re: Occasional giant spikes in CPU load
In-Reply-To: <201004142158.o3ELwXL09621@momjian.us>
References: <4BBD3A17.90209@emolecules.com> <201004142158.o3ELwXL09621@momjian.us>
* 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