Skip to contentSkip to conversation

HVMAssist BIOS boot device problem

DISCUSSION Stephen Quintero 2 participants 3 messages Jul 8, 2008

lore
Share & tools
lore
#0 lore raw

Hello,

The xm config option boot="c" is intended to boot from the "first" harddrive; however, the enumeration of harddrives is independent of device enumeration (hda|hdb|hdc|hdd), leading to unreliable boot device selection.

Example A:

I am building a Windows HVM appliance which performs file-system level operations over mounted NTFS volumes - for example a file-system level copy.

hda is the boot disk of the appliance and contains a single active (bootable) primary partition. If hdb also contains a single active primary partition, sometimes the appliance boots from hda and properly mounts the hdb partition and sometimes it misfires and boots from the hdb partition, causing a disaster (the contents of hdb are unknown to the appliance prior to boot).

Example B:

Make three copies of a bootable Windows image and set them up as hda, hdb, and hdc. "xm create" boots from the active partition of hda. Shutdown and reorder the devices, switching the images for hda and hdc. "xm create" now boots from the active partition of hdc.

Is there any method to cause an HVM guest to reliably boot from hda?

Any insight would be appreciated.

Thank you,

Stephen Quintero

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw
Quoted 11 lines · Stephen Quintero

Example A:

I am building a Windows HVM appliance which performs file-system level operations over mounted NTFS volumes - for example a file-system level copy.

hda is the boot disk of the appliance and contains a single active (bootable) primary partition. If hdb also contains a single active primary partition, sometimes the appliance boots from hda and properly mounts the hdb partition and sometimes it misfires and boots from the hdb partition, causing a disaster (the contents of hdb are unknown to the appliance prior to boot).

Quoted 8 lines

Example B:

Make three copies of a bootable Windows image and set them up as hda, hdb, and hdc. "xm create" boots from the active partition of hda. Shutdown and reorder the devices, switching the images for hda and hdc. "xm create" now boots from the active partition of hdc.

Is there any method to cause an HVM guest to reliably boot from hda?

Is the selected disc deterministic for any particular config file, or does it change randomly across reboots, with no changes to the guest config file?

-- Keir

#2 lore raw
In reply to Stephen Quintero
Quoted 3 lines · Stephen Quintero

Is there any method to cause an HVM guest to reliably boot from hda?

Any insight would be appreciated.

Reading the BIOS code, my understanding is that 'boot from hard disk' means to boot from the first connected hard drive enumerated in the following
order: primary master, primary slave, secondary master, secondary slave (i.e., hda-hdd). I confirmed this with a few simple tests -- attach a bootable image to hdd boots fine, but if I connect a non-bootable image on any of hha-hdc then the system fails to boot. This is all entirely deterministic. Selection of boot device should not be random, nor change across reboots.

-- Keir