WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] xen 4.0-testing: cannot install grub in debian domU (bo

2010/6/27 Niccolò Belli <darkbasic4@xxxxxxxxx>:
> Il 26 giugno 2010 17.51, Bruce Edge <bruce.edge@xxxxxxxxx> ha scritto:
>> I would assume you would need to mount the root .img via loopback, chroot
>> into it, and install form there
>
> I have to specify the offset when I loopback mount the image, so I
> will not be able to install it in the mbr but just in the first
> partition.
> Also I want the domU able to install the bootloader because I want it
> to automatically update the grub config (menu.lst) to boot the latest
> kernel installed.

I don't follow your logic from the commands you run earlier (did you
run fdisk? install debian domU first? chroot?). However it doesn't
really matter for PV domU. PV domU does not need grub to be installed
to MBR/partition for pygrub to work. It simply needs
/boot/grub/menu.lst (for grub) with the correct entries.

As for "automatically update the grub config (menu.lst) to boot the
latest kernel installed", you really only need these lines on
kernel-img.conf (on Ubuntu anyway. might be the same on debian) which
should exist already on a normal installation:

do_initrd = yes
postinst_hook = update-grub
postrm_hook   = update-grub

Now, for HVM, it's slightly different. You REALLY need it installed to
/dev/sda. If you install Debian as HVM using the install CD, it
already does that automatically. If you want to install it manually
after that, you can:
- boot with a live CD (I like sysrescuecd)
- mount all the necessar partitions ( "/", /boot, and possible others)
- bind-mount /dev, /dev/pts/, /sys, and /proc to the mounted root
- chroot
- possibly edit /etc/mtab
- grub-install /dev/sda

-- 
Fajar

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users