Hide Forgot
+++ This bug was initially created as a clone of Bug #575840 +++ +++ but i made description accurate +++ Description of problem: A raid array on a encrypted lvm volume is not started automatically by rc.syslocal when there aren't any md arrays already. This is because: # grep mdadm /etc/rc.sysinit [ -r /proc/mdstat -a -r /dev/md/md-device-map ] && /sbin/mdadm -IRs # If all the md components are on crypt, /dev/md/md-device-map does not exist at this time. I think this would work if dracut had set up some md devices earlier, but in my use case it does not. Version-Release number of selected component (if applicable): initscripts-9.03.23-1.el6.x86_64 How reproducible: always Steps to Reproduce: 1. create a mdadm raid on a encrypted partition 2. don't have any other mdadm raids Actual results: the raid is not started after boot Expected results: the raid is started Additional info: The recommendation of doing crypt underneath md came from RH engineering. This patch fixes the problem on my system (it's after the first init_crypto so the components are detectable): --- rc.sysinit.el6.1 2011-07-01 10:55:39.066082994 -0400 +++ rc.sysinit 2011-07-01 10:56:02.174082979 -0400 @@ -193,6 +193,7 @@ fi fi +[ -f /etc/mdadm.conf -a -x /sbin/mdadm ] && /sbin/mdadm -As --auto=yes --run # Start any MD RAID arrays that haven't been started yet [ -r /proc/mdstat -a -r /dev/md/md-device-map ] && /sbin/mdadm -IRs
I am curious: Who in Red Hat engineering recommended encrypting raid member devices instead of encrypting the raid device itself? This configuration is discouraged to the point that it was not even supported in RHEL5.
(I emailed you off-bz.) Crypt below seemed to be consensus when asking around, admittedly most of them didn't have the same case (laptop single disk) that I have for raid. In the GUI, anaconda seems to let you do either. Of course, there's more than one way to do it and I'm open to pro/con arguments as to which way to go. I didn't do any benchmarking, but I guess it depends on where the bottleneck lies - is it better to do crypt on bottom and have 4 dmcrypt threads underneath, or above md and only have one? As far as other combinations, I'm probably indifferent between lvm>crypt>md and crypt>lvm>md. The latter (crypt on top) would let me use urandom to have swap unrecoverable after reboot but I don't really care about that use case. I don't really swap much anyway, so I've still got a single crypt thread for all the iops. The former (crypt in middle) would protect lvm metadata, so nobody would know that my LV is called vg1_take_over_world_project but, oops, I posted it in bugzilla. I'm also not using md or crypt for the root filesystem. If I were I think md-device-map would exist at sysinit time and I'd have a chance of perhaps using the config file start the array without patching sysinit.
title changed to reflect el6 reality
Since RHEL 6.2 External Beta has begun, and this bug remains unresolved, it has been rejected as it is not proposed as exception or blocker. Red Hat invites you to ask your support representative to propose this request, if appropriate and relevant, in the next release of Red Hat Enterprise Linux.
This request was not resolved in time for the current release. Red Hat invites you to ask your support representative to propose this request, if still desired, for consideration in the next release of Red Hat Enterprise Linux.
There was no activity in the bugzilla for a long time (4 years). Since we are already in production phase 2, we should not make any changes in this area.