From: Scott Marlowe <scott.marlowe@gmail.com>
To: david@lang.hm
Cc: Scott Carey <scott@richrelevance.com>
Cc: James Mansion <james@mansionfamily.plus.com>
Cc: Greg Smith <gsmith@gregsmith.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Effects of setting linux block device readahead size
Date: Thu, 11 Sep 2008 15:40:15 -0600
Message-ID: <dcc563d10809111440q414c5285j5bff925fad310b41@mail.gmail.com> (raw)
In-Reply-To: <alpine.DEB.1.10.0809111434240.15169@asgard.lang.hm>
References: <70c01d1d0809092353r4ae687a3ycf3d99d43a5680cf@mail.gmail.com>
<Pine.GSO.4.64.0809101023520.15181@westnet.com>
<a1ec7d000809100926w28a4a57dy7c13f2942edc57ff@mail.gmail.com>
<Pine.GSO.4.64.0809101313070.4714@westnet.com>
<48C8AACD.5090702@mansionfamily.plus.com>
<Pine.GSO.4.64.0809110150070.3993@westnet.com>
<48C97793.2070909@mansionfamily.plus.com>
<a1ec7d000809111336m8027c74u62c9a3567ee7301f@mail.gmail.com>
<alpine.DEB.1.10.0809111434240.15169@asgard.lang.hm>
On Thu, Sep 11, 2008 at 3:36 PM, <david@lang.hm> wrote:
> On Thu, 11 Sep 2008, Scott Carey wrote:
>
>> Drives have their own read-ahead in the firmware. Many can keep track of
>> 2
>> or 4 concurrent file accesses. A few can keep track of more. This also
>> plays in with the NCQ or SCSI command queuing implementation.
>>
>> Consumer drives will often read-ahead much more than server drives
>> optimized
>> for i/o per second.
>> The difference in read-ahead sensitivity between the two setups I tested
>> may
>> be due to one setup using nearline-SAS (SATA, tuned for io-per sec using
>> SAS
>> firmware) and the other used consumer SATA.
>> For example, here is one "nearline SAS" style server tuned drive versus a
>> consumer tuned one:
>>
>> http://www.storagereview.com/php/benchmark/suite_v4.php?typeID=10&testbedID=4&osID=6&rai...
>>
>> The Linux readahead setting is _definitely_ in the kernel, definitely uses
>> and fills the page cache, and from what I can gather, simply issues extra
>> I/O's to the hardware beyond the last one requested by an app in certain
>> situations. It does not make your I/O request larger, it just queues an
>> extra I/O following your request.
>
> that extra I/O will be merged with your request by the I/O scheduler code so
> that by the time it gets to the drive it will be a single request.
>
> by even if it didn't, most modern drives read the entire cylinder into their
> buffer so any additional requests to the drive will be satisfied from this
> buffer and not have to wait for the disk itself.
Generally speaking I agree, but I would still make a separate logical
partition for pg_xlog so that if the OS fills up the /var/log dir or
something, it doesn't impact the db.
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: scott.marlowe@gmail.com, david@lang.hm, scott@richrelevance.com, james@mansionfamily.plus.com, gsmith@gregsmith.com
Subject: Re: Effects of setting linux block device readahead size
In-Reply-To: <dcc563d10809111440q414c5285j5bff925fad310b41@mail.gmail.com>
References: <70c01d1d0809092353r4ae687a3ycf3d99d43a5680cf@mail.gmail.com> <Pine.GSO.4.64.0809101023520.15181@westnet.com> <a1ec7d000809100926w28a4a57dy7c13f2942edc57ff@mail.gmail.com> <Pine.GSO.4.64.0809101313070.4714@westnet.com> <48C8AACD.5090702@mansionfamily.plus.com> <Pine.GSO.4.64.0809110150070.3993@westnet.com> <48C97793.2070909@mansionfamily.plus.com> <a1ec7d000809111336m8027c74u62c9a3567ee7301f@mail.gmail.com> <alpine.DEB.1.10.0809111434240.15169@asgard.lang.hm> <dcc563d10809111440q414c5285j5bff925fad310b41@mail.gmail.com>
* 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