Re: How to allocate 8 disks

From: Craig James <craig_james(at)emolecules(dot)com>
To: "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>
Cc: pgsql-performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: How to allocate 8 disks
Date: 2008-03-01 21:53:32
Message-ID: 47C9D05C.3040908@emolecules.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Joshua D. Drake wrote:
> On Sat, 01 Mar 2008 10:06:54 -0800
> Craig James <craig_james(at)emolecules(dot)com> wrote:
>
>> We're upgrading to a medium-sized server, a Dell PowerEdge 2950,
>> dual-quad CPU's and 8 GB memory. This box can hold at most 8 disks
>> (10K SCSI 2.5" 146 GB drives) and has Dell's Perc 6/i RAID controller.
>>
>> I'm thinking of this:
>>
>> 6 disks RAID 1+0 Postgres data
>> 1 disk WAL
>> 1 disk Linux
>>
>> I've often seen RAID 1 recommended for the WAL. Is that strictly for
>> reliability, or is there a performance advantage to RAID 1 for the
>> WAL?
>>
>> It seems to me separating the OS and WAL on two disks is better than
>> making a single RAID 1 and sharing it, from a performance point of
>> view.
>
> This scares me... You lose WAL you are a goner. Combine your OS and
> WAL into a RAID 1.

Right, I do understand that, but reliability is not a top priority in this system. The database will be replicated, and can be reproduced from the raw data. It's not an accounting system, it finds scientific results. That's not to say I *won't* take your advice, we may in fact combine the OS and WAL on one disk. Reliability is a good thing, but I need to know all of the tradeoffs, so that I can weigh performance, reliability, and cost and make the right choice.

So my question still stands: From a strictly performance point of view, would it be better to separate the OS and the WAL onto two disks? Is there any performance advantage to RAID 1? My understanding is that RAID 1 can give 2x seek performance during read, but no advantage during write. For the WAL, it seems to me that RAID 1 has no performance benefits, so separating the WAL and OS seems like a peformance advantage.

Another option would be:

4 disks RAID 1+0 Postgres data
2 disks RAID 1 WAL
1 disk Linux
1 disk spare

This would give us reliability, but I think the performance would be considerably worse, since the primary Postgres data would come from 4 disks instead of six.

I guess we could also consider:

4 disks RAID 1+0 Postgres data
4 disks RAID 1+0 WAL and Linux

Or even

8 disks RAID 1+0 Everything

This is a dedicated system and does nothing but Apache/Postgres, so the OS should get very little traffic. But if that's the case, I guess you could argue that your suggestion of combining OS and WAL on a 2-disk RAID 1 would be the way to go, since the OS activity wouldn't affect the WAL very much.

I suppose the thing to do is get the system, and run bonnie on various configurations. I've never run bonnie before -- can I get some useful results without a huge learning curve?

Thanks,
Craig

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Scott Marlowe 2008-03-01 22:30:20 Re: How to allocate 8 disks
Previous Message Joshua D. Drake 2008-03-01 21:03:47 Re: How to allocate 8 disks