Tuning Postgresql on FreeBSD 5.1

Sean Chittenden sean at chittenden.org
Mon Aug 25 21:20:47 PDT 2003


> > while still maintaining reasonable file system performance (ext2 is
> > faster than ext3 by a wide margin, but ext2 is _not_ a reliable FS).
> 
> > > #fsync = true
> > 
> > Change this to false.
> 
> This is a funny thing to suggest after the filesystem comment.

:) Did you enjoy that?  :) I should clarify that piece of "advice"
though.

If you're _sure_ power isn't going to fail (using a UPS) and make
regular backups (standard operating procedure), then fsync = false
can be a good thing in terms of performance (roughly speaking, it
doubles performance of any write/update operation).  A disk failure is
a disk failure and there is no substitute for RAID.  Leaving stability
in the OS and PostgreSQL... this is a FreeBSD mailing list, stability
goes without saying.  :) That said though, if you're unable to stomach
the possibility of possibly loosing data when one of the above fails,
keep fsync = true.  If, however, you have mitigated the risks to
levels that your business/operation is comfortable with (your data
center is on generators, your DB systems have UPSs, are using RAID,
and make frequent backups), then I would set fsync = false for most
noncritical apps (non-financial, non-medical).

-sc

-- 
Sean Chittenden
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 202 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-performance/attachments/20030825/4f219139/attachment.bin


More information about the freebsd-performance mailing list