Tried to switch a CentOS domU from the Debian kernel to pyGrub + CentOS kernel today. Here’s what I discovered:
- the redhat initrd sucks
- unsurprisingly, the debian initrd will not work with a redhat kernel
- modifying the redhat initrd to do the right thing is impossible
- lets try using hdaX: no. that didn’t work.
- apparently using e2label to force a filesystem label helps? nope.
- nash is not really a shell, but instead an evaluator of static commands
- mkinitrd is a horribly written bash script
- modifying mkinitrd to generate /dev/hdaX and /dev/sdaX? no dice.
- trying to embed a shell into the initrd like in debian’s initrd for debugging? impossible.
I gave up for the night. Sadly that user is probably going to post a horrible review of my Xen hosting service to WHT now. Oh well, it’s not as if I needed his $5/mo anyway. Yes, $5/mo apparently gets you the privilege of 24×7 support now. I didn’t know. Update: Oh, cool, apparently he didn’t.
Update: According to the CentOS wiki page on the subject, providing a virtual disk instead of a LVM volume makes it happy. The problem then is that any VMs made using an LVM partition can’t be transferred to a virtual disk, as the whole LVM volume is a filesystem. Or am I missing something? I suspect RedHat calls this a feature, personally I call it a bug.