large inserts and fsync

From: Aaron Burnett <aburnett(at)bzzagent(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: large inserts and fsync
Date: 2008-09-05 13:16:41
Message-ID: C4E6A979.3681%aburnett@bzzagent.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


Forgive me if this is a many-times rehashed topic. I¹m very new to
postgresql, most of my background is in Oracle.

Running postgres 8.2.5 with one master and three slaves (using slony)

For an upcoming release there is a 16 million row insert that on our test
cluster takes about 2.5 hours to complete with all indices dropped
beforehand.

If I turn off fsync, it completes in under 10 minutes.

Other than the protection that fsync will allow me should there be a crash
in the middle of such a process, my thinking was to turn off fsync for this
part of the release, get the insert done, then restart fsync once the insert
is complete.

Am I opening myself up to any dangers that aren¹t obvious by doing this? Any
advice to the contrary? And of course, if I am out of my mind for doing
this, please let me know.

Thanks in advance

Aaron

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Filip Rembiałkowski 2008-09-05 15:04:00 Re: a performence question
Previous Message Reid Thompson 2008-09-05 11:48:02 Re: Cannot connect to server