Skip site navigation (1) Skip section navigation (2)

Re: SATA drives performance

From: Richard Neill <rn214(at)cam(dot)ac(dot)uk>
To: PostgreSQL Performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: SATA drives performance
Date: 2009-12-24 17:12:40
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-performance
Greg Smith wrote:
> Richard Neill wrote:
>> 3. RAID 0 is twice as unreliable as no raid. I'd recommend using RAID 1
>> intead. If you use the Linux software mdraid, remote admin is easy.
> The main thing to be wary of with Linux software RAID-1 is that you 
> configure things so that both drives are capable of booting the system.  
> It's easy to mirror the data, but not the boot loader and the like.

Good point. I actually did this on a home PC (2 disks in RAID 1). The
solution is simple: just "grub-install /dev/sda; grub-install /dev/sdb"
and that's all you have to do, provided that /boot is on the raid array.

Of course, with a server machine, it's nearly impossible to use mdadm
raid: you are usually compelled to use a hardware raid card. Those are a
pain, and less configurable, but it will take care of the bootloader issue.

Obviously, test it both ways.

>> 7. If you have 3 equal disks, try doing some experiments. My inclination
>> would be to set them all up with ext4...
> I have yet to yet a single positive thing about using ext4 for 
> PostgreSQL.  Stick with ext3, where the problems you might run into are 
> at least well understood and performance is predictable.

I did some measurements on fdatasync() performance for ext2,ext3,ext4.

I found ext2 was fastest, ext4 was twice as slow as ext2, and ext3 was
about 5 times slower than ext2. Also, ext4 is doesn't having an
appallingly slow fsck.

We've had pretty good results from ext4.


In response to


pgsql-performance by date

Next:From: Jeremy HarrisDate: 2009-12-24 17:28:23
Subject: Re: SATA drives performance
Previous:From: Greg SmithDate: 2009-12-24 17:05:42
Subject: Re: SATA drives performance

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group