Re: Squelch 'eof from qemu monitor' error on normal VM shutdown

2021-09-30 Thread Jim Fehlig
On 9/30/21 11:24, Daniel P. Berrangé wrote: On Thu, Sep 30, 2021 at 11:15:18AM -0600, Jim Fehlig wrote: On 9/29/21 21:29, Jim Fehlig wrote: Hi All, Likely Christian received a bug report that motivated commit aeda1b8c56, which was later reverted by Michal with commit 72adaf2f10. In the past,

Re: Squelch 'eof from qemu monitor' error on normal VM shutdown

2021-09-30 Thread Jim Fehlig
On 9/29/21 21:29, Jim Fehlig wrote: Hi All, Likely Christian received a bug report that motivated commit aeda1b8c56, which was later reverted by Michal with commit 72adaf2f10. In the past, I recall being asked about "internal error: End of file from qemu monitor" on normal VM shutdown and

Re: [PATCH] failover: allow to pause the VM during the migration

2021-09-30 Thread Laine Stump
On 9/30/21 1:09 PM, Laurent Vivier wrote: If we want to save a snapshot of a VM to a file, we used to follow the following steps: 1- stop the VM: (qemu) stop 2- migrate the VM to a file: (qemu) migrate "exec:cat > snapshot" 3- resume the VM: (qemu) cont After that we can restore

Re: Squelch 'eof from qemu monitor' error on normal VM shutdown

2021-09-30 Thread Daniel P . Berrangé
On Thu, Sep 30, 2021 at 11:15:18AM -0600, Jim Fehlig wrote: > On 9/29/21 21:29, Jim Fehlig wrote: > > Hi All, > > > > Likely Christian received a bug report that motivated commit aeda1b8c56, > > which was later reverted by Michal with commit 72adaf2f10. In the past, > > I recall being asked about

Re: [Libguestfs] translating CD-ROM device paths from i440fx to Q35 in virt-v2v (was: test-v2v-cdrom: update the CD-ROM's bus to SATA in the converted domain)

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 12:53:51PM +0100, Richard W.M. Jones wrote: > On Thu, Sep 30, 2021 at 01:12:39PM +0200, Laszlo Ersek wrote: > > All this requires virt-v2v to parse complete elements from the > > original domain XML, and to generate complete elements in the > > destination domain XML. Is

Re: [PATCH v3 0/5] Add support for two i386 pm options which control acpi hotplug

2021-09-30 Thread Ani Sinha
On Thu, Sep 30, 2021 at 18:52 Laine Stump wrote: > On 9/30/21 2:16 AM, Ani Sinha wrote: > > On Fri, Sep 24, 2021 at 2:16 AM Laine Stump wrote: > >> > >> On 9/11/21 11:26 PM, Ani Sinha wrote: > >>> The above two options are only available for qemu driver and that too > for x86 > >>> guests only.

Re: [PATCH v3 0/5] Add support for two i386 pm options which control acpi hotplug

2021-09-30 Thread Laine Stump
On 9/30/21 2:16 AM, Ani Sinha wrote: On Fri, Sep 24, 2021 at 2:16 AM Laine Stump wrote: On 9/11/21 11:26 PM, Ani Sinha wrote: The above two options are only available for qemu driver and that too for x86 guests only. Both of them are global options. ``acpi-hotplug-bridge`` option enables or

Re: [PATCH 5/5] qemu: Prefer -numa cpu over -numa node,cpus=

2021-09-30 Thread Peter Krempa
On Tue, Sep 21, 2021 at 16:50:31 +0200, Michal Privoznik wrote: > QEMU is trying to obsolete -numa node,cpus= because that uses > ambiguous vCPU id to [socket, die, core, thread] mapping. The new > form is: > > -numa cpu,node-id=N,socket-id=S,die-id=D,core-id=C,thread-id=T > > which is

Re: translating CD-ROM device paths from i440fx to Q35 in virt-v2v (was: test-v2v-cdrom: update the CD-ROM's bus to SATA in the converted domain)

2021-09-30 Thread Daniel P . Berrangé
On Thu, Sep 30, 2021 at 01:12:39PM +0200, Laszlo Ersek wrote: > On 09/29/21 21:22, Richard W.M. Jones wrote: > Please correct me if I'm wrong: at the moment, I believe virt-v2v parses > and manipulates the following elements and attributes in the domain XML: > > > > >

Re: translating CD-ROM device paths from i440fx to Q35 in virt-v2v (was: test-v2v-cdrom: update the CD-ROM's bus to SATA in the converted domain)

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 01:12:39PM +0200, Laszlo Ersek wrote: > All this requires virt-v2v to parse complete elements from the > original domain XML, and to generate complete elements in the > destination domain XML. Is that feasible? The input is not always (in fact, hardly ever) full libvirt

Re: [PATCH 4/5] qemuBuildNumaCommandLine: Separate out building of CPU list

2021-09-30 Thread Peter Krempa
On Tue, Sep 21, 2021 at 16:50:30 +0200, Michal Privoznik wrote: > Signed-off-by: Michal Privoznik > --- > src/qemu/qemu_command.c | 43 ++--- > 1 file changed, 27 insertions(+), 16 deletions(-) Reviewed-by: Michal Privoznik

Re: [PATCH 3/5] qemuBuildNumaCommandLine: Move vars into loops

2021-09-30 Thread Peter Krempa
On Tue, Sep 21, 2021 at 16:50:29 +0200, Michal Privoznik wrote: > There are two variables that are used only in a single > loop. Move their definitions into their respective blocks. > > Signed-off-by: Michal Privoznik > --- > src/qemu/qemu_command.c | 4 ++-- > 1 file changed, 2 insertions(+),

Re: [PATCH 2/5] virCPUDefParseXML: Prefer virXMLPropUInt over virXPathUInt

2021-09-30 Thread Peter Krempa
On Tue, Sep 21, 2021 at 16:50:28 +0200, Michal Privoznik wrote: > When parsing CPU topology, which is described in > attributes we can use virXMLPropUInt() instead of virXPathUInt() > as the former results in shorter code. > > Signed-off-by: Michal Privoznik > --- > src/conf/cpu_conf.c | 41

[libvirt PATCH v3 7/9] virChrdevFree: Use VIR_WITH_MUTEX_LOCK

2021-09-30 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/virchrdev.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/conf/virchrdev.c b/src/conf/virchrdev.c index 0184a1ae10..1cf727d46e 100644 --- a/src/conf/virchrdev.c +++ b/src/conf/virchrdev.c @@ -291,10 +291,10 @@ void

[libvirt PATCH v3 6/9] virChrdevFDStreamCloseCb: Use virLockGuardNew

2021-09-30 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/conf/virchrdev.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/conf/virchrdev.c b/src/conf/virchrdev.c index 5d6de68427..0184a1ae10 100644 --- a/src/conf/virchrdev.c +++ b/src/conf/virchrdev.c @@ -237,12 +237,10 @@ static void

[libvirt PATCH v3 4/9] virobject: Introduce virObjectLockGuard

2021-09-30 Thread Tim Wiederhake
Typical usage: void foobar(virObjectLockable *obj) { VIR_LOCK_GUARD lock = virObjectLockGuard(obj); /* `obj` is locked, and released automatically on scope exit */ ... } Signed-off-by: Tim Wiederhake --- src/libvirt_private.syms | 1 + src/util/virobject.c

[libvirt PATCH v3 2/9] virthread: Introduce virLockGuard

2021-09-30 Thread Tim Wiederhake
Locks a virMutex on creation and unlocks it in its destructor. The VIR_LOCK_GUARD macro is used instead of "g_autoptr(virLockGuard)" to work around a clang issue (see https://bugs.llvm.org/show_bug.cgi?id=3888 and https://bugs.llvm.org/show_bug.cgi?id=43482). Typical usage: void

[libvirt PATCH v3 9/9] lxcDomainDetachDeviceHostdevUSBLive: Use VIR_WITH_OBJECT_LOCK_GUARD

2021-09-30 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/lxc/lxc_driver.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c index e2720a6f89..528af5d164 100644 --- a/src/lxc/lxc_driver.c +++ b/src/lxc/lxc_driver.c @@ -4079,9 +4079,9 @@

[libvirt PATCH v3 5/9] virobject: Introduce VIR_WITH_OBJECT_LOCK_GUARD

2021-09-30 Thread Tim Wiederhake
Modeled after "WITH_QEMU_LOCK_GUARD" (see qemu's include/qemu/lockable.h). Uses "__LINE__" instead of "__COUNTER__", as the latter is a GNU extension. See comment for typical usage. Signed-off-by: Tim Wiederhake --- src/util/virobject.h | 20 1 file changed, 20

[libvirt PATCH v3 3/9] virthread: Introduce VIR_WITH_MUTEX_LOCK_GUARD

2021-09-30 Thread Tim Wiederhake
Modeled after "WITH_QEMU_LOCK_GUARD" (see qemu's include/qemu/lockable.h). Uses "__LINE__" instead of "__COUNTER__", as the latter is a GNU extension. See comment for typical usage. Signed-off-by: Tim Wiederhake --- src/util/virthread.h | 20 1 file changed, 20

[libvirt PATCH v3 0/9] Automatic mutex management

2021-09-30 Thread Tim Wiederhake
V1: https://listman.redhat.com/archives/libvir-list/2021-August/msg00823.html V2: https://listman.redhat.com/archives/libvir-list/2021-September/msg00249.html Changes since V2: * Dropped VIR_XPATH_NODE_AUTORESTORE simplification. Moved to a separate series. * Dropped the attempt to work around

[libvirt PATCH v3 1/9] internal: Add CONCAT macro

2021-09-30 Thread Tim Wiederhake
Using the two-step idiom to force resolution of other macros, e.g.: #define bar BAR CONCAT_(foo, bar) // foobar CONCAT(foo, bar) // fooBAR Signed-off-by: Tim Wiederhake --- src/internal.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/internal.h b/src/internal.h

[libvirt PATCH v3 8/9] bhyveAutostartDomain: Use virObjectLockGuard

2021-09-30 Thread Tim Wiederhake
Signed-off-by: Tim Wiederhake --- src/bhyve/bhyve_driver.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bhyve/bhyve_driver.c b/src/bhyve/bhyve_driver.c index 516490f6cd..c41de30be9 100644 --- a/src/bhyve/bhyve_driver.c +++ b/src/bhyve/bhyve_driver.c @@ -87,7 +87,8

Re: [PATCH 1/5] virCPUDefParseXML: Parse uint using virXPathUInt()

2021-09-30 Thread Peter Krempa
On Tue, Sep 21, 2021 at 16:50:27 +0200, Michal Privoznik wrote: > There is no need to use virXPathULong() and a temporary UL > variable if we can use virXPathUInt() directly. > > Signed-off-by: Michal Privoznik > --- > src/conf/cpu_conf.c | 14 -- > 1 file changed, 4 insertions(+),

translating CD-ROM device paths from i440fx to Q35 in virt-v2v (was: test-v2v-cdrom: update the CD-ROM's bus to SATA in the converted domain)

2021-09-30 Thread Laszlo Ersek
(+libvirt-devel) On 09/29/21 21:22, Richard W.M. Jones wrote: > We currently partially install the virtio block drivers in the Windows > guest (just enough to get the guest to boot on the target), and > Windows itself re-installs the virtio block driver and other drivers > it needs, and that's

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 09:47:01AM +0100, Daniel P. Berrangé wrote: > On Thu, Sep 30, 2021 at 08:33:48AM +0100, Richard W.M. Jones wrote: > > I propose we deprecate the guid parameter in: > > > > -device vmgenid,guid=8987940a-0951-2cc5-e815-10634ff550b9,id=vmgenid0 > > > > Instead it will be

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Daniel P . Berrangé
On Thu, Sep 30, 2021 at 08:33:48AM +0100, Richard W.M. Jones wrote: > > More data: I found a colleague who has a Hyper-V instance with a > Windows guest and he helped me to understand how Hyper-V represents > generation IDs. Hyper-V has had support for generation IDs since long > before

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Laszlo Ersek
On 09/30/21 09:33, Richard W.M. Jones wrote: > > More data: I found a colleague who has a Hyper-V instance with a > Windows guest and he helped me to understand how Hyper-V represents > generation IDs. Hyper-V has had support for generation IDs since long > before Microsoft proposed the feature

Re: [libvirt][PATCH v7 5/5] Add get domaincaps unit test

2021-09-30 Thread Daniel P . Berrangé
On Thu, Sep 30, 2021 at 01:39:20AM +, Huang, Haibin wrote: > > > > -Original Message- > > From: Daniel P. Berrangé > > Sent: Tuesday, September 28, 2021 10:15 PM > > To: Huang, Haibin > > Cc: libvir-list@redhat.com; Ding, Jian-feng ; > > Yang, > > Lin A ; Lu, Lianhao ; > >

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Richard W.M. Jones
More data: I found a colleague who has a Hyper-V instance with a Windows guest and he helped me to understand how Hyper-V represents generation IDs. Hyper-V has had support for generation IDs since long before Microsoft proposed the feature for standardization. Originally (I think pre-2013)

Squelch 'eof from qemu monitor' error on normal VM shutdown

2021-09-30 Thread Jim Fehlig
Hi All, Likely Christian received a bug report that motivated commit aeda1b8c56, which was later reverted by Michal with commit 72adaf2f10. In the past, I recall being asked about "internal error: End of file from qemu monitor" on normal VM shutdown and gave a hand wavy response using some of

Re: [PATCH v3 0/5] Add support for two i386 pm options which control acpi hotplug

2021-09-30 Thread Ani Sinha
On Fri, Sep 24, 2021 at 2:16 AM Laine Stump wrote: > > On 9/11/21 11:26 PM, Ani Sinha wrote: > > Hi all: > > > > This patchset introduces libvirt xml support for the following two pm conf > > options: > > > > > > > > > > > > (before I get into a more radical discussion about different