2

"Redundant Array of Independent Disks "RAID" is a method of using multiple disks to provide different balances of increasing data reliability and/or increasing input/output performance, depending on the RAID level being used."

The main problem is I can't imagine what this would look like. Could someone explain with a practical example?

1
  • The best depends heavily on your needs. Aug 18, 2012 at 14:01

6 Answers 6

3

RAID is simply put a way to make two or more disks act as one - with some benefits:

RAID 0 is making the disks act as one physical disk. this means that the controller can split the files over both disks when writing and reading, which can improve the performance quite a bit. This also means that if one of your disks fail, the data on both of them are likely lost.

RAID 1 is mirroring; you need two identical disks, and you only get the space of one (two 1TB disks in RAID 1 only gives a 1 TB disk). The benefit here is that this enables the system to read from two different disks at the same time, even though write times might suffer a bit. Another benefit might be that if one disk fails, the data is mirrored on the other disk, but it is not completely without risks (see wikipedia)

Higher raid levels are possible, but you should read about them on wikipedia.

2

First of all RAID is not a substitute for a good backup strategy.

There are basically two concepts one uses distributed copies (RIAD 1 - also called mirroring, data is organized in blocks and every drive contains the same blocks) and another striping (RAID 0 - mostly done at block level with block level striping).

One advantage of mirroring mode (two or more drives holding the same data) would be, that you can easily get snapshots and backups from the system by just removing the drive from the system and archiving that drive. This seems like a poor mans backup and snapshot strategy since there are more sophisticated mechanisms available nowadays but that's still a nice example for using redundancy.

Another benefit of mirroring is that you can execute as many read operations as you have drives in the array at the same time. Linux software RAID has that capability, but for writing every drive has to write the same data.

With striping data is organized in stripes that cover two or more drives, so that workload can be distributed across multiple drives. The array is faster but offers no redundancy.

To have the benefit of both modes one can use combined modes such as RAID 10, which uses distributed copies of striped blocks. But this comes at the expense of using even more drives to store the same amount of data.

RAID 5 uses only striping but manages to keep redundancy by calculating parity data. It has different characteristics than RAID 10 and it's not always clear which mode serves a task better, sometimes it's RAID 5 and sometimes it's RAID 10.

Though on personal experience we had a failed RAID 5 array at work in a customers machine because somehow errors got into the parity data and the only way out was to set up a new array. Of course the colleagues ignored the advice from the qualifier at that time and just replaced one drive, but a month later the array was dead and lost.

Apart from Wikipedia I would recommend reading the Linux RAID Wiki as well as the manpages of mdadm and md.

0
2

RAID stands for Redundant Array of Inexpensive Disks. The expansion itself contains the word "Redundant" which should make it clear that it is something (yeah, you guessed it right) redundant. But in the world where we strive for the most efficient structures, why would we need such redundancy?

The answer is "fault tolerance". Basically, RAID is a configuration which allows you to restore your data if one of the disks fail. This means you need to have more than one disks. Here comes the word "Inexpensive". You can have multiple disks only if they are inexpensive; if the disks were the price of diamonds, you wouldn't want to have any redundancy (unless you store very very important data).

Now, you can have several RAID configurations from RAID0 to RAID6. RAID0 is the configuration we normally use, it has no fault tolerance. The data is only stored once, like we see in most end-user configurations. Then why is it a part of RAID? Well, it's just like that.

For more information you can head over to Wikipedia or search the Web. There is pretty much everything out there.

1
  • this sounds something like disaster backup , that i heard from admins .
    – Raja G
    Aug 16, 2012 at 16:29
2

Other answers have spelled out the practical aspects of RAID. I'll address the system administration view. Fault tolerance isn't free, I see many many users get into software RAID because it's convenient only to lose all their data due to incorrect setup or failing to understand how the RAID works when it actually suffers an event which requires your attention.

Yes, RAID done and maintained correctly will insure your data against loss and may even increase performance, done incorrectly, the probably of catastrophic failure actually goes up as you simply have more variables to manage, more drives to go bad; get it wrong and you might find yourself without the data you worked overtime to insure.

If you're going to get into RAID, understand and practice it's deployment and fault resolution. Again software RAID is neat and reliable, but it's not any less complex than a HW RAID. In fact it's increased flexibility gets a lot of novice users into trouble.

If you bought a shiny new HW RAID array or SAN you would probably read the directions and understand how it works before you pressed it into service. Treat software RAID with the same level of consideration and it will serve you well.

Before you do anything, begin with a solid backup strategy (like rsync), fault tolerance is no substitute for a reliable, automated backup.

1
  • so it gave me a conclusion , novice should be focus while playing with that .
    – Raja G
    Aug 16, 2012 at 16:30
2

RAID 1 arrays allow your system to be more tolerant of physical failures on hard disks.

Example: You have a two disks in your system set up in a RAID 1 array. These two disks appear as one volume to the operating system and all the data written to the volume get written to both disks in the array. This way if one disk fails, you still have an exact copy on the second disk.

There are also other types of RAID arrays.

This article from Wikipedia has pretty much all you need to know.

3
  • ok if we delete data at one HDD , then automatically changes will takes place to 2nd HDD ?
    – Raja G
    Aug 16, 2012 at 15:49
  • My experience with a redundant RAID 1 array like this: easy to set up, impossible to salvage the contents once things went bad. You need a lot of knowledge to really take advantage of it. Another thing is when you set them up for speed, but for a personal computer an ssd will do you much better service with less complication. Aug 16, 2012 at 16:26
  • @GrSr, yes. If we delete data from one HDD in RAID1 automatically the same will be done to the 2nd. To the user it is only one disk, even though there are two physical disks. One disk is the mirror image of the other. With RAID1 there is no extra disk space.
    – user68186
    Aug 16, 2012 at 17:16
1

As an example of how it works in practice, a configuration I have regularly used in production servers is to have the RAID controller in a system configured with 2 arrays. The first has 2 identical disks connected and is configured as RAID1, i.e. mirrored. The 2nd has at least 3 disks (4 seems to be common) as is configured as a RAID5 array, i.e. distributed data with a parity check.

When the operating system is installed, the RAID1 array, which to the system appears to be a single disk the size of one of the drives, is used for the root partition, /etc, /usr, /var and swap, i.e. all the system stuff and the RAID5 array is used for /home, i.e. all the user data. The RAID5 array's size appears to be (n-1) times the size of a single disk (i.e. for 4 drives, the system sees a single 'disk' with a size of 3 times the size of a single drive).

In operation, the system sees 2 'disks'. If a drive fails, the RAID hardware simply stops using it and, usually, it can be replaced without stopping the server (hot-swapped), so the users are not affected by the fault.

The main reason for mirroring the system array is simply to get a slight performance boost and provide the ability to do 'tricks' like rapidly cloning a system by putting one mirror disk into a different server. In the past, I have also run systems where all the drives were configured as a single RAID5 array appearing to the operating system as a single big disk.

Software RAID works in the same way, but since the hardware doesn't usually allow for hot-swapping, the system usually needs to be shut down to replace a drive. Hence software RAID, while easier to set up, is actually harder to manage.

And you still need to have a good backup straegy in case 2 drives fail at once or the RAID controller itself fails!

6
  • yeah i got one point from this , that we can use RAID installs for providing better support even we have faced any problem with a running server . i think this install is better for server maintenance . mostly for web-servers . at time we can send information to all requests .
    – Raja G
    Aug 17, 2012 at 3:41
  • 1
    @GrSr RAID protects against the effect of a hardware failure. It doesn't help with maintenance as you'd never pull a working drive from a production server just to test the RAID rebuild, although I have done this on test/pre-production systems to check the rebuild time. Also, as Ramon implies, if the failure is due to data corruption, the whole array is corrupt and RAID of any level won't help you. Web servers often duplicate the whole server; RAID is more useful for database/file servers where the on-disk data is critical. Of course, often the web server is also the data server.
    – StarNamer
    Aug 17, 2012 at 13:10
  • ok this gave me one new flag , is this going to help at catastrophic times of web-server/database ?
    – Raja G
    Aug 17, 2012 at 13:17
  • one more thing , how much extent RAID can help a sysadmin .
    – Raja G
    Aug 17, 2012 at 13:17
  • For a sysadmin, having RAID means that when a drive fails, you just call your support company and get them to ship a replacement drive, pull the old drive, slot in the new one and send the old one back. Your users never notice the failure and the business doesn't get hit with downtime. It's just another disaster prevention measure like having a UPS or a backup network connection.
    – StarNamer
    Aug 17, 2012 at 15:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .