Bug 17366

Summary: mdadm failing to run raid devices: falling back to dmraid
Product: Mageia Reporter: xboxboy <xboxboy.mageia>
Component: InstallerAssignee: Thierry Vignaud <thierry.vignaud>
Status: NEW --- QA Contact:
Severity: normal    
Priority: Low CC: marja11, tmb, xboxboy.mageia
Version: Cauldron   
Target Milestone: ---   
Hardware: i586   
OS: Linux   
Whiteboard:
Source RPM: drakx-installer-stage2-17.7.1-1.mga6 CVE:
Status comment:
Attachments: report.bug.xz

Description xboxboy 2015-12-19 14:14:34 CET
Description of problem:

Intel (other brands may also apply) bios/motherboard/fake raid array should be run and managed by mdadm. Dmraid is old and unmaintained.

Version-Release number of selected component (if applicable):

Mdadm-3.3.4-2.mga6
Dmraid-1.0.0-0.rc16.21.mga6

How reproducible:

(this is my system)
System has 5 HDD's
sda and sdb are paired in one array
sdc and sdd are paired in a second array
sde is boot/os drive

The raid arrays are assembled/created/labelled in bios prior to the OS booting.

In Mageia 5 fedora-storage-init was modified so the installer could allow dmraid to operate such arrangements. 

Steps to Reproduce:
1. Boot install media (confirmed that plasma x86_64 iso and boot.iso both do this)
2. Run through installer
3. Reboot at end of install into new os, check media mount points

Cat /proc/mdstat
Personalities :
Unused devices: <none>

There's no /dev/md*

But the arrays are mounted under /dev/mapper/isw*


The fact that the arrays are mounted and operational under dmraid is good (mageia 3 & 4 required that fedora-storage-init be modified AFTER install), but the application of mdadm would be much appreciated seeing it's the recommended system for such fake raid systems. dmraid doesn't have the features that mdadm now has, and as such recovering from a failed array may cause significant trauma. 

Reproducible: 

Steps to Reproduce:
Comment 1 xboxboy 2015-12-19 14:16:08 CET
Created attachment 7290 [details]
report.bug.xz
Comment 2 xboxboy 2015-12-19 14:18:02 CET
Added attachment 7290 [details] report.bug.xz from the boot.iso install

I can get the report from the plasma install also if required.

Willing to do any further testing required, just let me know.
Comment 3 Marja Van Waes 2015-12-20 08:59:52 CET
Assigning to Thierry

Maybe mdadm could be run in the setupSCSI step instead of dmraid??

CC: (none) => marja11
Assignee: bugsquad => thierry.vignaud
Source RPM: (none) => drakx-installer-stage2-17.7.1-1.mga6

Comment 4 Thierry Vignaud 2015-12-20 10:21:39 CET
It's a long goal...

CC: (none) => tmb

Comment 5 xboxboy 2016-12-30 14:48:10 CET
Done some digging: The default kernel option on latest plasma live dvd has 'noiswmd', if I remove this option then the arrays appear in /dev/md, but they are not activated, and diskdrake sees the individual drive members, not the array.

Looking at /lib/systemd/fedora-storage-init the line to active the md arrays is looking for /dev/md/md-device-map which I cannot find.

What made me look for this md-device-map was http://superuser.com/questions/364354/mandriva-linux-fails-to-boot-after-installing-systemd

Is this why I cannot get mdadm to run my arrays with out manual intervention? What creates md-device-map? Or does this not apply to a live DVD? Or are there other forces at play?
xboxboy 2016-12-30 14:49:15 CET

CC: (none) => xboxboy.mageia

Comment 6 Thierry Vignaud 2016-12-30 15:54:19 CET
And we explicitly use that option b/c else dracut will run mdadm instead of dmraid, and draklive-install/diskdrake do not handle it well.
So unless one suggests patches for diskdrake in order to support mdadm, we'll still use that option.

Priority: Normal => Low

Comment 7 xboxboy 2017-01-01 12:26:09 CET
Does this mean I should install on a boot drive as usual, leaving all raid members unmounted, then manually use mdadm. dmraid works fine, but I'd much rather mdadm for the abilities to rebuild should the array fail.

Pardon my ignorance, but as I understand, diskdrake doesn't have the ability to read/work with mdadm? is this correct? How big of a task would this be?