I’m trying to convert a running SuSE 11.3 machine to boot from RAID1.
Seems to work – I copied / and /boot to (degraded) md arrays, and have successfully booted from the new disk. But the md device for / on the running system does not exist in /dev! Among other things, this has prevented me from adding the original root partition to the array.
Perhaps devtmpfs was mounted on /dev after the md device was put in /dev, thus overmounting the existing md device?? I can not otherwise imagine how my system can claim to have /dev/md8 mounted as /, when /dev/md8 itself does not (seem to) exist. But I don’t know whether I need a new initrd, or should tweak devtmpfs and/or udev, or perhaps something else altogether.
Details:
I’ve been running SuSE 11.3 on a 64-bit machine with 1 disk.
I created /boot and / partitions on disk2 with:
mdadm -Cv /dev/md3 -e0.9 -l1 -n2 missing /dev/sdb3
mdadm -Cv /dev/md8 -e0.9 -l1 -n2 missing /dev/sdb6
(the numbering is for historical reasons), then added the configuration details to /etc/mdadm.conf using mdadm -Ds. Formatted as ext3, then copied /boot and / into /dev/md3 and /dev/md8, respectively. Set up GRUB and /etc/fstab on disk2, then booted successfully into the new system. Completed the /boot array (/dev/md3) with:
mdadm /dev/md3 -a /dev/sda3
but couldn’t run the similar command for /dev/md8 because it doesn’t exist! That’s right, df shows:
/dev/md8 766736 345272 382516 48% /
/dev/md3 256586 59520 183818 25% /boot
but “ls /dev/md8” returns “no such file or directory”, and /proc/mdstat contains no information about this array.
I’ve tried this both with the stock initrd (2.6.34-12-desktop), and with one I made using mkinitrd after adding “raid1” to INITRD_MODULES in /etc/sysconfig/kernel; no difference. I have not tried making my own initramfs. But I have trouble believing that this is where the problem lies, since the RAID array is assembled and mounted correctly – otherwise I couldn’t boot. Rather, I suspect this is a problem with devtmpfs. Or perhaps the init script, or even something silly like not using /dev/md0…
Thanks in advance for any suggestions.