Re: How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread Liang Chaojun
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-com

Re: How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread Peter Krempa
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

Re: [libvirt PATCH 04/10] virDomainNumaDefNodeDistanceParseXML: Use virXMLProp*

2021-05-13 Thread Tim Wiederhake
On Tue, 2021-05-11 at 12:15 -0400, Laine Stump wrote: > On 5/11/21 11:01 AM, Tim Wiederhake wrote: > > Signed-off-by: Tim Wiederhake > > --- > > src/conf/numa_conf.c | 42 --- > > --- > > 1 file changed, 4 insertions(+), 38 deletions(-) > > > > diff --git a/

[libvirt PATCH v2 4/6] virDomainNumaDefNodeDistanceParseXML: Use virXMLProp*

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/numa_conf.c | 42 -- 1 file changed, 4 insertions(+), 38 deletions(-) diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index 15bfda3aa1..60cd7767ef 100644 --- a/src/conf/numa_conf.c +++ b/src/conf/numa_con

[libvirt PATCH v2 2/6] virDomainNumatuneNodeParseXML: Use virXMLProp*

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/numa_conf.c | 45 +--- 1 file changed, 13 insertions(+), 32 deletions(-) diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index 932af4a185..bae59ac7b8 100644 --- a/src/conf/numa_conf.c +++ b/src/conf/numa_

[libvirt PATCH v2 1/6] virNodeDeviceDefParseXML: Use g_auto*

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/node_device_conf.c | 44 +++-- 1 file changed, 18 insertions(+), 26 deletions(-) diff --git a/src/conf/node_device_conf.c b/src/conf/node_device_conf.c index 4477a8d9d2..861f43f6c4 100644 --- a/src/conf/node_device_conf.c

[libvirt PATCH v2 5/6] virDomainNumaDefParseXML: Use virXMLProp*

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/numa_conf.c | 128 +- .../hugepages-memaccess-invalid.err | 2 +- 2 files changed, 35 insertions(+), 95 deletions(-) diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index 60cd7767ef..9fe49989

[libvirt PATCH v2 6/6] virDomainNumaDefParseXML: Use g_autofree

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/numa_conf.c | 84 +--- 1 file changed, 40 insertions(+), 44 deletions(-) diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index 9fe4998951..525bc28962 100644 --- a/src/conf/numa_conf.c +++ b/src/conf/numa_

[libvirt PATCH v2 0/6] Refactor more XML parsing boilerplate code, part X

2021-05-13 Thread Tim Wiederhake
For background, see https://listman.redhat.com/archives/libvir-list/2021-April/msg00668.html Changes since V1: * Split up VIR_FREE'd and reused ´g_autofree xmlNodePtr *´ variables. Tim Wiederhake (6): virNodeDeviceDefParseXML: Use g_auto* virDomainNumatuneNodeParseXML: Use virXMLProp* virDo

[libvirt PATCH v2 3/6] virDomainNumatuneNodeParseXML: Use g_autofree

2021-05-13 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/numa_conf.c | 34 ++ 1 file changed, 14 insertions(+), 20 deletions(-) diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index bae59ac7b8..15bfda3aa1 100644 --- a/src/conf/numa_conf.c +++ b/src/conf/numa_conf.c @@

Re: How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread Liang Chaojun
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. Thanks a lot! > 在 2021年5月13日,22:25,Peter Krempa 写道: > > On Thu, May 13, 2021 at 15:25:23 +0800, 梁朝军 wrote: >> Hi Guy, >> >>

Re: How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread Peter Krempa
On Thu, May 13, 2021 at 15:25:23 +0800, 梁朝军 wrote: >Hi Guy, > >Does anyone clear how to hot plugin a new vhost-user-blk-pci device to a >running VM? > >Before staring vm , I pass the disk through QEMU command line like below. > > > > > value='memory-backend-fi

How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread 梁朝军
Hi Guy,Does  anyone clear how to hot plugin a new vhost-user-blk-pci device to a running VM?Before staring vm , I pass the disk through QEMU command line  like below.                        But I don’t know how to live add a vhost-user-blk-pci device on running VM even with calling attachDevice API

[libvirt PATCH 2/2] storage_file: add support to probe cluster_size from QCOW2 images

2021-05-13 Thread Pavel Hrdina
>From QEMU docs/interop/qcow2.txt : Byte 20 - 23: cluster_bits Number of bits that are used for addressing an offset within a cluster (1 << cluster_bits is the cluster size). With this patch libvirt will be able to report the current cluster_size for

[libvirt PATCH 1/2] storage: add support for QCOW2 cluster_size option

2021-05-13 Thread Pavel Hrdina
The default value hard-coded in QEMU (64KiB) is not always the ideal. Having a possibility to set the cluster_size by user may in specific use-cases improve performance for QCOW2 images. QEMU internally has some limits, the value has to be between 512B and 2048KiB and must by power of two, except

[libvirt PATCH 0/2] storage_driver: add support for cluster_size QCOW2 option

2021-05-13 Thread Pavel Hrdina
Pavel Hrdina (2): storage: add support for QCOW2 cluster_size option storage_file: add support to probe cluster_size from QCOW2 images docs/formatstorage.html.in| 6 ++ docs/schemas/storagecommon.rng| 7 +++ docs/schemas/storagevol.rng |

Re: [PATCH libvirt v1] tests: add capabilities for QEMU 6.0.0 on s390x

2021-05-13 Thread Michal Prívozník
On 5/13/21 11:53 AM, Andrea Bolognani wrote: > On Thu, May 13, 2021 at 11:39:24AM +0200, Michal Prívozník wrote: >> On 5/12/21 6:11 PM, Andrea Bolognani wrote: >>> Overall looks reasonable, but comparing the computed capabilities >>> with those for QEMU 5.2 highlights a couple of changes that I'm n

Re: [PATCH libvirt v1] tests: add capabilities for QEMU 6.0.0 on s390x

2021-05-13 Thread Andrea Bolognani
On Thu, May 13, 2021 at 11:39:24AM +0200, Michal Prívozník wrote: > On 5/12/21 6:11 PM, Andrea Bolognani wrote: > > Overall looks reasonable, but comparing the computed capabilities > > with those for QEMU 5.2 highlights a couple of changes that I'm not > > so sure about, specifically > > > > ---

Re: [PATCH libvirt v1] tests: add capabilities for QEMU 6.0.0 on s390x

2021-05-13 Thread Michal Prívozník
On 5/12/21 6:11 PM, Andrea Bolognani wrote: > On Mon, May 10, 2021 at 01:39:07PM +0200, Shalini Chellathurai Saroja wrote: >> Add replies and xml files for QEMU 6.0.0 on s390x. >> >> Signed-off-by: Shalini Chellathurai Saroja >> Reviewed-by: Bjoern Walk >> Reviewed-by: Boris Fiuczynski >> --- >> Th

How to hot plugin a new vhost-user-blk-pci device to running VM?

2021-05-13 Thread Liang Chaojun
Hi Guy, Does anyone clear how to hot plugin a new vhost-user-blk-pci device to a running VM? Before staring vm , I pass the disk through QEMU command line like below. But I don’t know how to live add a vhost-user-blk-pci device on running VM even with calling attachDevice API

Re: [libvirt PATCH v3 00/10] make internal only secrets work with split daemons

2021-05-13 Thread Michal Prívozník
On 5/12/21 3:33 PM, Daniel P. Berrangé wrote: > If you define a secret with private="yes", then libvirt won't let any > client query the secret value after it is set. Only other libvirt > drivers inside the daemon can query it by passing a special internal > only flag to the virSecretGetValue API.

Re: [PATCH] rpm: Set version information for libvirt-admin virtual name

2021-05-13 Thread Michal Prívozník
On 5/12/21 1:22 AM, Neal Gompa wrote: > The libvirt-daemon package now provides the 'libvirt-admin' virtual > name, but the Provides stanza doesn't declare version information, > which breaks things depending on that package using a versioned > dependency. Fix this by setting the version-release of

Re: [libvirt PATCH 00/10] Refactor more XML parsing boilerplate code, part X

2021-05-13 Thread Michal Prívozník
On 5/11/21 5:01 PM, Tim Wiederhake wrote: > For background, see > https://listman.redhat.com/archives/libvir-list/2021-April/msg00668.html > > Tim Wiederhake (10): > virNodeDeviceDefParseXML: Use g_auto* > virDomainNumatuneNodeParseXML: Use virXMLProp* > virDomainNumatuneNodeParseXML: Use g_

Re: After blockcopy with pivot, a dirty-bitmap is added, but not been removed automatically.

2021-05-13 Thread Peter Krempa
On Thu, May 13, 2021 at 13:55:22 +0800, ChangLimin wrote: > >On Mon, May 10, 2021 at 13:34:41 +0800, ChangLimin wrote: > >> Hi Peter, > >> > >> Since > >> https://libvirt.org/git/?p=libvirt.git;a=commitdiff;h=7bfff40fdfe5410c446c1cd8ec413e00530faf7d, > >> after blockcopy with pivot, a dirty-bitmap