Peter Krempa
2021-May-13 16:47 UTC
How to hot plugin a new vhost-user-blk-pci device to running VM?
On Thu, May 13, 2021 at 23:11:36 +0800, Liang Chaojun wrote:> > > Thanks Peter for your quickly response. Is there any workaround to do that?As you know we must take care the risk of using latest version in product environment.Manual approach is to use 'virsh qemu-monitor-command' or the equivalent to attach the appropriate backends and frontends manually. Obviously that is very far from anything I'd recommend to use in any production environment.
Liang Chaojun
2021-May-14 06:33 UTC
How to hot plugin a new vhost-user-blk-pci device to running VM?
Thanks?I have tried qemu monitor as below. I used chardev_add to add a chardev and used device_add it to running vm. But i often hit a issue and cause the vm crash. qemu-system-x86_64: ../hw/virtio/vhost.c:1566: vhost_dev_get_config: Assertion `hdev->vhost_ops' failed. virsh qemu-monitor-command spdk1 --hmp --cmd "chardev-add socket,id=spdk_vhost_blk0,path=/var/tmp/vhost.0,reconnect=1" virsh qemu-monitor-command spdk1 --hmp --cmd "device_add vhost-user-blk-pci,chardev=spdk_vhost_blk0,num-queues=4"> ? 2021?5?14??00:47?Peter Krempa <pkrempa at redhat.com> ??? > > ?On Thu, May 13, 2021 at 23:11:36 +0800, Liang Chaojun wrote: >> >> >> Thanks Peter for your quickly response. Is there any workaround to do that?As you know we must take care the risk of using latest version in product environment. > > Manual approach is to use 'virsh qemu-monitor-command' or the equivalent > to attach the appropriate backends and frontends manually. > > Obviously that is very far from anything I'd recommend to use in any > production environment. >
Liang Chaojun
2021-May-14 06:33 UTC
How to hot plugin a new vhost-user-blk-pci device to running VM?
Thanks?I have tried qemu monitor as below. I used chardev_add to add a chardev and used device_add it to running vm. But i often hit a issue and cause the vm crash. qemu-system-x86_64: ../hw/virtio/vhost.c:1566: vhost_dev_get_config: Assertion `hdev->vhost_ops' failed. virsh qemu-monitor-command spdk1 --hmp --cmd "chardev-add socket,id=spdk_vhost_blk0,path=/var/tmp/vhost.0,reconnect=1" virsh qemu-monitor-command spdk1 --hmp --cmd "device_add vhost-user-blk-pci,chardev=spdk_vhost_blk0,num-queues=4"> ? 2021?5?14??00:47?Peter Krempa <pkrempa at redhat.com> ??? > > ?On Thu, May 13, 2021 at 23:11:36 +0800, Liang Chaojun wrote: >> >> >> Thanks Peter for your quickly response. Is there any workaround to do that?As you know we must take care the risk of using latest version in product environment. > > Manual approach is to use 'virsh qemu-monitor-command' or the equivalent > to attach the appropriate backends and frontends manually. > > Obviously that is very far from anything I'd recommend to use in any > production environment. >