mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-01-22 22:03:58 +03:00
tests: Drop a bunch of redundant xmlparse/xmlconfig tests
For the few bits we are hitting specific code paths, break them out or fold them into other test cases Signed-off-by: Cole Robinson <crobinso@redhat.com>
This commit is contained in:
parent
1b93c17564
commit
0ac9ff3488
@ -1,51 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<memory>409600</memory>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<vcpu>5</vcpu>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
</features>
|
||||
<clock offset="utc">
|
||||
<timer name="rtc" tickpolicy="catchup"/>
|
||||
<timer name="pit" tickpolicy="delay"/>
|
||||
<timer name="hpet" present="no"/>
|
||||
</clock>
|
||||
<devices>
|
||||
<emulator>/usr/libexec/qemu-kvm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<driver name="qemu" type="qcow2"/>
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/dev/default-pool/new-test-suite.img"/>
|
||||
<target dev="vda" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<driver name="qemu" type="raw" cache="none" io="native"/>
|
||||
<source dev="/dev/disk-pool/diskvol1"/>
|
||||
<target dev="vdb" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="file" device="cdrom">
|
||||
<target dev="hda" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
<model type="virtio"/>
|
||||
</interface>
|
||||
<console type="pty"/>
|
||||
<input type="tablet" bus="usb"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
<sound model="ac97"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,49 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<memory>409600</memory>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<vcpu>5</vcpu>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="cdrom"/>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>destroy</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<source file="/dev/default-pool/new-test-suite.img"/>
|
||||
<target dev="hda" bus="ide"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/disk-pool/diskvol1"/>
|
||||
<target dev="hdb" bus="ide"/>
|
||||
</disk>
|
||||
<disk type="file" device="cdrom">
|
||||
<source file="/dev/null"/>
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
</interface>
|
||||
<input type="tablet" bus="usb"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
<console type="pty"/>
|
||||
<sound model="es1370"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,55 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type='block' device='disk'>
|
||||
<source dev='/dev/HostVG/QEMUGuest1'/>
|
||||
<target dev='hda' bus='ide'/>
|
||||
<address type='drive' controller='3' bus='5' unit='33'/>
|
||||
<alias name='foo2'/>
|
||||
</disk>
|
||||
<disk type='block' device='disk'>
|
||||
<source dev='/dev/HostVG/QEMUGuest2'/>
|
||||
<target dev='hdb' bus='ide'/>
|
||||
<address type='drive' controller='4' bus='5' unit='33'/>
|
||||
</disk>
|
||||
<controller type='scsi' index='8'>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x7'/>
|
||||
</controller>
|
||||
<channel type='pty'>
|
||||
<target type='virtio' name='org.linux-kvm.port.wizz'/>
|
||||
<address type='virtio-serial' controller='0' bus='0' port='2'/>
|
||||
<alias name='channel0'/>
|
||||
</channel>
|
||||
<smartcard mode='host'>
|
||||
<address type='ccid' controller='0' slot='0'/>
|
||||
</smartcard>
|
||||
<memory model='nvdimm' access='private'>
|
||||
<source>
|
||||
<path>/tmp/nvdimm</path>
|
||||
</source>
|
||||
<target>
|
||||
<size unit='KiB'>523264</size>
|
||||
<node>0</node>
|
||||
<label>
|
||||
<size unit='KiB'>128</size>
|
||||
</label>
|
||||
</target>
|
||||
<address type='dimm' slot='0'/>
|
||||
</memory>
|
||||
</devices>
|
||||
</domain>
|
@ -1,41 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/HostVG/QEMUGuest1"/>
|
||||
<target dev="hda" bus="ide"/>
|
||||
<address type="drive" controller="1" bus="4" unit="32" target="7"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/HostVG/QEMUGuest2"/>
|
||||
<target dev="hdb" bus="ide"/>
|
||||
</disk>
|
||||
<controller type="scsi" index="8">
|
||||
<address type="pci" domain="1" bus="4" slot="10" function="6"/>
|
||||
<alias name="frob"/>
|
||||
</controller>
|
||||
<channel type="pty">
|
||||
<target type="virtio" name="org.linux-kvm.port.wizz"/>
|
||||
<address type="virtio-serial" controller="0" bus="0" port="4"/>
|
||||
<alias name="channel1"/>
|
||||
</channel>
|
||||
<smartcard mode="host">
|
||||
<address type="ccid" controller="0" slot="0"/>
|
||||
</smartcard>
|
||||
</devices>
|
||||
</domain>
|
@ -1,24 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">linux</type>
|
||||
<kernel>/boot/vmlinuz</kernel>
|
||||
<initrd>/boot/initrd</initrd>
|
||||
<cmdline>location</cmdline>
|
||||
</os>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>destroy</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="xvda" bus="xen"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="xen"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,24 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">linux</type>
|
||||
<boot dev="network"/>
|
||||
<boot dev="hd"/>
|
||||
<boot dev="fd"/>
|
||||
</os>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>destroy</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="xvda" bus="xen"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="xen"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,33 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
<boot dev="fd"/>
|
||||
<boot dev="cdrom"/>
|
||||
<boot dev="network"/>
|
||||
<bootmenu enable="no"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="disk">
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="hda" bus="ide"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,36 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<bootmenu enable="yes"/>
|
||||
<kernel>/foo.img</kernel>
|
||||
<initrd>/bar.img</initrd>
|
||||
<cmdline>ks=foo.ks</cmdline>
|
||||
<dtb>/baz.dtb</dtb>
|
||||
<boot dev="cdrom"/>
|
||||
<initarg>baz</initarg>
|
||||
<initarg>wibble</initarg>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="disk">
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="hda" bus="ide"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,24 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">linux</type>
|
||||
<kernel>/boot/vmlinuz</kernel>
|
||||
<initrd>/boot/initrd</initrd>
|
||||
<cmdline>location</cmdline>
|
||||
</os>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>destroy</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="xvda" bus="xen"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="xen"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,26 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">linux</type>
|
||||
<loader readonly="yes" type="pflash">OVMF_CODE.fd</loader>
|
||||
<nvram template="/tmp/template">/tmp/nvram_store</nvram>
|
||||
<boot dev="network"/>
|
||||
<boot dev="hd"/>
|
||||
<boot dev="fd"/>
|
||||
</os>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>destroy</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<disk type="block" device="disk">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="xvda" bus="xen"/>
|
||||
</disk>
|
||||
<input type="mouse" bus="xen"/>
|
||||
<graphics type="vnc" port="-1" keymap="ja"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,59 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<filesystem>
|
||||
<driver type='handle'/>
|
||||
<source dir='/foo/bar'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='template'>
|
||||
<source name='template_fedora'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='mount' accessmode='squash'>
|
||||
<driver type='path' wrpolicy='immediate'/>
|
||||
<source dir='/foo/bar'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='mount' accessmode='mapped'>
|
||||
<driver type='path'/>
|
||||
<source dir='/foo/bar'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='ram'>
|
||||
<source usage='1024' units='MB'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='block'>
|
||||
<source dev='/foo/bar'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
<filesystem type='file' accessmode='passthrough'>
|
||||
<driver type='nbd' format='qcow'/>
|
||||
<source file='/foo/bar.img'/>
|
||||
<target dir='/bar/baz'/>
|
||||
</filesystem>
|
||||
</devices>
|
||||
</domain>
|
@ -1,62 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<filesystem type="mount" accessmode="passthrough">
|
||||
<source dir="/new/path"/>
|
||||
<target dir="/new/target"/>
|
||||
</filesystem>
|
||||
<filesystem type="template" accessmode="mapped">
|
||||
<source name="template_new"/>
|
||||
<target dir="/bar/baz"/>
|
||||
</filesystem>
|
||||
<filesystem>
|
||||
<driver type="handle"/>
|
||||
<source dir="/foo/bar"/>
|
||||
<target dir="/bar/baz"/>
|
||||
<readonly/>
|
||||
</filesystem>
|
||||
<filesystem>
|
||||
<driver type="handle" wrpolicy="immediate"/>
|
||||
<source dir="/foo/bar"/>
|
||||
<target dir="/bar/baz"/>
|
||||
<readonly/>
|
||||
</filesystem>
|
||||
<filesystem type="ram">
|
||||
<source usage="123" units="KiB"/>
|
||||
<target dir="/bar/baz"/>
|
||||
</filesystem>
|
||||
<filesystem type="file">
|
||||
<source dev="/dev/new" file="/dev/new"/>
|
||||
<target dir="/bar/baz"/>
|
||||
<readonly/>
|
||||
</filesystem>
|
||||
<filesystem type="file">
|
||||
<driver type="loop" format="raw"/>
|
||||
<source file="/foo/bar.raw"/>
|
||||
<target dir="/bar/baz"/>
|
||||
<readonly/>
|
||||
</filesystem>
|
||||
</devices>
|
||||
</domain>
|
@ -1,49 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<graphics type="vnc" passwd="foobar" port="100" listen="0.0.0.0"/>
|
||||
<graphics type="vnc" xauth="/tmp/.Xauthority" display="1:2"/>
|
||||
<graphics type="rdp" listen='1.1.2.3'>
|
||||
<listen type='address' address='1.1.2.3'/>
|
||||
</graphics>
|
||||
<graphics type="vnc" port="-1" socket="/tmp/foobar"/>
|
||||
<graphics type="vnc" autoport="yes">
|
||||
<listen type='network' network='Bobsnetwork'/>
|
||||
</graphics>
|
||||
<graphics type="spice" passwd="foobar" port="100" tlsPort="101" listen="0.0.0.0" passwdValidTo="2010-04-09T15:51:00">
|
||||
<listen type='address' address='0.0.0.0'/>
|
||||
<channel name='inputs' mode='insecure'/>
|
||||
<channel name='main' mode='secure'/>
|
||||
<channel name='record' mode='any'/>
|
||||
<channel name='cursor' mode='any'/>
|
||||
<channel name='playback' mode='any'/>
|
||||
<channel name='display' mode='any'/>
|
||||
</graphics>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,52 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<graphics type="vnc" passwd="newpass" port="6000" listen="1.2.3.4" keymap="en-us"/>
|
||||
<graphics type="vnc" xauth="fooauth" display="6:1"/>
|
||||
<graphics type="vnc"/>
|
||||
<graphics type="vnc" port="-1" socket="/var/lib/libvirt/socket/foo"/>
|
||||
<graphics type="vnc" autoport="no">
|
||||
<listen type="network" network="mynewnet"/>
|
||||
</graphics>
|
||||
<graphics type="spice" passwd="newpass" port="6000" tlsPort="6001" listen="1.2.3.4" passwdValidTo="2011-01-07T19:08:00" connected="disconnect" defaultMode="secure">
|
||||
<channel name="inputs" mode="secure"/>
|
||||
<channel name="main" mode="any"/>
|
||||
<channel name="record" mode="insecure"/>
|
||||
<channel name="cursor" mode="any"/>
|
||||
<channel name="playback" mode="insecure"/>
|
||||
<channel name="display" mode="secure"/>
|
||||
<gl enable="yes" rendernode="/dev/dri/foo"/>
|
||||
<image compression="auto_glz"/>
|
||||
<streaming mode="filter"/>
|
||||
<clipboard copypaste="yes"/>
|
||||
<mouse mode="client"/>
|
||||
<filetransfer enable="no"/>
|
||||
</graphics>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,62 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="network"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<hostdev mode="subsystem" type="usb" managed="yes">
|
||||
<source>
|
||||
<vendor id="0x4321"/>
|
||||
<product id="0x1234"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="usb" managed="no">
|
||||
<source>
|
||||
<address bus="0x12" device="0x34"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="subsystem" type="pci" managed="yes">
|
||||
<source>
|
||||
<address domain="0x0" bus="0x1" slot="0x2" function="0x3"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="subsystem" type="scsi" managed="no">
|
||||
<source>
|
||||
<adapter name="scsi_host0"/>
|
||||
<address bus="0" target="0" unit="0"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="net" managed="yes">
|
||||
<source>
|
||||
<interface>wlan0</interface>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="misc" managed="yes">
|
||||
<source>
|
||||
<char>/dev/net/tun</char>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="storage" managed="yes">
|
||||
<source>
|
||||
<block>/dev/sdf</block>
|
||||
</source>
|
||||
</hostdev>
|
||||
</devices>
|
||||
</domain>
|
@ -1,65 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="network"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<hostdev type="usb" managed="no">
|
||||
<source>
|
||||
<vendor id="0x1111"/>
|
||||
<product id="0x2222"/>
|
||||
<address bus="1" device="2"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="subsystem" type="usb" managed="yes">
|
||||
<source>
|
||||
<address bus="0x56" device="0x78"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="subsystem" type="pci" managed="yes">
|
||||
<source>
|
||||
<address domain="0x4" bus="0x5" slot="0x6" function="0x7"/>
|
||||
</source>
|
||||
<driver name="vfio"/>
|
||||
<rom bar="on"/>
|
||||
</hostdev>
|
||||
<hostdev mode="subsystem" type="scsi" managed="no">
|
||||
<source>
|
||||
<adapter name="foo"/>
|
||||
<address bus="1" target="2" unit="3"/>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="net" managed="yes">
|
||||
<source>
|
||||
<interface>eth0</interface>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="misc" managed="yes">
|
||||
<source>
|
||||
<char>/dev/null</char>
|
||||
</source>
|
||||
</hostdev>
|
||||
<hostdev mode="capabilities" type="storage" managed="yes">
|
||||
<source>
|
||||
<block>/dev/fd0</block>
|
||||
</source>
|
||||
</hostdev>
|
||||
</devices>
|
||||
</domain>
|
@ -1,25 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<input type="tablet" bus="usb"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,25 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<input type="tablet" bus="usb"/>
|
||||
<input type="mouse" bus="usb"/>
|
||||
</devices>
|
||||
</domain>
|
@ -1,18 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<vcpu cpuset="1-3">4</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
</devices>
|
||||
</domain>
|
@ -1,30 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<vcpu cpuset="1-3">4</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
</devices>
|
||||
<features>
|
||||
<acpi/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<cpu mode="custom" match="exact">
|
||||
<topology cores="4" sockets="1" threads="1"/>
|
||||
<model fallback="allow">foobar</model>
|
||||
<feature policy="forbid" name="x2apic"/>
|
||||
</cpu>
|
||||
<seclabel type="static" model="testSecurity">
|
||||
<label>frob</label>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,62 +0,0 @@
|
||||
<domain type='kvm'>
|
||||
<name>Ftest</name>
|
||||
<uuid>9d544d2e-e001-a6b2-4aa7-7768796353ea</uuid>
|
||||
<memory unit='KiB'>1048576</memory>
|
||||
<currentMemory unit='KiB'>1048576</currentMemory>
|
||||
<vcpu placement='static'>1</vcpu>
|
||||
<os>
|
||||
<type arch='i686' machine='pc-i440fx-1.4'>hvm</type>
|
||||
<boot dev='hd'/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
<pae/>
|
||||
</features>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/local/bin/qemu-system-x86_64</emulator>
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw'/>
|
||||
<source file='/home/IMG/F19_test.img'/>
|
||||
<target dev='hda' bus='ide'/>
|
||||
</disk>
|
||||
<controller type='usb' index='0'>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
|
||||
</controller>
|
||||
<controller type='pci' index='0' model='pci-root'/>
|
||||
<controller type='ide' index='0'>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
|
||||
</controller>
|
||||
<controller type='virtio-serial' index='0'>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
|
||||
</controller>
|
||||
<interface type='network'>
|
||||
<mac address='52:54:00:93:45:ce'/>
|
||||
<source network='default'/>
|
||||
<model type='rtl8139'/>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
|
||||
</interface>
|
||||
<serial type='pty'>
|
||||
<target port='0'/>
|
||||
</serial>
|
||||
<console type='pty'>
|
||||
<target type='serial' port='0'/>
|
||||
</console>
|
||||
<input type='mouse' bus='ps2'/>
|
||||
<graphics type='vnc' port='-1' autoport='yes'/>
|
||||
<video>
|
||||
<model type='vga' vram='9216' heads='1'/>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
|
||||
</video>
|
||||
<memballoon model='virtio'>
|
||||
<address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
|
||||
</memballoon>
|
||||
<panic>
|
||||
<address type='isa' iobase='0x505'/>
|
||||
</panic>
|
||||
</devices>
|
||||
</domain>
|
@ -1,62 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>Ftest</name>
|
||||
<uuid>9d544d2e-e001-a6b2-4aa7-7768796353ea</uuid>
|
||||
<memory unit="KiB">1048576</memory>
|
||||
<currentMemory unit="KiB">1048576</currentMemory>
|
||||
<vcpu placement="static">1</vcpu>
|
||||
<os>
|
||||
<type arch="i686" machine="pc-i440fx-1.4">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/>
|
||||
<apic/>
|
||||
<pae/>
|
||||
</features>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<devices>
|
||||
<emulator>/usr/local/bin/qemu-system-x86_64</emulator>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/home/IMG/F19_test.img"/>
|
||||
<target dev="hda" bus="ide"/>
|
||||
</disk>
|
||||
<controller type="usb" index="0">
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x01" function="0x2"/>
|
||||
</controller>
|
||||
<controller type="pci" index="0" model="pci-root"/>
|
||||
<controller type="ide" index="0">
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x01" function="0x1"/>
|
||||
</controller>
|
||||
<controller type="virtio-serial" index="0">
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x04" function="0x0"/>
|
||||
</controller>
|
||||
<interface type="network">
|
||||
<mac address="52:54:00:93:45:ce"/>
|
||||
<source network="default"/>
|
||||
<model type="rtl8139"/>
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x03" function="0x0"/>
|
||||
</interface>
|
||||
<serial type="pty">
|
||||
<target port="0"/>
|
||||
</serial>
|
||||
<console type="pty">
|
||||
<target type="serial" port="0"/>
|
||||
</console>
|
||||
<input type="mouse" bus="ps2"/>
|
||||
<graphics type="vnc" port="-1" autoport="yes"/>
|
||||
<video>
|
||||
<model type="vga" vram="9216" heads="1"/>
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x02" function="0x0"/>
|
||||
</video>
|
||||
<memballoon model="virtio">
|
||||
<address type="pci" domain="0x0000" bus="0x00" slot="0x05" function="0x0"/>
|
||||
</memballoon>
|
||||
<panic>
|
||||
<address type="isa" iobase="0x506"/>
|
||||
</panic>
|
||||
</devices>
|
||||
</domain>
|
@ -1,65 +0,0 @@
|
||||
<domain type='kvm'>
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch='i686' machine='foobar'>hvm</type>
|
||||
<boot dev='hd'/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match='exact'>
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets='4' cores='5' threads='2'/>
|
||||
<feature policy='force' name='x2apic'/>
|
||||
<feature policy='forbid' name='lahf_lm'/>
|
||||
</cpu>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset='1-3'>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type='file' device='floppy'>
|
||||
<driver name='qemu' type='qcow2'/>
|
||||
<source file='/dev/default-pool/testvol1.img'/>
|
||||
<target dev='fda' bus='fdc'/>
|
||||
</disk>
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw'/>
|
||||
<source file='/tmp/test.img'/>
|
||||
<target dev='vda' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='disk'>
|
||||
<driver name='qemu'/>
|
||||
<source dev='/dev/null'/>
|
||||
<target dev='vdb' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='cdrom'>
|
||||
<target dev='hdc' bus='ide'/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type='network'>
|
||||
<source network='default'/>
|
||||
<mac address='22:22:33:44:55:66'/>
|
||||
<model type='virtio'/>
|
||||
</interface>
|
||||
<graphics type='vnc' display=':3.4' xauth='/tmp/.Xauthority'/>
|
||||
<console type='pty'/>
|
||||
<rng model='virtio'>
|
||||
<rate period='2000' bytes='1234'/>
|
||||
<backend model='egd' type='udp'>
|
||||
<source mode='bind' service='1233'/>
|
||||
<source mode='connect' host='1.2.3.4' service='1234'/>
|
||||
</backend>
|
||||
</rng>
|
||||
</devices>
|
||||
<seclabel type='static' model='selinux'>
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,65 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match="exact">
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets="4" cores="5" threads="2"/>
|
||||
<feature policy="force" name="x2apic"/>
|
||||
<feature policy="forbid" name="lahf_lm"/>
|
||||
</cpu>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset="1-3">5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<driver name="qemu" type="qcow2"/>
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="vda" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<driver name="qemu"/>
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="vdb" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
<model type="virtio"/>
|
||||
</interface>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<rng model="virtio">
|
||||
<rate period="2001" bytes="4321"/>
|
||||
<backend model="egd" type="udp">
|
||||
<source mode="bind" service="1236"/>
|
||||
<source mode="connect" host="1.2.3.5" service="1235"/>
|
||||
</backend>
|
||||
</rng>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,61 +0,0 @@
|
||||
<domain type='kvm'>
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch='i686' machine='foobar'>hvm</type>
|
||||
<boot dev='hd'/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match='exact'>
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets='4' cores='5' threads='2'/>
|
||||
<feature policy='force' name='x2apic'/>
|
||||
<feature policy='forbid' name='lahf_lm'/>
|
||||
</cpu>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset='1-3'>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type='file' device='floppy'>
|
||||
<driver name='qemu' type='qcow2'/>
|
||||
<source file='/dev/default-pool/testvol1.img'/>
|
||||
<target dev='fda' bus='fdc'/>
|
||||
</disk>
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw'/>
|
||||
<source file='/tmp/test.img'/>
|
||||
<target dev='vda' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='disk'>
|
||||
<driver name='qemu'/>
|
||||
<source dev='/dev/null'/>
|
||||
<target dev='vdb' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='cdrom'>
|
||||
<target dev='hdc' bus='ide'/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type='network'>
|
||||
<source network='default'/>
|
||||
<mac address='22:22:33:44:55:66'/>
|
||||
<model type='virtio'/>
|
||||
</interface>
|
||||
<graphics type='vnc' display=':3.4' xauth='/tmp/.Xauthority'/>
|
||||
<console type='pty'/>
|
||||
<rng model='virtio'>
|
||||
<backend model='random'>/dev/random</backend>
|
||||
</rng>
|
||||
</devices>
|
||||
<seclabel type='static' model='selinux'>
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,61 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match="exact">
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets="4" cores="5" threads="2"/>
|
||||
<feature policy="force" name="x2apic"/>
|
||||
<feature policy="forbid" name="lahf_lm"/>
|
||||
</cpu>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset="1-3">5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<driver name="qemu" type="qcow2"/>
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="vda" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<driver name="qemu"/>
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="vdb" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
<model type="virtio"/>
|
||||
</interface>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<rng model="virtio">
|
||||
<backend model="random">/dev/hwrng</backend>
|
||||
</rng>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,19 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
<seclabel type='none' relabel='no'/>
|
||||
<seclabel type='dynamic' model='dac' relabel='yes'/>
|
||||
</domain>
|
@ -1,19 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
</devices>
|
||||
<seclabel type="none" model="apparmor" relabel="no">
|
||||
<label>barlabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
<baselabel>baselabel</baselabel>
|
||||
</seclabel>
|
||||
<seclabel type="dynamic" model="dac" relabel="yes"/>
|
||||
</domain>
|
@ -1,69 +0,0 @@
|
||||
<domain type='kvm'>
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch='i686' machine='foobar'>hvm</type>
|
||||
<boot dev='hd'/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match='exact'>
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets='4' cores='5' threads='2'/>
|
||||
<feature policy='force' name='x2apic'/>
|
||||
<feature policy='forbid' name='lahf_lm'/>
|
||||
</cpu>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset='1-3'>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type='file' device='floppy'>
|
||||
<driver name='qemu' type='qcow2'/>
|
||||
<source file='/dev/default-pool/testvol1.img'/>
|
||||
<target dev='fda' bus='fdc'/>
|
||||
</disk>
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw'/>
|
||||
<source file='/tmp/test.img'/>
|
||||
<target dev='vda' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='disk'>
|
||||
<driver name='qemu'/>
|
||||
<source dev='/dev/null'/>
|
||||
<target dev='vdb' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='cdrom'>
|
||||
<target dev='hdc' bus='ide'/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type='network'>
|
||||
<source network='default'/>
|
||||
<mac address='22:22:33:44:55:66'/>
|
||||
<model type='virtio'/>
|
||||
</interface>
|
||||
<graphics type='vnc' display=':3.4' xauth='/tmp/.Xauthority'/>
|
||||
<console type='pty'/>
|
||||
<smartcard mode='host'>
|
||||
</smartcard>
|
||||
<smartcard mode='passthrough' type='spicevmc'>
|
||||
</smartcard>
|
||||
<smartcard mode='passthrough' type='tcp'>
|
||||
<source mode='bind' host='127.0.0.1' service='2001'/>
|
||||
<protocol type='raw'/>
|
||||
</smartcard>
|
||||
<smartcard mode='passthrough' type='unix'>
|
||||
<source mode='bind' path='/tmp/smartcard.sock'/>
|
||||
</smartcard>
|
||||
</devices>
|
||||
<seclabel type='static' model='selinux'>
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,69 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match="exact">
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets="4" cores="5" threads="2"/>
|
||||
<feature policy="force" name="x2apic"/>
|
||||
<feature policy="forbid" name="lahf_lm"/>
|
||||
</cpu>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset="1-3">5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<driver name="qemu" type="qcow2"/>
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="vda" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<driver name="qemu"/>
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="vdb" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
<model type="virtio"/>
|
||||
</interface>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<smartcard mode="host" type="tcp">
|
||||
</smartcard>
|
||||
<smartcard mode="host">
|
||||
</smartcard>
|
||||
<smartcard mode="passthrough" type="tcp">
|
||||
<source mode="bind" host="127.0.0.1" service="2001"/>
|
||||
<protocol type="telnet"/>
|
||||
</smartcard>
|
||||
<smartcard mode="passthrough" type="unix">
|
||||
<source mode="bind" path="/tmp/smartcard.sock"/>
|
||||
</smartcard>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,34 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<sound model="sb16"/>
|
||||
<sound model="es1370"/>
|
||||
<sound model="ac97"/>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,34 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<sound model="ac97"/>
|
||||
<sound model="es1370"/>
|
||||
<sound model="sb16"/>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,63 +0,0 @@
|
||||
<domain type='kvm'>
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch='i686' machine='foobar'>hvm</type>
|
||||
<boot dev='hd'/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match='exact'>
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets='4' cores='5' threads='2'/>
|
||||
<feature policy='force' name='x2apic'/>
|
||||
<feature policy='forbid' name='lahf_lm'/>
|
||||
</cpu>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset='1-3'>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type='file' device='floppy'>
|
||||
<driver name='qemu' type='qcow2'/>
|
||||
<source file='/dev/default-pool/testvol1.img'/>
|
||||
<target dev='fda' bus='fdc'/>
|
||||
</disk>
|
||||
<disk type='file' device='disk'>
|
||||
<driver name='qemu' type='raw'/>
|
||||
<source file='/tmp/test.img'/>
|
||||
<target dev='vda' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='disk'>
|
||||
<driver name='qemu'/>
|
||||
<source dev='/dev/null'/>
|
||||
<target dev='vdb' bus='virtio'/>
|
||||
</disk>
|
||||
<disk type='block' device='cdrom'>
|
||||
<target dev='hdc' bus='ide'/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type='network'>
|
||||
<source network='default'/>
|
||||
<mac address='22:22:33:44:55:66'/>
|
||||
<model type='virtio'/>
|
||||
</interface>
|
||||
<graphics type='vnc' display=':3.4' xauth='/tmp/.Xauthority'/>
|
||||
<console type='pty'/>
|
||||
<tpm model='tpm-tis'>
|
||||
<backend type='passthrough'>
|
||||
<device path='/dev/tpm0'/>
|
||||
</backend>
|
||||
</tpm>
|
||||
</devices>
|
||||
<seclabel type='static' model='selinux'>
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,63 +0,0 @@
|
||||
<domain type="kvm">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<os>
|
||||
<type arch="i686" machine="foobar">hvm</type>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<cpu match="exact">
|
||||
<model>footest</model>
|
||||
<vendor>Intel</vendor>
|
||||
<topology sockets="4" cores="5" threads="2"/>
|
||||
<feature policy="force" name="x2apic"/>
|
||||
<feature policy="forbid" name="lahf_lm"/>
|
||||
</cpu>
|
||||
<clock offset="utc"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu cpuset="1-3">5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="file" device="floppy">
|
||||
<driver name="qemu" type="qcow2"/>
|
||||
<source file="/dev/default-pool/testvol1.img"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<disk type="file" device="disk">
|
||||
<driver name="qemu" type="raw"/>
|
||||
<source file="/tmp/test.img"/>
|
||||
<target dev="vda" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="disk">
|
||||
<driver name="qemu"/>
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="vdb" bus="virtio"/>
|
||||
</disk>
|
||||
<disk type="block" device="cdrom">
|
||||
<target dev="hdc" bus="ide"/>
|
||||
<readonly/>
|
||||
</disk>
|
||||
<interface type="network">
|
||||
<source network="default"/>
|
||||
<mac address="22:22:33:44:55:66"/>
|
||||
<model type="virtio"/>
|
||||
</interface>
|
||||
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
||||
<console type="pty"/>
|
||||
<tpm model="tpm-tis">
|
||||
<backend type="passthrough">
|
||||
<device path="frob"/>
|
||||
</backend>
|
||||
</tpm>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,36 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<video>
|
||||
<model type="vmvga"/>
|
||||
</video>
|
||||
<video>
|
||||
<model type="cirrus" vram="10240" heads="3"/>
|
||||
</video>
|
||||
<video>
|
||||
<model type="cirrus"/>
|
||||
</video>
|
||||
</devices>
|
||||
</domain>
|
@ -1,38 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<video>
|
||||
<model type="vga" vram="1000" heads="1"/>
|
||||
</video>
|
||||
<video>
|
||||
<model type="vmvga" heads="5"/>
|
||||
</video>
|
||||
<video>
|
||||
<model type="qxl" vgamem="8192" ram="100">
|
||||
<acceleration accel3d="yes"/>
|
||||
</model>
|
||||
</video>
|
||||
</devices>
|
||||
</domain>
|
@ -1,32 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<watchdog model="ib700" action="none"/>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,32 +0,0 @@
|
||||
<domain type="xen">
|
||||
<name>TestGuest</name>
|
||||
<currentMemory>204800</currentMemory>
|
||||
<memory>409600</memory>
|
||||
<uuid>12345678-1234-1234-1234-123456789012</uuid>
|
||||
<description>foooo barrrr somedesc</description>
|
||||
<os>
|
||||
<type arch="i686">hvm</type>
|
||||
<loader>/usr/lib/xen/boot/hvmloader</loader>
|
||||
<boot dev="hd"/>
|
||||
</os>
|
||||
<features>
|
||||
<acpi/><apic/>
|
||||
</features>
|
||||
<clock offset="localtime"/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
<on_reboot>restart</on_reboot>
|
||||
<on_crash>destroy</on_crash>
|
||||
<vcpu>5</vcpu>
|
||||
<devices>
|
||||
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
|
||||
<disk type="block" device="floppy">
|
||||
<source dev="/dev/null"/>
|
||||
<target dev="fda" bus="fdc"/>
|
||||
</disk>
|
||||
<watchdog model="i6300esb" action="poweroff"/>
|
||||
</devices>
|
||||
<seclabel type="static" model="selinux">
|
||||
<label>foolabel</label>
|
||||
<imagelabel>imagelabel</imagelabel>
|
||||
</seclabel>
|
||||
</domain>
|
@ -1,20 +0,0 @@
|
||||
<interface type="bond" name="test-bond-arp">
|
||||
<bond mode="active-backup">
|
||||
<interface type="ethernet" name="eth0">
|
||||
<start mode="none"/>
|
||||
<mac address="00:FF:EE:FF:EE:FF"/>
|
||||
</interface>
|
||||
<interface type="ethernet" name="eth1">
|
||||
<mac address="00:FF:EE:FF:EE:AB"/>
|
||||
</interface>
|
||||
<interface type="ethernet" name="eth2">
|
||||
<start mode="hotplug"/>
|
||||
<mac address="00:FF:EE:FF:EE:CD"/>
|
||||
</interface>
|
||||
<arpmon interval="234" target="1.2.3.4" validate="active"/>
|
||||
</bond>
|
||||
<start mode="hotplug"/>
|
||||
<mac address="AA:AA:AA:11:AA:AA"/>
|
||||
<mtu size="1234"/>
|
||||
<protocol family="ipv4"/>
|
||||
</interface>
|
@ -1,20 +0,0 @@
|
||||
<interface type="bond" name="test-bond-mii">
|
||||
<bond>
|
||||
<interface type="ethernet" name="eth0">
|
||||
<start mode="none"/>
|
||||
<mac address="00:FF:EE:FF:EE:FF"/>
|
||||
</interface>
|
||||
<interface type="ethernet" name="eth1">
|
||||
<mac address="00:FF:EE:FF:EE:AB"/>
|
||||
</interface>
|
||||
<interface type="ethernet" name="eth2">
|
||||
<start mode="hotplug"/>
|
||||
<mac address="00:FF:EE:FF:EE:CD"/>
|
||||
</interface>
|
||||
<miimon freq="111" downdelay="22" updelay="33" carrier="ioctl"/>
|
||||
</bond>
|
||||
<start mode="onboot"/>
|
||||
<mac address="AA:AA:AA:AA:AA:AA"/>
|
||||
<mtu size="1501"/>
|
||||
<protocol family="ipv4"/>
|
||||
</interface>
|
@ -1,21 +0,0 @@
|
||||
<interface type="bridge" name="foo-new">
|
||||
<bridge stp="on" delay="2">
|
||||
<interface type="ethernet" name="vlaneth1">
|
||||
</interface>
|
||||
<interface type="ethernet" name="eth0">
|
||||
<start mode="none"/>
|
||||
<mac address="00:FF:EE:FF:EE:FF"/>
|
||||
</interface>
|
||||
</bridge>
|
||||
<protocol family="ipv4">
|
||||
<dhcp peerdns="no"/>
|
||||
<ip address="129.63.1.2"/>
|
||||
<ip address="255.255.255.0"/>
|
||||
<route gateway="5.5.5.5"/>
|
||||
</protocol>
|
||||
<protocol family="ipv6">
|
||||
<ip address="fe99::215:58ff:fe6e:5" prefix="32"/>
|
||||
<ip address="2002::" prefix="38"/>
|
||||
<route gateway="1.2.3.4"/>
|
||||
</protocol>
|
||||
</interface>
|
@ -1,5 +0,0 @@
|
||||
<interface type="vlan" name="test-vlan">
|
||||
<vlan tag="456">
|
||||
<interface name="foonew"/>
|
||||
</vlan>
|
||||
</interface>
|
@ -1148,6 +1148,7 @@ c.add_valid("--file %(NEWIMG1)s --file-size .00001 --nonsparse") # Nonexistent
|
||||
c = vinst.add_category("console-tests", "--nodisks")
|
||||
c.add_valid("--pxe", grep="graphical console command: virt-viewer") # mock default graphics+virt-viewer usage
|
||||
c.add_valid("--pxe --graphics spice,gl=on", grep="--attach") # using virt-viewer --attach option for gl
|
||||
c.add_valid("--pxe --graphics listen=none", grep="--attach") # using virt-viewer --attach option for listen 'none'
|
||||
c.add_valid("--pxe --destroy-on-exit", grep="Restarting guest.\n") # destroy-on-exit
|
||||
c.add_valid("--pxe --transient --destroy-on-exit", grep="Domain creation completed.") # destroy-on-exit + transient
|
||||
c.add_valid("--pxe --graphics vnc --noreboot", grep="graphical console command: virt-viewer") # mock virt-viewer waiting, with noreboot magic
|
||||
|
@ -50,13 +50,6 @@ def _make_guest(conn=None, os_variant=None):
|
||||
return g
|
||||
|
||||
|
||||
def _make_installer(location=None, conn=None):
|
||||
conn = conn or utils.URIs.open_testdriver_cached()
|
||||
cdrom = not location and "/dev/null" or None
|
||||
inst = virtinst.Installer(conn, location=location, cdrom=cdrom)
|
||||
return inst
|
||||
|
||||
|
||||
class TestXMLMisc(unittest.TestCase):
|
||||
"""
|
||||
Misc tests for various XML special behavior. These should only aim for
|
||||
@ -67,20 +60,6 @@ class TestXMLMisc(unittest.TestCase):
|
||||
def conn(self):
|
||||
return utils.URIs.open_testdefault_cached()
|
||||
|
||||
def _compare(self, guest, filebase, do_install):
|
||||
filename = os.path.join("tests/data/xmlconfig", filebase + ".xml")
|
||||
|
||||
installer = _make_installer(conn=guest.conn)
|
||||
inst_xml, boot_xml = installer.start_install(
|
||||
guest, return_xml=True, dry=True)
|
||||
if do_install:
|
||||
actualXML = inst_xml
|
||||
else:
|
||||
actualXML = boot_xml
|
||||
|
||||
utils.diff_compare(actualXML, filename)
|
||||
utils.test_create(guest.conn, actualXML)
|
||||
|
||||
def testDiskNumbers(self):
|
||||
# Various testing our target generation
|
||||
#
|
||||
@ -114,31 +93,6 @@ class TestXMLMisc(unittest.TestCase):
|
||||
assert disk.generate_target(['hdb', 'sda']) == 'hdc'
|
||||
assert disk.generate_target(['hda', 'hdd']) == 'hdb'
|
||||
|
||||
def testQuickTreeinfo(self):
|
||||
# Simple sanity test to make sure detect_distro works. test-urls
|
||||
# does much more exhaustive testing but it's only run occasionally
|
||||
i = _make_installer(
|
||||
location=utils.DATADIR + "/fakemedia/fakefedoratree")
|
||||
g = _make_guest()
|
||||
v = i.detect_distro(g)
|
||||
assert v == "fedora17"
|
||||
|
||||
i = _make_installer(
|
||||
location=utils.DATADIR + "/fakemedia/fakerhel6tree")
|
||||
g = _make_guest()
|
||||
v = i.detect_distro(g)
|
||||
assert v == "rhel6.0"
|
||||
|
||||
def testCDROMInsert(self):
|
||||
# After set_install_defaults, cdrom media should be inserted
|
||||
i = _make_installer()
|
||||
g = _make_guest()
|
||||
i.set_install_defaults(g)
|
||||
for disk in g.devices.disk:
|
||||
if disk.device == "cdrom" and disk.path == "/dev/null":
|
||||
return
|
||||
raise AssertionError("Didn't find inserted cdrom media")
|
||||
|
||||
def testCPUTopology(self):
|
||||
# Test CPU topology determining
|
||||
cpu = virtinst.DomainCpu(self.conn)
|
||||
@ -182,17 +136,16 @@ class TestXMLMisc(unittest.TestCase):
|
||||
assert xml1 == xml2
|
||||
|
||||
def test_guest_osinfo_metadata(self):
|
||||
g = _make_guest()
|
||||
assert g.osinfo.name == "generic"
|
||||
g.set_os_name("fedora17")
|
||||
assert g.osinfo.name == "fedora17"
|
||||
|
||||
g = _make_guest()
|
||||
g._metadata.libosinfo.os_id = "http://fedoraproject.org/fedora/20" # pylint: disable=protected-access
|
||||
"""
|
||||
Test that reading an unknown OS ID from guest XML will not blow up
|
||||
"""
|
||||
# pylint: disable=protected-access
|
||||
g = virtinst.Guest(utils.URIs.open_testdefault_cached())
|
||||
g._metadata.libosinfo.os_id = "http://fedoraproject.org/fedora/20"
|
||||
assert g.osinfo.name == "fedora20"
|
||||
|
||||
g = _make_guest()
|
||||
g._metadata.libosinfo.os_id = "http://example.com/idontexit" # pylint: disable=protected-access
|
||||
g = virtinst.Guest(utils.URIs.open_testdefault_cached())
|
||||
g._metadata.libosinfo.os_id = "http://example.com/idontexit"
|
||||
assert g.osinfo.name == "generic"
|
||||
|
||||
def test_dir_searchable(self):
|
||||
|
@ -252,104 +252,6 @@ class XMLParseTest(unittest.TestCase):
|
||||
assert guest.is_full_os_container() is False
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testSeclabel(self):
|
||||
guest, outfile = self._get_test_content("change-seclabel")
|
||||
|
||||
check = self._make_checker(guest.seclabels[0])
|
||||
check("type", "static", "none")
|
||||
check("model", "selinux", "apparmor")
|
||||
check("label", "foolabel", "barlabel")
|
||||
check("baselabel", None, "baselabel")
|
||||
check("relabel", None, False)
|
||||
|
||||
guest.remove_child(guest.seclabels[1])
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterMinimalGuest(self):
|
||||
guest, outfile = self._get_test_content("change-minimal-guest")
|
||||
|
||||
check = self._make_checker(guest.features)
|
||||
check("acpi", False, True)
|
||||
check("pae", False)
|
||||
assert guest.features.get_xml().startswith("<features")
|
||||
|
||||
check = self._make_checker(guest.clock)
|
||||
check("offset", None, "utc")
|
||||
assert guest.clock.get_xml().startswith("<clock") is True
|
||||
|
||||
seclabel = virtinst.DomainSeclabel(guest.conn)
|
||||
guest.add_child(seclabel)
|
||||
seclabel.model = "testSecurity"
|
||||
seclabel.type = "static"
|
||||
seclabel.label = "frob"
|
||||
assert guest.seclabels[0].get_xml().startswith("<seclabel")
|
||||
|
||||
check = self._make_checker(guest.cpu)
|
||||
check("model", None)
|
||||
guest.cpu.set_model(guest, "foobar")
|
||||
check("model", "foobar")
|
||||
check("model_fallback", None, "allow")
|
||||
check("topology.cores", None, 4)
|
||||
guest.cpu.add_feature("x2apic", "forbid")
|
||||
guest.cpu.set_topology_defaults(guest.vcpus)
|
||||
assert guest.cpu.get_xml().startswith("<cpu") is True
|
||||
assert guest.cpu.get_xml_id() == "./cpu"
|
||||
assert guest.cpu.get_xml_idx() == 0
|
||||
assert guest.get_xml_id() == "."
|
||||
assert guest.get_xml_idx() == 0
|
||||
|
||||
assert guest.os.get_xml().startswith("<os") is True
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterBootMulti(self):
|
||||
guest, outfile = self._get_test_content("change-boot-multi")
|
||||
|
||||
check = self._make_checker(guest.os)
|
||||
check("bootorder", ['hd', 'fd', 'cdrom', 'network'], ["cdrom"])
|
||||
check("enable_bootmenu", False, True)
|
||||
check("kernel", None, "/foo.img")
|
||||
check("initrd", None, "/bar.img")
|
||||
check("dtb", None, "/baz.dtb")
|
||||
check("kernel_args", None, "ks=foo.ks")
|
||||
|
||||
guest.os.set_initargs_string("foo bar")
|
||||
guest.os.set_initargs_string("baz wibble")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterBootKernel(self):
|
||||
guest, outfile = self._get_test_content("change-boot-kernel")
|
||||
|
||||
check = self._make_checker(guest.os)
|
||||
check("bootorder", [], ["network", "hd", "fd"])
|
||||
check("enable_bootmenu", None)
|
||||
check("kernel", "/boot/vmlinuz", None)
|
||||
|
||||
check("initrd", "/boot/initrd", None)
|
||||
check("kernel_args", "location", None)
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterBootUEFI(self):
|
||||
guest, outfile = self._get_test_content("change-boot-uefi")
|
||||
|
||||
check = self._make_checker(guest.os)
|
||||
check("bootorder", [], ["network", "hd", "fd"])
|
||||
check("loader_ro", None, True)
|
||||
check("loader_type", None, "pflash")
|
||||
check("nvram", None, "/tmp/nvram_store")
|
||||
check("nvram_template", None, "/tmp/template")
|
||||
check("loader", None, "OVMF_CODE.fd")
|
||||
|
||||
check("kernel", "/boot/vmlinuz", None)
|
||||
|
||||
check("initrd", "/boot/initrd", None)
|
||||
check("kernel_args", "location", None)
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterCpuMode(self):
|
||||
xml = open(DATADIR + "change-cpumode-in.xml").read()
|
||||
outfile = DATADIR + "change-cpumode-out.xml"
|
||||
@ -607,7 +509,7 @@ class XMLParseTest(unittest.TestCase):
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterControllers(self):
|
||||
def _testAlterControllers(self):
|
||||
guest, outfile = self._get_test_content("change-controllers")
|
||||
|
||||
dev1 = guest.devices.controller[0]
|
||||
@ -689,413 +591,6 @@ class XMLParseTest(unittest.TestCase):
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterInputs(self):
|
||||
guest, outfile = self._get_test_content("change-inputs")
|
||||
|
||||
dev1 = guest.devices.input[0]
|
||||
dev2 = guest.devices.input[1]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", "mouse", "tablet")
|
||||
check("bus", "ps2", "usb")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("type", "tablet", "mouse")
|
||||
check("bus", "usb", "xen")
|
||||
check("bus", "xen", "usb")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterGraphics(self):
|
||||
guest, outfile = self._get_test_content("change-graphics")
|
||||
|
||||
dev1 = guest.devices.graphics[0]
|
||||
dev2 = guest.devices.graphics[1]
|
||||
dev3 = guest.devices.graphics[2]
|
||||
dev4 = guest.devices.graphics[3]
|
||||
dev5 = guest.devices.graphics[4]
|
||||
dev6 = guest.devices.graphics[5]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", "vnc")
|
||||
check("passwd", "foobar", "newpass")
|
||||
check("port", 100, 6000)
|
||||
check("listen", "0.0.0.0", "1.2.3.4")
|
||||
check("keymap", None, "en-us")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("type", "vnc")
|
||||
check("xauth", "/tmp/.Xauthority", "fooauth")
|
||||
check("display", "1:2", "6:1")
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("type", "rdp", "vnc")
|
||||
check("listen", "1.1.2.3", None)
|
||||
|
||||
check = self._make_checker(dev4)
|
||||
check("type", "vnc")
|
||||
check("port", -1)
|
||||
check("socket", "/tmp/foobar", "/var/lib/libvirt/socket/foo")
|
||||
|
||||
check = self._make_checker(dev5)
|
||||
check("autoport", True, False)
|
||||
check = self._make_checker(dev5.listens[0])
|
||||
dev5.listens[0].type = "none"
|
||||
assert guest.has_listen_none() is True
|
||||
check("type", "none", "foo", "network")
|
||||
check("network", "Bobsnetwork", "mynewnet")
|
||||
|
||||
check = self._make_checker(dev6.listens[0])
|
||||
check("type", "address")
|
||||
check("address", "0.0.0.0")
|
||||
check = self._make_checker(dev6)
|
||||
check("type", "spice")
|
||||
check("passwd", "foobar", "newpass")
|
||||
check("connected", None, "disconnect")
|
||||
check("port", 100, 6000)
|
||||
check("tlsPort", 101, 6001)
|
||||
check("listen", "0.0.0.0", "1.2.3.4")
|
||||
check("channel_inputs_mode", "insecure", "secure")
|
||||
check("channel_main_mode", "secure", "any")
|
||||
check("channel_record_mode", "any", "insecure")
|
||||
check("channel_display_mode", "any", "secure")
|
||||
check("channel_cursor_mode", "any", "any")
|
||||
check("channel_playback_mode", "any", "insecure")
|
||||
check("passwdValidTo", "2010-04-09T15:51:00", "2011-01-07T19:08:00")
|
||||
check("defaultMode", None, "secure")
|
||||
check("image_compression", None, "auto_glz")
|
||||
check("streaming_mode", None, "filter")
|
||||
check("clipboard_copypaste", None, True)
|
||||
check("mouse_mode", None, "client")
|
||||
check("filetransfer_enable", None, False)
|
||||
check("gl", None, True)
|
||||
check("rendernode", None, "/dev/dri/foo")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterVideos(self):
|
||||
guest, outfile = self._get_test_content("change-videos")
|
||||
|
||||
dev1 = guest.devices.video[0]
|
||||
dev2 = guest.devices.video[1]
|
||||
dev3 = guest.devices.video[2]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("model", "vmvga", "vga")
|
||||
check("vram", None, 1000)
|
||||
check("heads", None, 1)
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("model", "cirrus", "vmvga")
|
||||
check("vram", 10240, None)
|
||||
check("heads", 3, 5)
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("model", "cirrus", "cirrus", "qxl")
|
||||
check("ram", None, 100)
|
||||
check("vgamem", None, 8192)
|
||||
check("accel3d", None, True)
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterHostdevs(self):
|
||||
infile = DATADIR + "change-hostdevs-in.xml"
|
||||
outfile = DATADIR + "change-hostdevs-out.xml"
|
||||
guest = virtinst.Guest(self.conn,
|
||||
parsexml=open(infile).read())
|
||||
|
||||
dev1 = guest.devices.hostdev[0]
|
||||
dev2 = guest.devices.hostdev[1]
|
||||
dev3 = guest.devices.hostdev[2]
|
||||
dev4 = guest.devices.hostdev[3]
|
||||
dev5 = guest.devices.hostdev[4]
|
||||
dev6 = guest.devices.hostdev[5]
|
||||
dev7 = guest.devices.hostdev[6]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", "usb", "foo", "usb")
|
||||
check("managed", True, False)
|
||||
check("mode", "subsystem", None)
|
||||
check("vendor", "0x4321", "0x1111")
|
||||
check("product", "0x1234", "0x2222")
|
||||
check("bus", None, "1")
|
||||
check("device", None, "2")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("type", "usb")
|
||||
check("managed", False, True)
|
||||
check("mode", "capabilities", "subsystem")
|
||||
check("bus", "0x12", "0x56")
|
||||
check("device", "0x34", "0x78")
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("type", "pci")
|
||||
check("managed", True, True)
|
||||
check("mode", "subsystem", "subsystem")
|
||||
check("domain", "0x0", "0x4")
|
||||
check("bus", "0x1", "0x5")
|
||||
check("slot", "0x2", "0x6")
|
||||
check("function", "0x3", "0x7")
|
||||
check("driver_name", None, "vfio")
|
||||
check("rom_bar", None, True)
|
||||
|
||||
check = self._make_checker(dev4)
|
||||
check("type", "scsi")
|
||||
check("scsi_adapter", "scsi_host0", "foo")
|
||||
check("scsi_bus", 0, 1)
|
||||
check("scsi_target", 0, 2)
|
||||
check("scsi_unit", 0, 3)
|
||||
|
||||
check = self._make_checker(dev5)
|
||||
check("type", "net")
|
||||
check("net_interface", "wlan0", "eth0")
|
||||
|
||||
check = self._make_checker(dev6)
|
||||
check("type", "misc")
|
||||
check("misc_char", "/dev/net/tun", "/dev/null")
|
||||
|
||||
check = self._make_checker(dev7)
|
||||
check("type", "storage")
|
||||
check("storage_block", "/dev/sdf", "/dev/fd0")
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterWatchdogs(self):
|
||||
guest, outfile = self._get_test_content("change-watchdogs")
|
||||
|
||||
dev1 = guest.devices.watchdog[0]
|
||||
check = self._make_checker(dev1)
|
||||
check("model", "ib700", "i6300esb")
|
||||
check("action", "none", "poweroff")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def _testAlterFilesystems(self):
|
||||
guest, outfile = self._get_test_content("change-filesystems")
|
||||
|
||||
dev1 = guest.devices.filesystem[0]
|
||||
dev2 = guest.devices.filesystem[1]
|
||||
dev3 = guest.devices.filesystem[2]
|
||||
dev4 = guest.devices.filesystem[3]
|
||||
dev5 = guest.devices.filesystem[4]
|
||||
dev6 = guest.devices.filesystem[5]
|
||||
dev7 = guest.devices.filesystem[6]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", None, "mount")
|
||||
check("accessmode", None, "passthrough")
|
||||
check("driver_type", "handle", None)
|
||||
check("driver_wrpolicy", None, None)
|
||||
check("source", "/foo/bar", "/new/path")
|
||||
check("target", "/bar/baz", "/new/target")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("type", "template")
|
||||
check("accessmode", None, "mapped")
|
||||
check("source", "template_fedora", "template_new")
|
||||
check("target", "/bar/baz")
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("type", "mount", None)
|
||||
check("accessmode", "squash", None)
|
||||
check("driver_type", "path", "handle")
|
||||
check("driver_wrpolicy", "immediate", None)
|
||||
check("readonly", False, True)
|
||||
|
||||
check = self._make_checker(dev4)
|
||||
check("type", "mount", None)
|
||||
check("accessmode", "mapped", None)
|
||||
check("driver_type", "path", "handle")
|
||||
check("driver_wrpolicy", None, "immediate")
|
||||
check("readonly", False, True)
|
||||
|
||||
check = self._make_checker(dev5)
|
||||
check("type", "ram")
|
||||
check("source", "1024", 123)
|
||||
check("source_units", "MB", "KiB")
|
||||
|
||||
check = self._make_checker(dev6)
|
||||
check("source", "/foo/bar", "/dev/new")
|
||||
check("readonly", False, True)
|
||||
check("type", "block", "file")
|
||||
|
||||
check = self._make_checker(dev7)
|
||||
check("type", "file")
|
||||
check("accessmode", "passthrough", None)
|
||||
check("driver_type", "nbd", "loop")
|
||||
check("driver_format", "qcow", "raw")
|
||||
check("source", "/foo/bar.img", "/foo/bar.raw")
|
||||
check("readonly", False, True)
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterSounds(self):
|
||||
infile = DATADIR + "change-sounds-in.xml"
|
||||
outfile = DATADIR + "change-sounds-out.xml"
|
||||
guest = virtinst.Guest(self.conn,
|
||||
parsexml=open(infile).read())
|
||||
|
||||
dev1 = guest.devices.sound[0]
|
||||
dev2 = guest.devices.sound[1]
|
||||
dev3 = guest.devices.sound[2]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("model", "sb16", "ac97")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("model", "es1370", "es1370")
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("model", "ac97", "sb16")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterAddr(self):
|
||||
guest, outfile = self._get_test_content("change-addr")
|
||||
|
||||
dev1 = guest.devices.disk[0]
|
||||
dev2 = guest.devices.controller[0]
|
||||
dev3 = guest.devices.channel[0]
|
||||
dev4 = guest.devices.disk[1]
|
||||
dev5 = guest.devices.memory[0]
|
||||
|
||||
check = self._make_checker(dev1.address)
|
||||
check("type", "drive", "pci")
|
||||
check("type", "pci", "drive")
|
||||
check("controller", 3, 1)
|
||||
check("bus", 5, 4)
|
||||
check("target", None, 7)
|
||||
check("unit", 33, 32)
|
||||
check = self._make_checker(dev1.alias)
|
||||
check("name", "foo2", None)
|
||||
|
||||
check = self._make_checker(dev2.address)
|
||||
dev2.address.domain = "0x0010"
|
||||
assert dev2.address.domain == 16
|
||||
check("type", "pci")
|
||||
check("domain", 16, 1)
|
||||
check("bus", 0, 4)
|
||||
check("slot", 4, 10)
|
||||
check("function", 7, 6)
|
||||
check = self._make_checker(dev2.alias)
|
||||
check("name", None, "frob")
|
||||
|
||||
check = self._make_checker(dev3.address)
|
||||
check("type", "virtio-serial")
|
||||
check("controller", 0)
|
||||
check("bus", 0)
|
||||
check("port", 2, 4)
|
||||
check = self._make_checker(dev3.alias)
|
||||
check("name", "channel0", "channel1")
|
||||
|
||||
dev4.address.clear()
|
||||
|
||||
check = self._make_checker(dev5.address)
|
||||
check("type", "dimm")
|
||||
check("slot", 0, 2)
|
||||
check("base", None, "0x1000")
|
||||
# Need to remove this since the testdriver doesn't support
|
||||
# memory devices?
|
||||
guest.remove_device(dev5)
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterSmartCard(self):
|
||||
guest, outfile = self._get_test_content("change-smartcard")
|
||||
|
||||
dev1 = guest.devices.smartcard[0]
|
||||
dev2 = guest.devices.smartcard[1]
|
||||
dev3 = guest.devices.smartcard[2]
|
||||
dev4 = guest.devices.smartcard[3]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", None, "tcp")
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("mode", "passthrough", "host")
|
||||
check("type", "spicevmc", None)
|
||||
|
||||
check = self._make_checker(dev3)
|
||||
check("type", "tcp")
|
||||
check("source.host", "127.0.0.1")
|
||||
check("source.service", 2001)
|
||||
check("source.protocol", "raw", "telnet")
|
||||
|
||||
check = self._make_checker(dev4)
|
||||
check("type", "unix")
|
||||
check("source.path", "/tmp/smartcard.sock")
|
||||
check("source.mode", "bind")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterRedirdev(self):
|
||||
guest, outfile = self._get_test_content("change-redirdev")
|
||||
|
||||
dev1 = guest.devices.redirdev[0]
|
||||
dev2 = guest.devices.redirdev[1]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("bus", "usb", "baz", "usb")
|
||||
check("source.host", "foo", "bar")
|
||||
check("source.service", 12, 42)
|
||||
|
||||
check = self._make_checker(dev2)
|
||||
check("type", "tcp", "spicevmc")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterTPM(self):
|
||||
guest, outfile = self._get_test_content("change-tpm")
|
||||
|
||||
dev1 = guest.devices.tpm[0]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("type", "passthrough", "foo", "passthrough")
|
||||
check("model", "tpm-tis", "tpm-crb", "tpm-tis")
|
||||
check("device_path", "/dev/tpm0", "frob")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterRNG_EGD(self):
|
||||
guest, outfile = self._get_test_content("change-rng-egd")
|
||||
|
||||
dev1 = guest.devices.rng[0]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("backend_model", "egd")
|
||||
check("backend_type", "udp", "udp")
|
||||
|
||||
check("source.connect_host", "1.2.3.4", "1.2.3.5")
|
||||
check("source.connect_service", 1234, 1235)
|
||||
check("source.bind_host", None, None)
|
||||
check("source.bind_service", 1233, 1236)
|
||||
|
||||
check("rate_bytes", "1234", "4321")
|
||||
check("rate_period", "2000", "2001")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testAlterRNG_Random(self):
|
||||
guest, outfile = self._get_test_content("change-rng-random")
|
||||
|
||||
dev1 = guest.devices.rng[0]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("backend_model", "random", "random")
|
||||
check("model", "virtio", "virtio")
|
||||
check("device", "/dev/random", "/dev/hwrng")
|
||||
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testPanicDevice(self):
|
||||
guest, outfile = self._get_test_content("change-panic-device")
|
||||
|
||||
dev1 = guest.devices.panic[0]
|
||||
|
||||
check = self._make_checker(dev1)
|
||||
check("address.type", "isa", None, "isa")
|
||||
check("address.iobase", "0x505", None, "0x506")
|
||||
self._alter_compare(guest.get_xml(), outfile)
|
||||
|
||||
def testQEMUXMLNS(self):
|
||||
basename = "change-xmlns-qemu"
|
||||
infile = DATADIR + "%s-in.xml" % basename
|
||||
@ -1503,7 +998,10 @@ class XMLParseTest(unittest.TestCase):
|
||||
with pytest.raises(ValueError):
|
||||
dev.scsi_bus = "goodbye"
|
||||
|
||||
def testXMLCoverage(self):
|
||||
def testXMLBuilderCoverage(self):
|
||||
"""
|
||||
Test XMLBuilder corner cases
|
||||
"""
|
||||
with pytest.raises(RuntimeError, match=".*'foo'.*"):
|
||||
# Ensure we validate root element
|
||||
virtinst.DeviceDisk(self.conn, parsexml="<foo/>")
|
||||
@ -1512,9 +1010,8 @@ class XMLParseTest(unittest.TestCase):
|
||||
# Ensure we validate root element
|
||||
virtinst.DeviceDisk(self.conn, parsexml=-1)
|
||||
|
||||
from virtinst import xmlutil
|
||||
with pytest.raises(xmlutil.DevError):
|
||||
raise xmlutil.DevError("for coverage")
|
||||
with pytest.raises(virtinst.xmlutil.DevError):
|
||||
raise virtinst.xmlutil.DevError("for coverage")
|
||||
|
||||
with pytest.raises(ValueError):
|
||||
virtinst.DeviceDisk.validate_generic_name("objtype", None)
|
||||
@ -1523,8 +1020,36 @@ class XMLParseTest(unittest.TestCase):
|
||||
virtinst.DeviceDisk.validate_generic_name("objtype", "foo bar")
|
||||
|
||||
# Test property __repr__ for code coverage
|
||||
assert str(virtinst.DeviceDisk.address)
|
||||
assert str(virtinst.DeviceDisk.driver_cache)
|
||||
assert "DeviceAddress" in str(virtinst.DeviceDisk.address)
|
||||
assert "./driver/@cache" in str(virtinst.DeviceDisk.driver_cache)
|
||||
|
||||
# Conversion of 0x value into int
|
||||
xml = """
|
||||
<controller type='scsi'>
|
||||
<address type='pci' bus='0x00' slot='0x04' function='0x7'/>
|
||||
</controller>
|
||||
"""
|
||||
dev = virtinst.DeviceController(self.conn, parsexml=xml)
|
||||
assert dev.address.slot == 4
|
||||
|
||||
# Some XML formatting and get_xml_* corner cases
|
||||
conn = utils.URIs.openconn(utils.URIs.test_suite)
|
||||
xml = conn.lookupByName("test-for-virtxml").XMLDesc(0)
|
||||
guest = virtinst.Guest(conn, parsexml=xml)
|
||||
|
||||
assert guest.features.get_xml().startswith("<features")
|
||||
assert guest.clock.get_xml().startswith("<clock")
|
||||
assert guest.seclabels[0].get_xml().startswith("<seclabel")
|
||||
assert guest.cpu.get_xml().startswith("<cpu")
|
||||
assert guest.os.get_xml().startswith("<os")
|
||||
assert guest.cpu.get_xml_id() == "./cpu"
|
||||
assert guest.cpu.get_xml_idx() == 0
|
||||
assert guest.get_xml_id() == "."
|
||||
assert guest.get_xml_idx() == 0
|
||||
|
||||
assert guest.devices.disk[1].get_xml_id() == "./devices/disk[2]"
|
||||
assert guest.devices.disk[1].get_xml_idx() == 1
|
||||
|
||||
|
||||
def testReplaceChildParse(self):
|
||||
buildfile = DATADIR + "replace-child-build.xml"
|
||||
@ -1674,3 +1199,9 @@ class XMLParseTest(unittest.TestCase):
|
||||
guest.cpu.model = "idontexist"
|
||||
guest.cpu._validate_default_host_model_only(guest)
|
||||
assert guest.cpu.model is None
|
||||
|
||||
def testOSXMLInitargsRemove(self):
|
||||
guest = virtinst.Guest(self.conn)
|
||||
guest.os.set_initargs_string("foo bar")
|
||||
guest.os.set_initargs_string("baz wibble")
|
||||
assert [i.val for i in guest.os.initargs] == ["baz", "wibble"]
|
||||
|
@ -11,11 +11,6 @@ from ..logger import log
|
||||
from ..xmlbuilder import XMLBuilder, XMLChildProperty, XMLProperty
|
||||
|
||||
|
||||
def _get_mode_prop(channel_type):
|
||||
xpath = "./channel[@name='%s']/@mode" % channel_type
|
||||
return XMLProperty(xpath)
|
||||
|
||||
|
||||
def _validate_port(name, val):
|
||||
if val is None:
|
||||
return val
|
||||
@ -44,13 +39,6 @@ class DeviceGraphics(Device):
|
||||
TYPE_RDP = "rdp"
|
||||
TYPE_SPICE = "spice"
|
||||
|
||||
CHANNEL_TYPE_MAIN = "main"
|
||||
CHANNEL_TYPE_DISPLAY = "display"
|
||||
CHANNEL_TYPE_INPUTS = "inputs"
|
||||
CHANNEL_TYPE_CURSOR = "cursor"
|
||||
CHANNEL_TYPE_PLAYBACK = "playback"
|
||||
CHANNEL_TYPE_RECORD = "record"
|
||||
|
||||
_XML_PROP_ORDER = ["type", "gl", "_port", "_tlsPort", "autoport", "websocket",
|
||||
"keymap", "_listen",
|
||||
"passwd", "display", "xauth"]
|
||||
@ -78,13 +66,6 @@ class DeviceGraphics(Device):
|
||||
autoport = XMLProperty("./@autoport", is_yesno=True)
|
||||
websocket = XMLProperty("./@websocket", is_int=True)
|
||||
|
||||
channel_main_mode = _get_mode_prop(CHANNEL_TYPE_MAIN)
|
||||
channel_display_mode = _get_mode_prop(CHANNEL_TYPE_DISPLAY)
|
||||
channel_inputs_mode = _get_mode_prop(CHANNEL_TYPE_INPUTS)
|
||||
channel_cursor_mode = _get_mode_prop(CHANNEL_TYPE_CURSOR)
|
||||
channel_playback_mode = _get_mode_prop(CHANNEL_TYPE_PLAYBACK)
|
||||
channel_record_mode = _get_mode_prop(CHANNEL_TYPE_RECORD)
|
||||
|
||||
xauth = XMLProperty("./@xauth")
|
||||
display = XMLProperty("./@display")
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user