Re: win32 performance - fsync question

From: Evgeny Rodichev <er(at)sai(dot)msu(dot)su>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Magnus Hagander <mha(at)sollentuna(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: win32 performance - fsync question
Date: 2005-02-17 23:56:02
Message-ID: Pine.GSO.4.62.0502180235250.347@ra.sai.msu.su
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 17 Feb 2005, Tom Lane wrote:

> Evgeny Rodichev <er(at)sai(dot)msu(dot)su> writes:
>>> Any claimed TPS rate exceeding your disk drive's rotation rate is a
>>> red flag.
>
>> Write cache is enabled under Linux by default all the time I make deal
>> with it (since 1993).
>
> You're playing with fire.

Yes. I'm lucky in this play :)

More seriously, we (with Oleg Bartunov) investigated many platforms/OS
for commercial, scientific and other applications during past 10-12
years. I suppose, virtually all excluding modern mainframes.

For reliability Linux + PostreSQL was found the best one (including the
environment with very frequent unexpected power-off, as at some astronomical
observatories at high mountains).

Hence, I'm lucky :)

>
>> fsync() really works fine as I switch off my notebook everyday 2-3 times,
>> and never had any data loss :)
>
> Given that it's a notebook, it's possible that the hardware is smart
> enough not to power down the disk until the disk is done writing
> everything it's cached. Do you care to try some experiments with
> pulling out the battery while Postgres is busy making updates?

Yes, you are exactly right. All modern HDDs (not entry level ones) has
a huge cache (at device, not at controller), and provide the safe hardware
flush of cache *after* power off (thanks capacitors). My HDD has 16MB cache,
and it is the reason for excellent performance.

Regards,
E.R.
_________________________________________________________________________
Evgeny Rodichev Sternberg Astronomical Institute
email: er(at)sai(dot)msu(dot)su Moscow State University
Phone: 007 (095) 939 2383
Fax: 007 (095) 932 8841 http://www.sai.msu.su/~er

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Evgeny Rodichev 2005-02-18 00:16:09 Re: win32 performance - fsync question
Previous Message Oliver Jowett 2005-02-17 23:41:54 Re: win32 performance - fsync question