pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mark Mielke <mark@mark.mielke.cc>
To: Matthew <matthew@flymine.org>
Cc: pgsql-performance <pgsql-performance@postgresql.org>
Subject: Re: How to allocate 8 disks
Date: Mon, 03 Mar 2008 10:06:03 -0500
Message-ID: <47CC13DB.9000406@mark.mielke.cc> (raw)
In-Reply-To: <Pine.LNX.4.64.0803031454430.20402@aragorn.flymine.org>
References: <1204285894.11773.33.camel@franck-gusty>
	<dcc563d10802290613v482f52dr43ea95b52886de31@mail.gmail.com>
	<1204296705.11773.51.camel@franck-gusty>
	<Pine.GSO.4.64.0802291019570.28452@westnet.com>
	<47C88826.4040209@paradise.net.nz>
	<47C99B3E.4010606@emolecules.com>
	<20080301130347.0832b323@commandprompt.com>
	<47C9D05C.3040908@emolecules.com>
	<Pine.LNX.4.64.0803031206340.20402@aragorn.flymine.org>
	<47CC0FD1.7090404@mark.mielke.cc>
	<Pine.LNX.4.64.0803031454430.20402@aragorn.flymine.org>

Matthew wrote:
> On Mon, 3 Mar 2008, Mark Mielke wrote:
>> Has anybody been able to prove to themselves that RAID 0 vs RAID 1+0 
>> is faster for these sorts of loads? My understanding is that RAID 1+0 
>> *can* reduce latency for reads, but that it relies on random access, 
>> whereas RAID 0 performs best for sequential scans? Does PostgreSQL 
>> ever do enough random access to make RAID 1+0 shine?
> Theoretically the performance of RAID 0 and RAID 10 should be 
> identical for reads, both seeks and throughput, assuming you have a 
> sensible readahead and a good controller. For writes, RAID 10 needs to 
> write to multiple drives, so is slower. Whether this is true in 
> reality is another matter, as all sorts of factors come in, not least 
> how good your controller is at managing the arrangement.

I don't think your statement that they should be identical is true - 
RAID 1+0 can satisfy and given read from at least two drives. A good 
controller can satisfy half the reads from one side of the array, and 
half the reads from the other side of the array, where the first set 
does not have to wait for the second set, before continuing. To 
contrast, sequential reads of a RAID 1+0 system is almost always HALF of 
the speed of sequential reads of a RAID 0 system. The hardware 
read-ahead on the RAID 1+0 system is being wasted as even if you did 
leap from one side of the array to the other, each side ends up 
"skipping" the data served by the other side, making any caching 
ineffective.

The question I have is not whether RAID 1+0 vs RAID 0 show different 
characteristics. I know they do based upon my own analysis. My question 
is whether PostgreSQL disk access patterns for certain loads ever 
benefit from RAID 1+0, or whether RAID 1+0 is always a bad choice for 
performance-only (completely ignore reliability) loads.

Cheers,
mark

-- 
Mark Mielke <mark@mielke.cc>




view thread (14+ messages)  latest in thread

Message-ID: <47CC13DB.9000406@mark.mielke.cc>
Permalink:  ../47CC13DB.9000406@mark.mielke.cc/
Also on:    postgresql.org/message-id/47CC13DB.9000406@mark.mielke.cc

 · 

reply

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 using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: mark@mark.mielke.cc, matthew@flymine.org
  Subject: Re: How to allocate 8 disks
  In-Reply-To: <47CC13DB.9000406@mark.mielke.cc>

* 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