1

I am running Debian Wheezy on a software RAID 0 with LVM. I'm trying to get Xen to work but grub refuses to boot in it. I installed Xen by following the instructions here: http://wiki.debian.org/Xen

Upon reaching

multiboot       /boot/xen-4.1-amd64.gz placeholder dom0_mem=4096M

I get

error: couldn't open file

followed by

error: you need to load the multiboot kernel first

There's nothing wrong with the file though. Here's the grub.cfg entry for Xen:

menuentry 'Debian GNU/Linux, with Xen 4.1-amd64 and Linux 3.2.0-4-amd64' --class debian --class gnu-linux --class gnu --class os --class xen {
        insmod raid
        insmod mdraid1x
        insmod lvm
        insmod part_msdos
        insmod part_msdos
        insmod ext2
        set root='(vg00-dom0-root)'
        search --no-floppy --fs-uuid --set=root 681448b8-7afb-4a25-9830-490dfc0f29a3
        echo    'Loading Xen 4.1-amd64 ...'
        multiboot       /boot/xen-4.1-amd64.gz placeholder dom0_mem=4096M
        echo    'Loading Linux 3.2.0-4-amd64 ...'
        module  /boot/vmlinuz-3.2.0-4-amd64 placeholder root=/dev/mapper/vg00-dom0--root ro initrd=/install/initrd.gz quiet
        echo    'Loading initial ramdisk ...'
        module  /boot/initrd.img-3.2.0-4-amd64
}

Below is my regular boot entry. It's remarkably similar and it works perfectly.

menuentry 'Debian GNU/Linux, with Linux 3.2.0-4-amd64' --class debian --class gnu-linux --class gnu --class os {
        load_video
        insmod gzio
        insmod raid
        insmod mdraid1x
        insmod lvm
        insmod part_msdos
        insmod part_msdos
        insmod ext2
        set root='(vg00-dom0-root)'
        search --no-floppy --fs-uuid --set=root 681448b8-7afb-4a25-9830-490dfc0f29a3
        echo    'Loading Linux 3.2.0-4-amd64 ...'
        linux   /boot/vmlinuz-3.2.0-4-amd64 root=/dev/mapper/vg00-dom0--root ro initrd=/install/initrd.gz quiet
        echo    'Loading initial ramdisk ...'
        initrd  /boot/initrd.img-3.2.0-4-amd64
}

I realize this looks like a "please solve my problem for me" kind of question, but that is not my intention at all. I've spent hours googling and trying things already, but I can't find anything that brings me even one step closer. The closest thing I found on the web was someone who forgot to add the "search" line in his grub.cfg. It doesn't look like that's the problem in my case, as the "search" seems to work fine for my regular boot entry.

I'm really hoping someone can point me in the right direction so I can find the solution.

Thank you!

Rapsey
  • 295
  • 3
  • 10

2 Answers2

1

I googled after "xen grub2 multiboot" and found a similar question on Superuser.

I think the baseline of the answer is that the kernel did not match. Strange to me is the missing /boot prefix in the solution, but it might be that he did put /boot on a partition of its own.

Nils
  • 7,657
  • 3
  • 31
  • 71
  • Wow, now my noodle is really baked. That post held the solution for me. Apparently all I had to do was change the "--set=root" to just "--set" in the "search" line. Thank you, this was exactly what I was looking for! – Rapsey May 15 '13 at 08:34
  • I think he could use lvm fs, in that case you can start with root == (content of boot)/boot, also after that root=/dev/mapper... that mean we have logical FS – Mazeryt Apr 05 '16 at 10:27
1

I had a very similar problem like this. And I believe your problem is caused by the fact that your Xen-Image is ziped and yet you forgot to "insmod gzio" in your menuentry for Xen.

Josai
  • 11
  • 1