dmraid does not start on boot for single disk RAID0
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
dmraid (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
I have a Lenovo server with a LSI controller that insists on having a RAID set to boot. So the BIOS is configured with a RAID0 stripe set, with a single disk:
$ dmraid -i -si
*** Group superset .ddf1_disks
--> Subset
name : ddf1_4c53492020
size : 974608384
stride : 128
type : stripe
status : ok
subsets: 0
devs : 1
spares : 0
Notice that 'devs' is 1.
This causes this bit of code in dm-activate to bail:
case "$Raid_Type" in
Of course, the above is totally bogus, a 1 disk RAID0 is perfectly valid. I wonder if this should be testing 'status' instead?
This is a problem because of GPT partitioning. If you don't start the RAID downstream tools will attempt to partition sda. The RAID metadata at the end of the disk collides with the GPT partition backup and it ends up destroying the RAID set and making the server unbootable. The kernel hints at this condition:
[ 4.202136] GPT:Primary header thinks Alt. header is not at the end of the disk.
[ 4.202137] GPT:974608383 != 976773167
[ 4.202138] GPT:Alternate GPT header not at the end of the disk.
[ 4.202138] GPT:974608383 != 976773167
Which is 100% true, the GPT was written to the RAID, not the raw disk, and 974608383 sectors is at the end of the raid volume.
The test in that script is wrong, but since you only have a single disk, you should be able to throw out the fake raid junk and just put the controller in AHCI mode.