3 xenvm is a single VM monitor. it's a single process that follow the life of
4 a VM, and open a command socket where you can send command, just like xm to xend
6 xenvm expose the uuid of the domain to outside world, so instead of having to
7 refer to the domid of the domain, all outside command use the uuid. the uuid
8 beeing stable, all command will use the same uuid after reboot/suspend/resume
13 you can put the following parameters in your config file:
16 +====================+======+=======================================================+
17 | key name | type | description |
18 +====================+======+=======================================================+
19 | hvm | s | command line given to the kernel |
20 +--------------------+------+-------------------------------------------------------+
21 | startup | s | specify what to do with the domain at startup |
22 | | | possibles value: started, paused, shutdown or |
23 | | | restore <file> |
24 +--------------------+------+-------------------------------------------------------+
25 | debug | b | logs all operations to /tmp/xenvm-debug-%uuid |
26 +--------------------+------+-------------------------------------------------------+
27 | uuid | s | specify the domain uuid (default to autogeneration) |
28 +--------------------+------+-------------------------------------------------------+
29 | on_crash | s | specify the action to be taken after notifying a |
30 | on_halt | s | crash/halt/reboot. possible values: |
31 | on_reboot | s | preserve, reboot, destroy |
32 +--------------------+------+-------------------------------------------------------+
33 | kernel | s | specify where to find the kernel to boot |
34 | | | (can be empty for hvm. default to hvmloader) |
35 +--------------------+------+-------------------------------------------------------+
36 | memory | i | specify the memory given to the guest in megabytes |
37 +--------------------+------+-------------------------------------------------------+
38 | vcpus | i | number of vcpus available to the guest |
39 +--------------------+------+-------------------------------------------------------+
40 | disk | s | add a virtual disk. |
41 | | | format: physpath:phystype:virtpath:mode:devty[:k=v...]|
42 | | | - physpath: path to the disk image, raw device, .. |
43 | | | - phystype: phy | qcow | aio | file | vhd |
44 | | | - virtpath: hd(a-d) | sd(a-.) | xvd(a-p) |
46 | | | - devtype = cdrom | disk |
47 | | | - extra k=v arguments (cipher, key-size, key-file) |
48 +--------------------+------+-------------------------------------------------------+
49 | nic | s | add a virtual nic. |
50 | | | format: key=value,key=value,... (can be empty) |
51 | | | supported key: bridge, mac, id |
53 | | | "nic = bridge=xen-br0,mac=ab:de:fe:dc:ba:ab" |
54 | | | "nic = mac=ab:de:fe:dc:ba:ab" |
56 +--------------------+------+-------------------------------------------------------+
57 | pci | s | add a pci device. |
58 | | | format: devid,bind,domain:bus:device.function |
60 +--------------------+------+-------------------------------------------------------+
61 | serial | s | redirect serial to device or network tcp:ip:port |
62 | | | ex: "pty" or "tcp:1.2.3.4:1234" |
63 +--------------------+------+-------------------------------------------------------+
64 | display | s | details the type of display available for the guest |
65 | | | format: <protocol>:key[=value],key[=value],... |
66 | | | possible values: |
68 | | | - vnc (keys allowed: use-port-unused, keymap, port) |
71 +--------------------+------+-------------------------------------------------------+
74 (the following are just useful for pv)
75 +====================+======+=======================================================+
76 | key name | type | description |
77 +====================+======+=======================================================+
78 | cmdline | s | command line given to the kernel |
79 +--------------------+------+-------------------------------------------------------+
80 | initrd | s | specify the initrd use, leave empty for none |
81 +--------------------+------+-------------------------------------------------------+
84 (the following are just useful for hvm)
86 +====================+======+=======================================================+
87 | key name | type | description |
88 +====================+======+=======================================================+
89 | pae | b | specify that the guest is using PAE |
90 +--------------------+------+-------------------------------------------------------+
91 | acpi | b | specify that the guest is using ACPI |
92 +--------------------+------+-------------------------------------------------------+
93 | apic | b | specify that the guest is using APIC |
94 +--------------------+------+-------------------------------------------------------+
95 | nx | b | specify that the guest is using NX |
96 +--------------------+------+-------------------------------------------------------+
97 | smbios-pt | b | specify that the guest is using smbios pass-through |
98 +--------------------+------+-------------------------------------------------------+
99 | smbios-oem-type-pt | i, | tables number to passthrough |
100 +--------------------+------+-------------------------------------------------------+
101 | acpi-pt | b | specify that the guest is using ACPI pass-through |
102 +--------------------+------+-------------------------------------------------------+
103 | diskinfo-pt | b | specify the guest is using SCSI diskinfo pass-through |
104 +--------------------+------+-------------------------------------------------------+
105 | boot | s | specify the qemu boot string |
106 +--------------------+------+-------------------------------------------------------+
107 | extra-hvm | k=v, | specify extra arguments passthrough to qemu as -k v |
108 +--------------------+------+-------------------------------------------------------+
109 | power-management | i | specify the power management passthrough mode |
110 | | | - 1 : pass-through mode (limited scope) |
111 | | | - 2 : non pass-through mode (in doubt use this) |
112 +--------------------+------+-------------------------------------------------------+
113 | oem-features | i | specify whether or not to pass through oem features. |
114 | | | Note: At the moment any integer value can be passed |
115 | | | but this is likely to change in future especially if |
116 | | | we decide to pass through a subset of oem features |
117 | | | and let user configure that subset. |
118 +--------------------+------+-------------------------------------------------------+
119 | timer-mode | i | specify the timer mode used. |
120 +--------------------+------+-------------------------------------------------------+
121 | timeoffset | s | specify the time offset (i.e. timezone) used. |
122 +--------------------+------+-------------------------------------------------------+
123 | pci-msitranslate | i | specify whether to use MSI-INTx translation for guest.|
124 +--------------------+------+-------------------------------------------------------+
125 |pci-power-management| i | specify whether or not to enable Dx power management |
126 | | | for passthrough devices. |
127 +--------------------+------+-------------------------------------------------------+
128 | inject-sci | i | specify whether or not to inject SCIs like lid close, |
129 | | | power button press to guest. (Default: no injection) |
130 +--------------------+------+-------------------------------------------------------+
133 = Sending command to the monitor
135 xenvm bind a unix socket to the uuid specified/generated
136 You can easily send command to the monitor with xenvm-cmd using the simple
139 xenvm-cmd <uuid> <cmds> <args>
141 The following command are supported:
148 - suspend file=<file>
149 - suspend file=<file> live=true
150 - restore file=<file>
154 - quit (quit the monitor leaving the vm untouched)
156 = Running with xen-unstable
158 It's possible to run with xen-unstable directly, but you need the
159 qemu-dm-wrapper script and xenguest binary in /usr/bin/.
160 They are available in xenguest/xenguest and scripts/qemu-dm-wrapper
161 in the toolstack.git repository.
163 And you need to replace your udev rules by the one available in
164 scripts/xen-backend.rules and scripts/xen-frontend.rules and add the
165 scripts/tap scripts/block scripts/block-front scripts/vif into
166 /etc/xensource/scripts/
168 Also note that since xen-unstable doesn't have the dm-ready patch,
169 hvm domain takes unfortunately a substantial time (around 20s.) to start.
173 PV config with one LVM disk called 'test' and one VIF :
176 uuid = 00000000-0000-0000-0000-000000000001
178 kernel = /boot/vmlinuz-2.6.18-xenU
179 cmdline = root=/dev/sda1 ro
181 disk = /dev/vg/test:phy:sda:w:disk
185 HVM config for installing a windows 2k3 from iso on a LVM disk called 'testhvm':
188 uuid = 00000000-0000-0000-0000-000000000002
191 disk = /dev/vg/testhvm:phy:hda:w:disk
192 disk = /var/opt/xen/iso_import/w2k3eesp2.iso:file:hdd:r:cdrom