===== I have moved on! =====

Please join me at Virtually Lost in the search to find Nirvana using virtualization technologies.

Monday, January 15, 2007

Problems with booting Xen guests after going to version 3

If you are experiencing bootup problems with your Xen v3 guests, it may very be that you have not completely prepared your guests with the Xen v3 modules.

You see, with Xen v2, most people compiled their own kernels, both for the xen0/dom0 and xenU/domU. Most admins compiled in the ext3 support or necessary filesystem drivers directly into the XenU kernel, and were able to boot the Virtual Machines with no hiccups.
With Xen v3, the kernel is the same with both dom0 and domU, and everything is modular. Most admins even have to make sure to include a initrd to even boot their dom0. How do you do the same with the domU ??

Follow these two steps:


  1. Add the following in your xmconfig file for that domU:
    ramdisk="/boot/initrd-2.6.18-1.2869.fc6xen.img"

  2. Tar up the Xen modules, mount your domU image on a loopback and copy the modules to the domU image.
    cd /lib/modules
    tar -czvf ./2.6.18-1.2869.fc6xen-modules.tgz ./2.6.18-1.2869.fc6xen/
    mkdir /mnt/guest-os
    mount -o loop /someclient_image /mnt/guest-os
    cd /mnt/guest-os
    tar -xzvf /lib/modules/2.6.18-1.2869.fc6xen.tgz
    cd /
    umount /mnt/guest-os


That should be all, you should now be able to start your domU.
Note: This article takes for granted that your actual kernel name is vmlinux-2.6.18-1.2869.fc6xen :-) YMMV

No comments: