qemu: command: Move around order of generating -drive arguments

Move together sections which are conditionaly executed depending on
whether -device will be used together with the -drive.
This commit is contained in:
Peter Krempa 2017-11-22 10:36:30 +01:00
parent ccc1d910ce
commit b9dfed787d
57 changed files with 100 additions and 98 deletions

View File

@ -1673,18 +1673,6 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
virBufferAsprintf(&opt, "if=%s",
virDomainDiskQEMUBusTypeToString(disk->bus));
if (disk->device == VIR_DOMAIN_DISK_DEVICE_CDROM) {
if (disk->bus == VIR_DOMAIN_DISK_BUS_SCSI) {
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_CD))
virBufferAddLit(&opt, ",media=cdrom");
} else if (disk->bus == VIR_DOMAIN_DISK_BUS_IDE) {
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_IDE_CD))
virBufferAddLit(&opt, ",media=cdrom");
} else {
virBufferAddLit(&opt, ",media=cdrom");
}
}
if (emitDeviceSyntax) {
char *drivealias = qemuAliasFromDisk(disk);
if (!drivealias)
@ -1701,6 +1689,21 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
}
virBufferAsprintf(&opt, ",index=%d", idx);
}
qemuBuildDiskFrontendAttributes(disk, qemuCaps, &opt);
if (disk->device == VIR_DOMAIN_DISK_DEVICE_CDROM) {
if (disk->bus == VIR_DOMAIN_DISK_BUS_SCSI) {
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_CD))
virBufferAddLit(&opt, ",media=cdrom");
} else if (disk->bus == VIR_DOMAIN_DISK_BUS_IDE) {
if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_IDE_CD))
virBufferAddLit(&opt, ",media=cdrom");
} else {
virBufferAddLit(&opt, ",media=cdrom");
}
}
if (bootable &&
virQEMUCapsGet(qemuCaps, QEMU_CAPS_DRIVE_BOOT) &&
(disk->device == VIR_DOMAIN_DISK_DEVICE_DISK ||
@ -1710,7 +1713,6 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
if (disk->src->readonly)
virBufferAddLit(&opt, ",readonly=on");
qemuBuildDiskFrontendAttributes(disk, qemuCaps, &opt);
if (disk->cachemode) {
virBufferAsprintf(&opt, ",cache=%s",

View File

@ -19,6 +19,6 @@ server,nowait \
-no-acpi \
-boot d \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -28,7 +28,7 @@ id=virtio-disk1 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/hdb,format=raw,if=none,id=drive-ide0-0-1 \
-device ide-drive,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \
-drive file=/dev/HostVG/hdc,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/HostVG/hdc,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \

View File

@ -29,7 +29,7 @@ id=virtio-disk1 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/hdb,format=raw,if=none,id=drive-ide0-0-1 \
-device ide-drive,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \
-drive file=/dev/HostVG/hdc,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/HostVG/hdc,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive file=/dev/fd0,format=raw,if=none,id=drive-fdc0-0-0 \

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot menu=off \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot order=d,menu=off \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot order=d,menu=off \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot menu=on \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot order=d,menu=on,splash-time=3000 \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot order=d,menu=on \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,7 +19,7 @@ server,nowait \
-no-acpi \
-boot order=dcna,menu=on \
-usb \
-drive file=/dev/cdrom,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/cdrom,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -20,7 +20,7 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/root/boot.iso,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/root/boot.iso,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \

View File

@ -29,7 +29,7 @@ id=virtio-disk1 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/hdb,format=raw,if=none,id=drive-ide0-0-1 \
-device ide-drive,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \
-drive file=/dev/HostVG/hdc,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/HostVG/hdc,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \

View File

@ -26,7 +26,7 @@ aio=native \
-device virtio-blk-pci,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/tmp/Fedora-17-x86_64-Live-Desktop.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-net-pci,vlan=0,id=net0,mac=52:54:00:4d:4b:19,bus=pci.0,addr=0x3 \
-net user,vlan=0,name=hostnet0 \

View File

@ -22,7 +22,7 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=none,aio=native \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on,aio=threads \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on,aio=threads \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -21,5 +21,5 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on \
-drive if=none,id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -19,6 +19,6 @@ server,nowait \
-boot d \
-usb \
-drive file=ftp://host.name:21/url/path/file.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,6 +19,6 @@ server,nowait \
-boot d \
-usb \
-drive file=ftps://host.name:990/url/path/file.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,6 +19,6 @@ server,nowait \
-boot d \
-usb \
-drive file=http://host.name:80/url/path/file.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,6 +19,6 @@ server,nowait \
-boot d \
-usb \
-drive file=https://host.name:443/url/path/file.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -19,6 +19,6 @@ server,nowait \
-boot d \
-usb \
-drive file=tftp://host.name:69/url/path/file.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -21,6 +21,6 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on \
-drive if=none,id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -24,8 +24,8 @@ id=drive-virtio-disk0 \
-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive if=none,media=cdrom,id=drive-ide0-1-1,readonly=on \
-drive if=none,id=drive-ide0-1-1,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=1,drive=drive-ide0-1-1,id=ide0-1-1 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -21,6 +21,6 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/root/boot.iso,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/root/boot.iso,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -25,7 +25,7 @@ id=drive-virtio-disk0,copy-on-read=on \
-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-net-pci,tx=bh,vlan=0,id=net0,mac=52:54:00:e5:48:58,bus=pci.0,\
addr=0x3 \

View File

@ -21,6 +21,6 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -21,6 +21,6 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=directsync \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=unsafe \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=none \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=writeback \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=writethrough \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -24,6 +24,6 @@ id=drive-virtio-disk0,discard=unmap,detect-zeroes=unmap \
-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on,discard=ignore,detect-zeroes=on \
id=drive-ide0-1-0,media=cdrom,readonly=on,discard=ignore,detect-zeroes=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -24,6 +24,6 @@ id=drive-virtio-disk0,discard=unmap \
-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on,discard=ignore \
id=drive-ide0-1-0,media=cdrom,readonly=on,discard=ignore \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=none,werror=enospc \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=none,werror=stop,rerror=stop \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -22,6 +22,6 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
cache=none,werror=report,rerror=ignore \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -21,6 +21,6 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0

View File

@ -21,8 +21,8 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,\
bootindex=2 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0,\
bootindex=1 \
-drive file=/dev/fd0,format=raw,if=none,id=drive-fdc0-0-0 \

View File

@ -22,7 +22,7 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/sr0,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/sr0,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -22,7 +22,7 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/sr0,format=raw,if=none,media=cdrom,id=drive-ide0-1-0,\
-drive file=/dev/sr0,format=raw,if=none,id=drive-ide0-1-0,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -22,7 +22,7 @@ server,nowait \
-drive file=/dev/HostVG/QEMUGuest1,format=qcow2,if=none,id=drive-ide0-0-0,\
serial=XYZXYZXYZYXXYZYZYXYZY,cache=none \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -25,7 +25,7 @@ id=drive-virtio-disk0 \
-device virtio-blk-pci,ioeventfd=on,scsi=off,bus=pci.0,addr=0x4,\
drive=drive-virtio-disk0,id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-net-pci,tx=bh,ioeventfd=off,vlan=0,id=net0,\
mac=52:54:00:e5:48:58,bus=pci.0,addr=0x3 \

View File

@ -21,8 +21,8 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive file=/tmp/data.img,format=raw,if=none,id=drive-virtio-disk0 \
-device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\

View File

@ -25,7 +25,7 @@ cache=none \
-drive file=/dev/HostVG/QEMUGuest3,format=qcow2,if=none,id=drive-ide0-2-0,\
cache=none \
-device ide-drive,bus=ide.2,unit=0,drive=drive-ide0-2-0,id=ide0-2-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -20,15 +20,15 @@ server,nowait \
-no-acpi \
-boot c \
-usb \
-drive file=/some/block/device/unit:0:0:1,if=none,media=cdrom,\
id=drive-ide0-0-1,readonly=on \
-drive file=/some/block/device/unit:0:0:1,if=none,id=drive-ide0-0-1,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \
-drive file=iscsi://iscsi.example.com:3260/demo-target/2,if=none,media=cdrom,\
id=drive-ide0-0-2,readonly=on \
-drive file=iscsi://iscsi.example.com:3260/demo-target/2,if=none,\
id=drive-ide0-0-2,media=cdrom,readonly=on \
-device ide-drive,bus=ide.0,unit=2,drive=drive-ide0-0-2,id=ide0-0-2 \
-drive file=/tmp/idedisk.img,format=raw,if=none,id=drive-ide0-0-3 \
-device ide-drive,bus=ide.0,unit=3,drive=drive-ide0-0-3,id=ide0-0-3 \
-drive file=iscsi://iscsi.example.com:3260/demo-target/3,if=none,media=cdrom,\
id=drive-ide0-0-4,readonly=on \
-drive file=iscsi://iscsi.example.com:3260/demo-target/3,if=none,\
id=drive-ide0-0-4,media=cdrom,readonly=on \
-device ide-drive,bus=ide.0,unit=4,drive=drive-ide0-0-4,id=ide0-0-4 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3

View File

@ -20,10 +20,10 @@ server,nowait \
-no-acpi \
-boot c \
-usb \
-drive file=/some/block/device/cdrom,if=none,media=cdrom,id=drive-ide0-0-1,\
-drive file=/some/block/device/cdrom,if=none,id=drive-ide0-0-1,media=cdrom,\
readonly=on \
-device ide-drive,bus=ide.0,unit=1,drive=drive-ide0-0-1,id=ide0-0-1 \
-drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on \
-drive if=none,id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive file=/tmp/idedisk.img,format=raw,if=none,id=drive-ide0-0-2 \
-device ide-drive,bus=ide.0,unit=2,drive=drive-ide0-0-2,id=ide0-0-2 \

View File

@ -21,8 +21,8 @@ server,nowait \
-usb \
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/dev/HostVG/QEMUGuest2,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive file=/tmp/data.img,format=raw,if=none,id=drive-virtio-disk0 \
-device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\

View File

@ -25,7 +25,7 @@ id=drive-virtio-disk0 \
-device virtio-blk-pci,event_idx=on,scsi=off,bus=pci.0,addr=0x4,\
drive=drive-virtio-disk0,id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device virtio-net-pci,event_idx=off,vlan=0,id=net0,mac=52:54:00:e5:48:58,\
bus=pci.0,addr=0x3 \

View File

@ -25,7 +25,7 @@ id=drive-virtio-disk0 \
-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive file=/var/lib/libvirt/Fedora-14-x86_64-Live-KDE.iso,format=raw,if=none,\
media=cdrom,id=drive-ide0-1-0,readonly=on \
id=drive-ide0-1-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device rtl8139,vlan=0,id=net0,mac=52:54:00:71:70:89,bus=pci.0,addr=0x7 \
-net tap,fd=3,vlan=0,name=hostnet0 \

View File

@ -38,7 +38,7 @@ addr=0x6 \
id=drive-virtio-disk0 \
-device virtio-blk-pci,bus=pci.0,addr=0x7,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-drive if=none,media=cdrom,id=drive-ide0-0-0,readonly=on \
-drive if=none,id=drive-ide0-0-0,media=cdrom,readonly=on \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-chardev socket,id=charchannel0,\
path=/var/lib/libvirt/qemu/channel/target/fedora.org.qemu.guest_agent.0,server,\

View File

@ -25,8 +25,8 @@ server,nowait \
-device pci-bridge,chassis_nr=6,id=pci.6,bus=pci.0,addr=0x8 \
-device pci-bridge,chassis_nr=7,id=pci.7,bus=pci.0,addr=0x9 \
-usb \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-vga cirrus \
-device virtio-balloon-pci,id=balloon0,bus=pci.7,addr=0x6

View File

@ -26,8 +26,8 @@ server,nowait \
-device pci-bridge,chassis_nr=6,id=pci.6,bus=pci.0,addr=0x9 \
-device pci-bridge,chassis_nr=7,id=pci.7,bus=pci.0,addr=0xa \
-usb \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-vga cirrus \
-device virtio-balloon-pci,id=balloon0,bus=pci.4,addr=0x6

View File

@ -19,8 +19,8 @@ server,nowait \
-no-acpi \
-boot c \
-usb \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
id=drive-virtio-disk0,readonly=on \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,id=drive-virtio-disk0,\
media=cdrom,readonly=on \
-device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\
id=virtio-disk0 \
-vga cirrus \

View File

@ -19,8 +19,8 @@ server,nowait \
-device pci-bridge,chassis_nr=1,id=pci.1,bus=pci.0,addr=0x3 \
-device pci-bridge,chassis_nr=2,id=pci.2,bus=pci.0,addr=0x4 \
-usb \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-device rtl8139,vlan=0,id=net0,mac=52:54:00:f1:95:51,bus=pci.0,addr=0x5 \
-net user,vlan=0,name=hostnet0 \

View File

@ -18,8 +18,8 @@ server,nowait \
-mon chardev=charmonitor,id=monitor,mode=readline \
-boot c \
-usb \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,media=cdrom,\
id=drive-ide0-1-0,readonly=on \
-drive file=/var/iso/f18kde.iso,format=raw,if=none,id=drive-ide0-1-0,\
media=cdrom,readonly=on \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 \
-drive file=/var/lib/libvirt/images/test.img,format=raw,if=none,\
id=drive-virtio-disk0 \

View File

@ -43,7 +43,7 @@ id=drive-ua-myEncryptedDisk1 \
-device virtio-blk-pci,bus=pci.0,addr=0x7,drive=drive-ua-myEncryptedDisk1,\
id=ua-myEncryptedDisk1 \
-drive file=/home/zippy/tmp/install-amd64-minimal-20140619.iso,format=raw,\
if=none,media=cdrom,id=drive-ua-WhatAnAwesomeCDROM,readonly=on,cache=none \
if=none,id=drive-ua-WhatAnAwesomeCDROM,media=cdrom,readonly=on,cache=none \
-device ide-drive,bus=ide.1,unit=0,drive=drive-ua-WhatAnAwesomeCDROM,\
id=ua-WhatAnAwesomeCDROM \
-device virtio-net-pci,vlan=0,id=ua-CheckoutThisNIC,mac=52:54:00:d6:c0:0b,\