qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [QEMU question] Disk hot plugging without working PCI hotplug - possible?
@ 2013-06-06 10:13 Alexey Kardashevskiy
  2013-06-06 12:44 ` Frederic Konrad
  0 siblings, 1 reply; 6+ messages in thread
From: Alexey Kardashevskiy @ 2013-06-06 10:13 UTC (permalink / raw)
  To: qemu-devel@nongnu.org; +Cc: Michael S. Tsirkin

Hi!

For the pseries platform (server PPC64) we do not support PCI hotplug yet.
However we still want to hot plug disks.

As a workaround, we could add multiple SCSI host devices (virtio-scsi-pci,
spapr-vscsi) without any disk attached and later (using qemu console)
attach drives to them as we do with the "-drive" parameter in the command line.

So I enabled CONFIG_PCI_HOTPLUG_OLD=y and tried.

However, drive_add console command works only with PCI what eliminates
"spapr-vscsi" from the list. Oookay.

Then I tried running qemu with "-device virtio-scsi-pci,id=device0" and
later doing "drive_add 0 file=virtimg/test1" from the qemu console. This
time qemu responded with "Device is not a SCSI adapter" what is correct as
nowadays virtio-XXXX-pci devices are not what are they called as they
simply create underlying virtio-bus, attach a real virtio-XXXX-device there
(which is not PCI) and only then attach disk to non-PCI virtio device.

So as I see there is no way to attach a disk to an existing controller in
already running qemu.

This is how I add disks to qemu now:
 -device virtio-scsi-pci,id=virtioscsi0 \
 -drive file=virtimg/fc18guest,if=none,id=drive0,readonly=off,
format=raw,media=disk,werror=stop,rerror=stop \
 -device scsi-disk,id=scsidisk0,bus=virtioscsi0.0,channel=0,
scsi-id=0,lun=0,drive=drive0,removable=off \

I want to only add "-device virtio-scsi-pci,id=virtioscsi0" to the command
line and do the rest from the qemu console.

Am I missing some useful command from qemu console or anything else? Thanks!


-- 
Alexey

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-06-07  3:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-06 10:13 [Qemu-devel] [QEMU question] Disk hot plugging without working PCI hotplug - possible? Alexey Kardashevskiy
2013-06-06 12:44 ` Frederic Konrad
2013-06-06 13:59   ` Alexey Kardashevskiy
2013-06-06 14:29     ` Frederic Konrad
2013-06-07  0:05       ` Alexey Kardashevskiy
2013-06-07  3:40       ` Alexey Kardashevskiy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).