From: David Lang
Subject: Re: x206-x225
Date: ,
Msg-id: Pine.LNX.4.62.0603111313290.23148@qnivq.ynat.uz
(view: Whole thread, Raw)
In response to: Re: x206-x225  (Joost Kraaijeveld)
List: pgsql-performance

Tree view

x206-x225  ("H.J. Sanders", )
 Re: x206-x225  (Richard Huxton, )
  Re: x206-x225  ("Daniel Blaisdell", )
  Re: x206-x225  (Joost Kraaijeveld, )
   Re: x206-x225  (David Lang, )
    Re: x206-x225  (Joost Kraaijeveld, )
     Re: x206-x225  (PFC, )
      Re: x206-x225  (Joost Kraaijeveld, )
       Re: x206-x225  (Tom Lane, )
        Re: x206-x225  (Joost Kraaijeveld, )
     Re: x206-x225  (David Lang, )
    Re: x206-x225  ("Jim C. Nasby", )
     Re: x206-x225  (Richard Huxton, )
      Re: x206-x225  ("Jim C. Nasby", )
       Re: x206-x225  (Richard Huxton, )

On Sat, 11 Mar 2006, Joost Kraaijeveld wrote:

> Date: Sat, 11 Mar 2006 09:17:09 +0100
> From: Joost Kraaijeveld <>
> To: David Lang <>
> Cc: Richard Huxton <>, 
> Subject: Re: [PERFORM] x206-x225
>
> On Fri, 2006-03-10 at 23:57 -0800, David Lang wrote:
>> On Sat, 11 Mar 2006, Joost Kraaijeveld wrote:
>>
>>> On Fri, 2006-03-10 at 13:40 +0000, Richard Huxton wrote:
>>>> Your ATA disk is lying about disk caching being turned off. Assuming
>>>> each insert is in a separate transaction, then it's not going to do
>>>> 10,000 / 6 = 1667 transactions/sec - that's faster than it's rotational
>>>> speed.
>>> Could you explain the calculation? Why should the number of transactions
>>> be related to the rotational speed of the disk, without saying anything
>>> about the number of bytes per rotation?
>>
>> each transaction requires a sync to the disk, a sync requires a real
>> write (which you then wait for), so you can only do one transaction per
>> rotation.
> Not according to a conversation I had with Western Digital about the
> write performance of my own SATA disks. What I understand from their
> explanation their disk are limited by the MB/sec and not by the number
> of writes/second, e.g. I could write 50 MB/sec *in 1 bit/write* on my
> disk. This would suggest that the maximum transactions of my disk
> (overhead of OS and PostgreSQL ignored) would be 50MB / (transaction
> size in MB) per second. Or am I missing something (what would not
> surprise me, as I do not understand the perforance of my system at
> all ;-))?

but if you do a 1 bit write, and wait for it to complete, and then do
another 1 bit write that belongs on disk immediatly after the first one
(and wait for it to complete) you have to wait until the disk rotates to
the point that it can make the write before it's really safe on disk.

so you can do one transaction in less then one rotation, but if you do 50
transactions you must wait at least 49 (and a fraction) roatations.

if the disk cache is turned on then you don't have to wait for this, but
you also will loose the data if you loose power so it's really not safe.

David Lang


pgsql-performance by date:

From: Josh Berkus
Date:
Subject: Re: Postgres and Ingres R3 / SAN
From: "Phadnis"
Date:
Subject: help needed asap....