From 86a22bd660eaef0c39a6f18696ea70801fe8ed74 Mon Sep 17 00:00:00 2001 From: "Daniel P. Berrange" Date: Mon, 14 Aug 2006 15:53:52 +0000 Subject: [PATCH] Updated notes about HVM devices / boot details --- ChangeLog | 6 ++++++ docs/format.html | 44 ++++++++++++++++++++++++++++++++++++-------- docs/libvir.html | 47 +++++++++++++++++++++++++++++++++++++++-------- 3 files changed, 81 insertions(+), 16 deletions(-) diff --git a/ChangeLog b/ChangeLog index fcd5014a33..4482714db4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Mon Aug 14 10:55:02 EDT 2006 Daniel Berrange + + * docs/libvir.html, docs/format.html: Updated description of + HVM boot device, and disk device configuration to match up + new new behaviour from previous changes + Fri Aug 11 09:37:02 EDT 2006 Daniel Berrange * src/libvirt.c: Avoid duplicated attempts to shutdown or diff --git a/docs/format.html b/docs/format.html index 2749deaf95..af71e9a21b 100644 --- a/docs/format.html +++ b/docs/format.html @@ -99,7 +99,7 @@ systems:

<domain type='xen' id='3'>
   <os>
     <type>hvm</type>
     <loader>/usr/lib/xen/boot/hvmloader</loader>
-    <boot dev='hda'/>
+    <boot dev='da'/>
   </os>
   <memory>524288</memory>
   <vcpu>1</vcpu>
@@ -115,22 +115,50 @@ systems:

<domain type='xen' id='3'>
     </interface>
     <disk type='file'>
       <source file='/root/fv0'/>
-      <target dev='ioemu:hda'/>
+      <target dev='hda'/>
+    </disk>
+    <disk type='file' device='cdrom'>
+      <source file='/root/fc5-x86_64-boot.iso'/>
+      <target dev='hdc'/>
+      <readonly/>
+    </disk>
+    <disk type='file' device='floppy'>
+      <source file='/root/fd.img'/>
+      <target dev='fda'/>
     </disk>
     <graphics type='vnc' port='5904'/>
   </devices>
-</domain>

There is a few things to notice specifically for HVM domains:

  • the <os> block description is very different, first it indicates +</domain>

There is a few things to notice specifically for HVM domains:

  • the <os> block description is very different, first it indicates that the type is 'hvm' for hardware virtualization, then instead of a kernel, boot and command line arguments, it points to an os boot loader which will extract the boot informations from the boot device specified - in a separate boot element
  • -
  • the <devices> section includes an emulator entry pointing to an + in a separate boot element. The dev attribute on the boot + tag can be one of: +
    • fd - boot from first floppy device
    • +
    • hd - boot from first harddisk device
    • +
    • cdrom - boot from first cdrom device
    • +
  • +
  • the <devices> section includes an emulator entry pointing to an additional program in charge of emulating the devices
  • the disk entry indicates in the dev target section that the emulation - for the drive is the first IDE disk device hda
  • -
  • the <devices> section also include at least one entry for the + for the drive is the first IDE disk device hda. The list of device names + supported is dependant on the Hypervisor, but for Xen it can be any IDE + device hda-hdd, or a floppy device fda, + fdb. The <disk> element also supports a 'device' + attribute to indicate what kinda of hardware to emulate. The following values are + supported: +
    • floppy - a floppy disk controller
    • +
    • disk - a generic hard drive (the default it omitted)
    • +
    • cdrom - a CDROM device
    • +
    + For Xen 3.0.2 and earlier a CDROM device can only be emulated on the + hdc channel, while for 3.0.3 and later, it can be emulated on + any IDE channel.
  • +
  • the <devices> section also include at least one entry for the graphic device used to render the os. Currently there is just 2 types - possible 'vnc' or 'sdl'
  • + possible 'vnc' or 'sdl'. If the type is 'vnc', then an additional port + attribute will be present indicating the TCP port on which the VNC server is + accepting client connections.

It is likely that the HVM description gets additional optional elements and attributes as the support for fully virtualized domain expands, especially for the variety of devices emulated and the graphic support diff --git a/docs/libvir.html b/docs/libvir.html index f2534ff063..4ad76554f6 100644 --- a/docs/libvir.html +++ b/docs/libvir.html @@ -423,7 +423,7 @@ systems:

<os> <type>hvm</type> <loader>/usr/lib/xen/boot/hvmloader</loader> - <boot dev='hda'/> + <boot dev='hd'/> </os> <memory>524288</memory> <vcpu>1</vcpu> @@ -439,7 +439,16 @@ systems:

</interface> <disk type='file'> <source file='/root/fv0'/> - <target dev='ioemu:hda'/> + <target dev='hda'/> + </disk> + <disk type='file' device='cdrom'> + <source file='/root/fc5-x86_64-boot.iso'/> + <target dev='hdc'/> + <readonly/> + </disk> + <disk type='file' device='floppy'> + <source file='/root/fd.img'/> + <target dev='fda'/> </disk> <graphics type='vnc' port='5904'/> </devices> @@ -447,18 +456,40 @@ systems:

There is a few things to notice specifically for HVM domains:

    -
  • the <os> block description is very different, first it indicates +
  • the <os> block description is very different, first it indicates that the type is 'hvm' for hardware virtualization, then instead of a kernel, boot and command line arguments, it points to an os boot loader which will extract the boot informations from the boot device specified - in a separate boot element
  • -
  • the <devices> section includes an emulator entry pointing to an + in a separate boot element. The dev attribute on the boot + tag can be one of: +
      +
    • fd - boot from first floppy device
    • +
    • hd - boot from first harddisk device
    • +
    • cdrom - boot from first cdrom device
    • +
    +
  • +
  • the <devices> section includes an emulator entry pointing to an additional program in charge of emulating the devices
  • the disk entry indicates in the dev target section that the emulation - for the drive is the first IDE disk device hda
  • -
  • the <devices> section also include at least one entry for the + for the drive is the first IDE disk device hda. The list of device names + supported is dependant on the Hypervisor, but for Xen it can be any IDE + device hda-hdd, or a floppy device fda, + fdb. The <disk> element also supports a 'device' + attribute to indicate what kinda of hardware to emulate. The following values are + supported: +
      +
    • floppy - a floppy disk controller
    • +
    • disk - a generic hard drive (the default it omitted)
    • +
    • cdrom - a CDROM device
    • +
    + For Xen 3.0.2 and earlier a CDROM device can only be emulated on the + hdc channel, while for 3.0.3 and later, it can be emulated on + any IDE channel.
  • +
  • the <devices> section also include at least one entry for the graphic device used to render the os. Currently there is just 2 types - possible 'vnc' or 'sdl'
  • + possible 'vnc' or 'sdl'. If the type is 'vnc', then an additional port + attribute will be present indicating the TCP port on which the VNC server is + accepting client connections.

It is likely that the HVM description gets additional optional elements