Jump to: navigation, search

Using QEMU Disk Images for Xen DomainU Systems

3 bytes added, 18:31, 28 March 2009
no edit summary
In earlier chapters we have looked at using raw disk images and physical disks as filesystems for a Xen based domainU. Another option is to use the disk images used by QEMU. In this chapter we will cover the steps necessary to create a QEMU disk image, install an operating system into it and then use ''pygrub'' to boot the system as a Xen guest system (domainU).
== Creating a QEMU Disk Image for the Xen domainU ==
The first step in the process of using QEMU disk images with Xen is to create a disk image. This is achieved using the ''qemu-img'' tool. QEMU supports a number of different image types. For this the purposes of this chapter we will use the ''raw'' type which is the standard and portable disk image used by QEMU by default. The following command-line created creates a new QEMU 4Gb 4GB disk image called ''XenQemu.img'':
== Installing the Guest Operating System ==
At this point we have a raw QEMU disk image which is ready to have an operating system installed within it. In order to install the operating system we will use the QEMU emulator to boot and install from a Linux installation CD. In order to boot from the CDROM drive we need to tell QEMU the CDROM device on the host system (in this case it is /dev/hdc but will be different depending on the Linux distribution and hardware configuration0 configuration) together with the ''-boot d'' command-line argument. Finally, we need to reference the QEMU disk image created above with the ''-hda'' flag and the amount of memory to be allocated using ''-m'':

Navigation menu