From owner-freebsd-questions@FreeBSD.ORG Wed Mar 3 16:54:16 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5D2B716A4CE for ; Wed, 3 Mar 2004 16:54:16 -0800 (PST) Received: from gateway.home.ricin.net (cp464173-a.dbsch1.nb.home.nl [212.204.145.167]) by mx1.FreeBSD.org (Postfix) with ESMTP id B3A1543D39 for ; Wed, 3 Mar 2004 16:54:15 -0800 (PST) (envelope-from danny@ricin.com) Received: from workstation.home.ricin.net (workstation.home.ricin.net [172.16.32.66]) by gateway.home.ricin.net (Postfix) with ESMTP id BDE5C24D09 for ; Thu, 4 Mar 2004 01:54:14 +0100 (CET) From: Danny Pansters To: freebsd-questions@freebsd.org Date: Thu, 4 Mar 2004 01:54:14 +0100 User-Agent: KMail/1.6 References: <000601c4016d$cdb571e0$0a06a8c0@rekon> In-Reply-To: <000601c4016d$cdb571e0$0a06a8c0@rekon> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200403040154.14373.danny@ricin.com> Subject: RAID1 vs RAID5 [ was Re: 1 processor vs. 2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: danny@ricin.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Mar 2004 00:54:16 -0000 On Wednesday 03 March 2004 23:20, Reko Turja wrote: > > RAID-1 will be about 50% faster than RAID-5 doing reads regardless of > > size, and will also be *much* faster doing small writes-- by a factor > > of 4, perhaps. > > The abovementioned figures seem more like comparing RAID-0 (striping) > to RAID-5 (striping with ECC) than RAID-5 to RAID-1 (mirroring). In > my experience mirroring is always the slowest RAID in terms of > retrieving data, writes might be quite comparable with RAID-1 and > RAID-5 though. That makes sense. With more disks you have more disk heads to read with. So statistically and theoreticaly RAID1 compares to no RAID at all as 2x read speed, 1x write speed (it needs to be written twice but through two heads on two drives seperately and assume they react and move at the same speed). Take a RAID5 with 5 drives that would in terms of data resiliance compare with a RAID1 of 3 drives at best (right?). Change the above numbers for a RAID1 to 3 drives and you have a 3x read and a 1x write speed. With the hypothetical RAID5 as above we have 3x read and 1x write speed for data plus 2x read and 1x write for parity info which will usually be smaller in size. Let's assume they're of comparative sizes, to make things simple, then we have 5/2x reads and 1x writes to compare. Therefore reads are poorer and there's more overall CPU/RAM overhead (with hardware RAID this depends on how you look at it, all RAID is essentially software RAID be it on your PC on on a chip inside it). This simplified approach would indicate that 6 or more drives might be a nice thing for RAID5. I thought this over more often when thinking of how to deploy vinum and recently about whether to buy a RAID1 (cheap) or RAID5 ($$) ATA card and always thought this was the correct way to consider performance (resilliance is another thing). Do people agree on this? I often wondered because most of the meta-information around doesn't go into specifics like this. I think the above scenario applies only when there's a reasonable amount of I/O going on concurrently rather than if nothing ever happens but that lone write or read. That would change the assumption that more heads == more reads && equal writes (not rights ;-). Sorry to divert a bit. What can I say, I like having a (somewhat informed) discussion... And this is still relevant to OP. Greets, Dan