2005.0 and installing on a software RAID (tears remaining hair out)
Trying to setup Gentoo on a pair of IDE disks (hda / hdc), similar to
how I did it last year with the 2004.0 disks. Basically, both drives
are going to be partitioned as follows, with RAID1 for everything (even
the swap file).
/boot - 128MB (hda1/hdc1)
(swap) - 2GB (hda2/hdc2)
/ - 2GB (hda3/hdc3)
LVM partitions - rest of disk (hda4/hdc4)
However, things have changed slightly between last year's 2004.0 CD and
the 2005.0 CD (mostly having to do with the 2.6 kernel and changing to
UDev from DevFS?).
# modprobe md
# ls /dev/md*
ls: /dev/md*: No such file or directory
# for i in 0 1 2 3; do mknod /dev/md$i b 9 $i; done
# ls /dev/md*
/dev/md0 /dev/md1 /dev/md2 /dev/md3
# nano -w /etc/mdadm.conf
Contents of my mdadm.conf file:
DEVICE /dev/hda1 /dev/hda2 /dev/hda3 /dev/hda4
DEVICE /dev/hdc1 /dev/hdc2 /dev/hdc3 /dev/hdc4
ARRAY /dev/md0 devices=/dev/hda1,/dev/hdc1
ARRAY /dev/md1 devices=/dev/hda2,/dev/hdc2
ARRAY /dev/md2 devices=/dev/hda3,/dev/hdc3
ARRAY /dev/md3 devices=/dev/hda4,/dev/hdc4
Pretty generic... now to create the raid. This is where we hit our first
issue:
# modprobe raid1
# mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/hda1 /dev/hdc1
mdadm: /dev/hda1 appears to contain an ext2fs file system
size=72192K mtime=Wed Mar 30 16:46:07 2005
mdadm: /dev/hdc1 appears to contain an ext2fs file system
size=72192K mtime=Wed Mar 30 16:46:07 2005
Continue creating array? y
mdadm: ADD_NEW_DISK for /dev/hda1 failed: Device or resource busy
#
Here are the problems:
1) Even though I have a 128MB partition for /boot, it is still showing
64MB from a previous partitioning scheme.
2) mdadm: ADD_NEW_DISK for /dev/hda1 failed: Device or resource busy
So... take a look at my partition list:
livecd root # fdisk -l
Disk /dev/hda: 76.8 GB, 76869918720 bytes
16 heads, 63 sectors/track, 148945 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Device Boot Start End Blocks Id System
/dev/hda1 * 1 249 125464+ fd Linux raid autodetect
/dev/hda2 250 4218 2000376 fd Linux raid autodetect
/dev/hda3 4219 8187 2000376 fd Linux raid autodetect
/dev/hda4 8188 148945 70942032 fd Linux raid autodetect
Disk /dev/hdc: 76.8 GB, 76869918720 bytes
16 heads, 63 sectors/track, 148945 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Device Boot Start End Blocks Id System
/dev/hdc1 * 1 249 125464+ fd Linux raid autodetect
/dev/hdc2 250 4218 2000376 fd Linux raid autodetect
/dev/hdc3 4219 8187 2000376 fd Linux raid autodetect
/dev/hdc4 8188 148945 70942032 fd Linux raid autodetect
livecd root #
All of which looks right and proper. I'm on about my 6th attempt now,
and I'm not sure why the 2004.0 CD worked last year, but the 2005.0 CD
is not working this year. (I had an identical configuration up and
running for most of last year.) |