Re: Multiple disks: RAID 5 or PG Cluster

From: Jacques Caron <jc(at)directinfos(dot)com>
To: PFC <lists(at)boutiquenumerique(dot)com>
Cc: mudfoot(at)rawbw(dot)com, pgsql-performance(at)postgresql(dot)org
Subject: Re: Multiple disks: RAID 5 or PG Cluster
Date: 2005-06-18 16:24:21
Message-ID: 6.2.0.14.0.20050618181239.0446d7a8@pop.interactivemediafactory.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Hi,

At 18:00 18/06/2005, PFC wrote:
> I don't know what I'm talking about, but wouldn't mirorring be
> faster
>than striping for random reads like you often get on a database ? (ie. the
>reads can be dispatched to any disk) ? (or course, not for writes, but if
>you won't use fsync, random writes should be reduced no ?)

Roughly, for random reads, the performance (in terms of operations/s)
compared to a single disk setup, with N being the number of drives, is:

RAID 0 (striping):
- read = N
- write = N
- capacity = N
- redundancy = 0

RAID 1 (mirroring, N=2):
- read = N
- write = 1
- capacity = 1
- redundancy = 1

RAID 5 (striping + parity, N>=3)
- read = N-1
- write = 1/2
- capacity = N-1
- redundancy = 1

RAID 10 (mirroring + striping, N=2n, N>=4)
- read = N
- write = N/2
- capacity = N/2
- redundancy < N/2

So depending on your app, i.e. your read/write ratio, how much data can be
cached, whether the data is important or not, how much data you have, etc,
one or the other option might be better.

Jacques.

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Yves Vindevogel 2005-06-18 16:42:27 Fwd: Multiple disks: RAID 5 or PG Cluster
Previous Message PFC 2005-06-18 16:00:14 Re: Multiple disks: RAID 5 or PG Cluster