mirror of
https://github.com/virt-manager/virt-manager.git
synced 2024-12-25 23:21:45 +03:00
fc6778108b
Currently we hardcode these defaults for installing VMs: <on_poweroff>destroy</on_poweroff> <on_reboot>destroy</on_reboot> <on_crash>destroy</on_crash> And these for post-install config: <on_poweroff>destroy</on_poweroff> <on_reboot>restart</on_reboot> <on_crash>restart</on_crash> But this has some issues. on_crash=restart is problematic in that most configs don't support it, and some like virtuozzo actively reject it. Additionally this we should leave as much to libvirt defaults as we can, which are more sensible in this case. Drop everything except setting on_reboot=destroy for the install time case (which is required for our config changes). Since on_poweroff and on_crash already default to 'destroy', the install time config is unchanged, and the post-install config now on_crash=destroy instead of 'restart'. The s390 on_crash=preserve workaround is dropped, which was intended to avoid a reboot loop caused by on_crash=reboot
103 lines
3.2 KiB
XML
103 lines
3.2 KiB
XML
<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"/>
|
|
</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="/dev/null"/>
|
|
<target dev="hda" bus="usb" removable="on"/>
|
|
<serial>frob</serial>
|
|
<driver name="test" type="raw"/>
|
|
</disk>
|
|
<disk type="block" device="disk">
|
|
<source dev="/dev/null">
|
|
<seclabel model="selinux" relabel="no"/>
|
|
<seclabel model="dac" relabel="yes">
|
|
<label>foo-my-label</label>
|
|
</seclabel>
|
|
</source>
|
|
<target dev="hdb" bus="ide"/>
|
|
</disk>
|
|
<disk type="file" device="floppy">
|
|
<target dev="fde" bus="fdc"/>
|
|
</disk>
|
|
<disk type="block" device="lun" sgio="unfiltered">
|
|
<driver name="qemu" type="raw"/>
|
|
<source dev="/dev/sda"/>
|
|
<target dev="hdd" bus="scsi"/>
|
|
<readonly/>
|
|
</disk>
|
|
<disk type="network" device="cdrom">
|
|
<target dev="sda" bus="scsi"/>
|
|
<readonly/>
|
|
<source protocol="http" name="my/file">
|
|
<host name="1:2:3:4:5:6:7:8" port="1122"/>
|
|
</source>
|
|
</disk>
|
|
<disk type="file" device="floppy">
|
|
<target dev="fda" bus="fdc"/>
|
|
<iotune>
|
|
<read_iops_sec>0</read_iops_sec>
|
|
<read_bytes_sec>0</read_bytes_sec>
|
|
<write_iops_sec>0</write_iops_sec>
|
|
<write_bytes_sec>0</write_bytes_sec>
|
|
<total_iops_sec>5</total_iops_sec>
|
|
<total_bytes_sec>6</total_bytes_sec>
|
|
</iotune>
|
|
<driver cache="writeback" discard="unmap" io="native"/>
|
|
<source file="/dev/default-pool/default-vol" startupPolicy="optional"/>
|
|
<shareable/>
|
|
</disk>
|
|
<disk type="block" device="floppy">
|
|
<driver name="phy" cache="none"/>
|
|
<source dev="/dev/null"/>
|
|
<target dev="fdb" bus="fdc"/>
|
|
</disk>
|
|
<disk type="block" device="disk">
|
|
<driver name="qemu" type="qcow2" cache="none"/>
|
|
<source dev="/dev/null"/>
|
|
<target dev="vda" bus="virtio"/>
|
|
</disk>
|
|
<disk type="volume" device="disk">
|
|
<driver name="qemu"/>
|
|
<source pool="anotherPool" volume="newvol"/>
|
|
<target dev="vdb" bus="virtio"/>
|
|
<readonly/>
|
|
</disk>
|
|
<disk type="network" device="disk">
|
|
<driver name="qemu" type="raw"/>
|
|
<source protocol="gluster" name="new-val/vol">
|
|
<host name="diff.example.org" port="1234"/>
|
|
<host name="mon2.example.org" port="6322"/>
|
|
<host name="mon3.example.org" port="6322"/>
|
|
</source>
|
|
<target dev="vdc" bus="virtio"/>
|
|
</disk>
|
|
<disk type="network" device="disk">
|
|
<driver name="qemu" type="raw"/>
|
|
<source protocol="nbd">
|
|
<host transport="unix" socket="/var/run/nbdsock"/>
|
|
</source>
|
|
<target dev="vdd" bus="virtio"/>
|
|
</disk>
|
|
<input type="mouse" bus="ps2"/>
|
|
<graphics type="vnc" display=":3.4" xauth="/tmp/.Xauthority"/>
|
|
<console type="pty"/>
|
|
</devices>
|
|
</domain>
|