Bug#549298: mdadm should copy its own rules file to the initramfs
Petter Reinholdtsen
pere at hungry.com
Sun Oct 25 10:42:24 UTC 2009
tags 549298 + patch
thanks
I had a look in udev and mdadm, and suspect this untested patch will
solve the problem. It is a copy of code found in udev with only the
mdadm rule left in the for loop.
I do not know the inner workings of udev and mdadm, so I am not sure
if this was the change the udev maintainer Marco d'Itri had in mind.
Cc to him, hoping for feedback on the approach.
diff -ur mdadm-3.0/debian/initramfs/hook mdadm-3.0-pere/debian/initramfs/hook
--- mdadm-3.0/debian/initramfs/hook 2009-10-24 23:46:21.000000000 +0200
+++ mdadm-3.0-pere/debian/initramfs/hook 2009-10-25 11:35:31.000000000 +0100
@@ -281,6 +281,15 @@
done
fi
+ # Copy udev rules, udev want to stop copying it
+ mkdir -p $DESTDIR/lib/udev/rules.d/
+ for rules in 64-md-raid.rules; do
+ if [ -e /etc/udev/rules.d/$rules ]; then
+ cp -p /etc/udev/rules.d/$rules $DESTDIR/lib/udev/rules.d/
+ elif [ -e /lib/udev/rules.d/$rules ]; then
+ cp -p /lib/udev/rules.d/$rules $DESTDIR/lib/udev/rules.d/
+ fi
+ done
else
echo "MD_DEVS=none" >> $DESTCONFIG
echo "MD_MODULES=''" >> $DESTCONFIG
Happy hacking,
--
Petter Reinholdtsen
More information about the pkg-mdadm-devel
mailing list