Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Hardware RAID controller

Need help with peripherals or devices?
Post Reply
Message
Author
NewToLinux
Posts: 71
Joined: 2017-09-17 11:30

Hardware RAID controller

#1 Post by NewToLinux »

I am thinking of setting up a RAID 1 array of two SATA HDDs using a hardware RAID controller on a desktop
computer running Debian 11.

I would like some advice regarding a suitable controller that costs no more than about 100 pounds.

I understand that the lsi/Broadcom Megaraid RAID software can be set up for Debian :-

https://www.mybluelinux.com/debian-linu ... araid-sas/

LE_746F6D617A7A69
Posts: 932
Joined: 2020-05-03 14:16
Has thanked: 7 times
Been thanked: 65 times

Re: Hardware RAID controller

#2 Post by LE_746F6D617A7A69 »

There are 2 kinds of HW Raid controllers:
1. Fake RAID controllers (where the RAID functionality is implemented in the firmware -> 90% of the controllers on the market)
2. Server RAID controllers (very expensive, but they can handle tens of HDDs)

For just 2 HDDs in RAID1 mode it doesn't make any sense to buy a HW RAID controller -> Linux MD driver is all You need (see the manpage for mdadm)

Buying a HW RAID controller generally makes sense only for RAID6 (RAID5 is flawed - never use this topology), -> true RAID6 HW controller is off-loading the CPU, because it's calculating the checksums for the RAID stripes on-the-fly. However, today's CPUs are very fast, and they can achieve up to 40GB/s with DDR4 RAM, so buying a HW RAID6 controller makes sense only if You have a lot of HDDs in the array.

For RAID levels 0,1,10 in a home PC it makes completely no sense to buy a HW controller - MD array will perform significantly better, with zero additional costs.

Regards.
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Hardware RAID controller

#3 Post by p.H »

LE_746F6D617A7A69 wrote: 2022-01-28 21:27 RAID5 is flawed - never use this topology
Why ?

LE_746F6D617A7A69
Posts: 932
Joined: 2020-05-03 14:16
Has thanked: 7 times
Been thanked: 65 times

Re: Hardware RAID controller

#4 Post by LE_746F6D617A7A69 »

p.H wrote: 2022-01-29 09:52
LE_746F6D617A7A69 wrote: 2022-01-28 21:27 RAID5 is flawed - never use this topology
Why ?
Well, there are hundreds of articles on this topic, and even more reports of RAID5 failures - the problem is that RAID5 topology can't protect the data during rebuilding of the array after a single disk failure - mainly because of the URE factor (Unrecoverable Error Rate).

Here You have example article:
https://www.zdnet.com/article/why-raid- ... g-in-2009/

Of course RAID6 also has its limitations -> IMO RAID10 offers the best possible data safety and a performance level similar to that of RAID0.

Regards
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed

User avatar
argentwolf
Posts: 201
Joined: 2021-09-05 23:21
Has thanked: 185 times
Been thanked: 15 times

Re: Hardware RAID controller

#5 Post by argentwolf »

It would be more creditable if people would simply provide the technology behind the discussion and leave the 'faulty article' links in the ether. D'oh!

"RAID (redundant array of independent disks)"
https://www.techtarget.com/searchstorag ... ition/RAID

Edit:
Hell, one might even bring into this discussion the different file systems...to 'next level' the information.

"Comparison of file systems"
https://infogalactic.com/info/Compariso ... le_systems
Vanguard Debian, because nothing's worse than doing nothing, whimsically!
32-bit | 2 Duo T5270 @ 1.40GHz x 2 CPU | 3.9GiB RAM | NV86 117MiB GPU | 465.76GiB SSD
64-bit | i7-4790 @ 3.60GHz x 8 CPU | 15.6GiB RAM | NVD9 1.9GiB GPU | 931.51GiB SSD

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Hardware RAID controller

#6 Post by p.H »

LE_746F6D617A7A69 wrote: 2022-01-29 11:05 the problem is that RAID5 topology can't protect the data during rebuilding of the array after a single disk failure - mainly because of the URE factor (Unrecoverable Error Rate)
How is that different from RAID 1 or RAID 10 ?

NewToLinux
Posts: 71
Joined: 2017-09-17 11:30

Re: Hardware RAID controller

#7 Post by NewToLinux »

Thanks very much for all your replies.

I should have made the situation clearer.

I actually require to have the OS on a RAID 1 array of two SATA HDDs and the user data on another RAID 1
array of another two SATA HDDs.

I realise I can set up the user data RAID 1 using software RAID (e.g. mdadm).

The problem is with setting up the OS RAID 1. Often this is possible using the motherboard RAID.

Unfortunately, the AMD Ryzen motherboard I am using appears not to have motherboard RAID support for Linux.

So the only option for the OS RAID appears to be the use of a Hardware RAID controller. I realise such a controller
can cost hundreds of pounds, but I was hoping to find such a controller for about 100 pounds.

I am not interested in RAID arrays other than RAID 1.

CwF
Global Moderator
Global Moderator
Posts: 2669
Joined: 2018-06-20 15:16
Location: Colorado
Has thanked: 41 times
Been thanked: 196 times

Re: Hardware RAID controller

#8 Post by CwF »

NewToLinux wrote: 2022-01-29 17:39 I am not interested in RAID arrays other than RAID 1.
I question using any type at all!

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Hardware RAID controller

#9 Post by p.H »

NewToLinux wrote: 2022-01-29 17:39 Unfortunately, the AMD Ryzen motherboard I am using appears not to have motherboard RAID support for Linux.
So the only option for the OS RAID appears to be the use of a Hardware RAID controller.
No. You can also use Linux software RAID for the OS. The boot setup is just a bit more tricky.

LE_746F6D617A7A69
Posts: 932
Joined: 2020-05-03 14:16
Has thanked: 7 times
Been thanked: 65 times

Re: Hardware RAID controller

#10 Post by LE_746F6D617A7A69 »

p.H wrote: 2022-01-29 12:35
LE_746F6D617A7A69 wrote: 2022-01-29 11:05 the problem is that RAID5 topology can't protect the data during rebuilding of the array after a single disk failure - mainly because of the URE factor (Unrecoverable Error Rate)
How is that different from RAID 1 or RAID 10 ?
For minimal RAID1 array made of 2 HDDs there's no difference in this aspect, and nobody is setting RAID1 mode for more than 2 HDDs

Typical RAID10 made of 4 HDDs behaves like RAID6, but the probability of failure decreases with the number of HDDs in the array -> unlike in case of RAID6, where probability of simultaneous failure of 2 HDDs grows with the size of array.
RAID10 can work even if halve of the array is offline and only in such case it is affected by URE.
------------------
p.H wrote: 2022-01-29 19:20
NewToLinux wrote: 2022-01-29 17:39 Unfortunately, the AMD Ryzen motherboard I am using appears not to have motherboard RAID support for Linux.
So the only option for the OS RAID appears to be the use of a Hardware RAID controller.
No. You can also use Linux software RAID for the OS. The boot setup is just a bit more tricky.
*ALL* raid controllers integrated into PC motherboards are FAKE raids.

Debian installer allows to create RAID array during installation - no problem at all.
The problem is with UEFI partitions, but there's a solution:
https://outflux.net/blog/archives/2018/ ... and-raid1/
.
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Hardware RAID controller

#11 Post by p.H »

LE_746F6D617A7A69 wrote: 2022-01-29 20:10 For minimal RAID1 array made of 2 HDDs there's no difference in this aspect, and nobody is setting RAID1 mode for more than 2 HDDs
Why then warn against RAID 5 only ?
LE_746F6D617A7A69 wrote: 2022-01-29 20:10 Typical RAID10 made of 4 HDDs behaves like RAID6
Not quite. RAID 6 survives the failure of any 2 drives. RAID 10 made of 4 drives has 50% survival probability when losing two drives, depending on which drives fail.
LE_746F6D617A7A69 wrote: 2022-01-29 20:10 RAID10 can work even if halve of the array is offline
Only if you are lucky. If you are unlucky, RAID 10 can die if two drives fail.

LE_746F6D617A7A69
Posts: 932
Joined: 2020-05-03 14:16
Has thanked: 7 times
Been thanked: 65 times

Re: Hardware RAID controller

#12 Post by LE_746F6D617A7A69 »

p.H wrote: 2022-01-29 21:02
LE_746F6D617A7A69 wrote: 2022-01-29 20:10 For minimal RAID1 array made of 2 HDDs there's no difference in this aspect, and nobody is setting RAID1 mode for more than 2 HDDs
Why then warn against RAID 5 only ?
Because RAID5 is still the most commonly used configuration for 3+ HDDs - and people just have to be warned
p.H wrote: 2022-01-29 21:02
LE_746F6D617A7A69 wrote: 2022-01-29 20:10 Typical RAID10 made of 4 HDDs behaves like RAID6
Not quite. RAID 6 survives the failure of any 2 drives. RAID 10 made of 4 drives has 50% survival probability when losing two drives, depending on which drives fail.
Not quite - this depends on data layout. Linux MD RAID10 layout != Raid1+0 and != Raid0+1 -> the data is evenly distributed among all the drives.
p.H wrote: 2022-01-29 21:02
LE_746F6D617A7A69 wrote: 2022-01-29 20:10 RAID10 can work even if halve of the array is offline
Only if you are lucky. If you are unlucky, RAID 10 can die if two drives fail.
As above, this is not true: with correct data layout, the chunks of data are evenly distributed among all the drives, so 50% of HDDs can go offline safely.
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed

p.H
Global Moderator
Global Moderator
Posts: 3049
Joined: 2017-09-17 07:12
Has thanked: 5 times
Been thanked: 132 times

Re: Hardware RAID controller

#13 Post by p.H »

I do not see how this is possible. Any data chunk is present on two drives only, so if these two drives fail the data is lost.

LE_746F6D617A7A69
Posts: 932
Joined: 2020-05-03 14:16
Has thanked: 7 times
Been thanked: 65 times

Re: Hardware RAID controller

#14 Post by LE_746F6D617A7A69 »

p.H wrote: 2022-01-29 23:22 I do not see how this is possible. Any data chunk is present on two drives only, so if these two drives fail the data is lost.
The magic responsible for this phenomenon is probability.
For RAID6, failure of *any* 3 drives damages the array, and to kill RAID10 you need a simultaneous failure of 2 *selected* drives.

The probability of failure of *any* 3 drives grows proportionally to the size of the array, while the probability of failure of 2 *selected* drives drops exponentially with the size of array:

Code: Select all

PfHDD - probability of single HDD failure
N     - number of drives in the array
PfR6  = N*PfHDD^3
PfR10 = (1/N)^2*PfHDD^2

For PfHDD=0.01, N=100:
PfR6  = 100*0.01^3 = 0.0001 = 1*10^-4
PfR10 = (1/100)^2*0.01^2 = 0.00000001 = 1*10^-8
That's why it works.
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed

Post Reply