Re: mdraid DDF container support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2012-07-24 at 14:02 -0500, Jared_Dominguez@xxxxxxxx wrote:
> Greetings,
> 
> I've been working on a feature to add DDF container support using mdraid to Anaconda. It should be building on the work done to support IMSM containers using mdraid instead of dmraid. I've been hoping to have a patch ready already, but I'm running into some problems related to differences in how metadata for the two container formats is exposed. This is also the first time I've worked on Anaconda so am still familiarizing myself with the codebase. For IMSM, Anaconda has a udev rule that gets a value for MD_DEVICES:
>     ENV{ID_FS_TYPE}=="isw_raid_member", IMPORT{program}="$env{ANACBIN}/mdadm --examine --export $tempnode"
> 
> Alas, for DDF, the same rule doesn't get a value for MD_DEVICES. One can get this information for DDF by first doing "mdadm -A -e ddf --scan". Subsequently, "mdadm --detail --export /dev/md127" will give MD_DEVICES. However, it seems to me to be a poor practice to assemble any arrays in 70-anaconda.rules. Besides, while testing, Anaconda seems not to like this in there anyway:
>     ENV{ID_FS_TYPE}=="ddf_raid_member", RUN+="$env{ANACBIN}/mdadm -A -e ddf --scan"
>     KERNEL=="md[0-9]*|md_d[0-9]*|md/*", IMPORT{program}="$env{ANACBIN}/mdadm --detail --export $tempnode"
> It interferes with Anaconda accessing the array with mdadm, causing Anaconda to hang indefinitely.
> 
> Might anyone with more Anaconda development experience have suggestions for where to try collecting this one piece of information?

Short answer:
Take a look at the function mdexamine in
pyanaconda/storage/devicelibs/mdraid.py.

Longer answer:
I haven't read the DDF spec, but it sounds like there is no way to
determine the number of component devices without first
assembling/activating the array. If this is not the case, file a bug
against mdadm to fix the output of 'mdadm --examine --export'.

If it is the case that one can never know the number of members of a DDF
array without first assembling the array, you'll need to add special
code to anaconda to accommodate setting up an array without knowing the
number of member devices. Some of the areas you'll need to work to do
that are

pyanaconda/storage/devicetree.py:DeviceTree.addUdevDiskDevice
pyanaconda/storage/devicetree.py:DeviceTree.handleUdevMDMemberFormat
pyanaconda/storage/devices.py:MDRaidArrayDevice
pyanaconda/storage/devicelibs/mdraid.py

Good luck.

David

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux