Re: Creating /dev/md* device files
On Wednesday 26 January 2005 01:59 pm, Steve Witt wrote:
> Thanks for the help, mknod worked but MAKEDEV didn't (I was root). And
> devices made with mknod don't survive a reboot!?! So, in digging a bit
> more, it seems, unbeknownst by me, that this machine is using the udev
> scheme for managing devices (it has a 2.6.8 kernel, which I should have
> mentioned). So at least I know why MAKEDEV didn't work and now need to
> research udev and find out how to get md devices to consistantly show up.
I am running multiple software raid systems.
I also had the trouble with udev. In the end I just removed udev, ran
mknod /dev/md0 b 9 0 and went from there.
There is no problem if you compile the modules md, raid5 (or raid1) and md
into the kernel. However if you load these as modules, then there is a
problem. Udev apparently doesnt create the devices early enough.
The issue is that it is hard to be able to have udev create the devices early
enough so that the raid array will exist early during the boot process
so that when fsck is run during /etc/rcS.d
(ie in single user mode - when we run S30checkfs.sh, and all the devices
in /etc/fstab have fsck run on them) we need that /dev/md0 should exist.
Anyway, this is apparently a known issue with udev. If you have a solution
using initrd and modules other than recompiling the kernel, let me know. To
find the bug report, look for my prior postings on debian-user and md0.
I quote from Greg Folkert
> i am curious. i am running 2.6.8 kernel on sarge. i tried to avoid
> my kernel and would prefer to load the raid5 driver as a module, and thus
> initrd.img. however, in my initial setup, after i ran mknod /dev/md0 and
> rebooted, /dev/md0 dissapeared, (perhaps this udev? is the culpret? who
Well you found the same bug I found doing it that way. Remove udev. file
a bug against kernel-source-2.6.8-1. Ask the Debian Kernel Team. As far
as the bug, here it is and read Marco's response and re-assign to the
> well what do i do to make it appear each boot? or perhaps, once i
> create the initrd with raid5 module in it, then it will appear without my
> doing mknod /dev/md0 each time, or do i need a script in /etc/rcS.d
> or /etc/rc2.d to do
> mknod /dev/md0 b 9 0
> each reboot?
> any ideas?
> mknod /dev/md0
Oh, yes my child... all you haav to do is remove udev for the time being
or recompile a kernel with raid* compiled in statically.
greg, greg <at> gregfolkert.net