Linux RAID best practices

From Strugglers
Revision as of 20:59, 15 January 2006 by Andy (Talk | contribs)

Jump to: navigation, search

This article is about the various issues surrounding RAID on Linux.

Hardware or software?

Performance

Given a decent CPU in your host machine, software RAID using MD will most likely be faster than a hardware RAID card. However if your host experiences frequent high CPU loading then this can degrade performance system-wide. Hardware RAID cards have their own CPU so can continue to provide decent performance regardless of the load of the host system.

More expensive RAID cards include a small amount of battery-backed storage. This increases performance as the card can inform the operating system that the write is complete as soon as it hits its memory.

Reliability

I haven't personally had any issues with Linux software RAID, and use it a lot. Do bear in mind that MD is still under development and it is possible, though unlikely, that a bug could be introduced.

Since MD runs as part of the Linux kernel, you need a working kernel to have working RAID. If you break your kernel and your machine does not boot then you will need a rescue disk that supports MD in order to fix things.

Hardware RAID is presented to the BIOS as a normal disk and the better cards allow configuration from the BIOS.

If there is a serious problem with a hardware RAID card then you must rely on the vendor to help you get your data. If changing RAID cards then you need to restore from backup unless changing only between cards from the same vendor and there is guaranteed compatability. By contrast you can usually take disks running under MD and install them into another Linux box running MD, in any order, and still have array(s) assemble correctly.

Levels

For a decent explanation of what the different RAID levels are, try the Wikipedia article.