Linux – Performance of RAID 5 with mdadm

advanced-formatlinuxperformanceraidsoftware-raid

I have set up a software-raid 5 with mdadm on a 1.3 GHz AMD Neo 36L dual core machine using 3 1.5 TB Seagate Barracude Green drives (4k sectors). The chunk size of the raid is 512 KB. On top of the raid there is one lvm volume formatted with ext4 (Block size=4096, Stride=128 blocks, Stripe width=256 block). Both the raid and the lvm are aligned properly. When running bonnie++ I get the following results:

VVersion  1.96       ------Sequential Output------ --Sequential Input- --Random-
Concurrency   1     -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
               Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP  /sec %CP
                4G   362  97 69738  15 52826  16  1732  94 248671  31 539.0  32
Latency             92293us    3276ms    4274ms   22450us   38749us     111ms

Can anybody tell me if this performance is what I can expect from my setup? Especially the sequential output and the per-chr-access seems a bit too slow to me.

Best Answer

Yup. You can see from the bonnie output that its CPU bound (on what are relatively slow cores), as one would expect with software raid. The calculation of where to store data in a RAID 5 array is something better left to a dedicated XOR ASIC not a CPU. More info on that here:

http://www.dell.com/content/topics/global.aspx/power/en/ps2q03_luse?c=us&l=en

If performance is a concern you'd be way better off throwing down the cash for a 4th drive and doing RAID 10.

Related Question