[CentOS] How to setup RAID 5 + 1 hot spare?

Thu Jan 24 14:37:54 UTC 2013
Wenshan Ren <renws1990 at gmail.com>

Rudi Ahlers writes:

> On Thu, Jan 24, 2013 at 7:59 AM, Ren Wen shan <renws1990 at gmail.com> wrote:
>
>> Hello everyone,
>>
>> I am new to this group so please forgive me if this question has been
>> already asked.
>>
>> With four identical hard drives, I want to setup RAID 5 + 1 hot spare by a
>> fresh CentOS (6.3) installation.
>>
>> I have read this article (
>>
>> http://www.centos.org/docs/5/html/Deployment_Guide-en-US/s1-raid-config.html
>> )
>> and watched this video (http://www.youtube.com/watch?v=qm3MkuTfDLw), now I
>> have the basic ideas.
>>
>> However, due to my limited experience and knowledge on this area, I am
>> still confused.
>>
>> To make things easier, I only need a swap and a `/' partition.
>>
>> Could you give me any hint on this? What should I read to get the basic
>> knowledge? How can I setup a simple RAID 5 + hot spare?
>>
>>
>> Regards,
>> - Meatball
>> _______________________________________________
>>
>>
> Since you're new to this list, and this topic, I'm going to spare you the
> headache. Don't use RAID5 Even with a hot-spare, if you use large drives
> chances are you'll loose everything if one of the drive fail and you need
> to rebuild the whole set.
>
> Rather use RAID 10. The newer CentOS installation disks has an option to
> setup RAID10, alternatively.
>
> There are numerous tutorials out there on how todo it, but this one seems
> quite easy to follow:
> http://www.youtube.com/watch?v=zlOK1voR2nA

Hi Rudi,

Thanks a lot for your reply, the video is very helpful.

I read this discussion on serverfault.com
http://serverfault.com/questions/106131/raid-5-with-hot-spare-or-raid-10-with-no-hot-spare


but still quite confused as some people think RAID-10 is way safer while
some people wrote:
"
I'd have to disagree with CHopper3. Since there are only 4 drives in
this situation your failure capabilities are the same (2 drives) with
either scenario, except with raid 10 if you happen to lose the wrong 2
drives then you'll have a real problem. Also there is definitely an
added benefit of having a global spare for your other RAIDs as well.
"


My new question is:
As RAID 10 requires at least 4 hard drives (not very sure about this
information), with only 4 hard disks, is RAID-10 without hot spare a
better solution than RAID-5 + 1 hot spare? Why or why not?

--
Wenshan Ren
Email: renws1990 at gmail.com
Blog: wenshanren.org
Douban: www.douban.com/people/renws