Entering freeze for libvirt-6.10.0

2020-11-24 Thread Jiri Denemark
I have just tagged v6.10.0-rc1 in the repository and pushed signed tarballs and source RPMs to https://libvirt.org/sources/ Please give the release candidate some testing and in case you find a serious issue which should have a fix in the upcoming release, feel free to reply to this thread to

Re: Issue 90 Further Clarifications

2020-11-24 Thread Peter Krempa
On Tue, Nov 24, 2020 at 15:25:01 -0600, Dustan B Helm wrote: > On Tue, Nov 24, 2020 at 12:59 AM Peter Krempa wrote: > > On Mon, Nov 23, 2020 at 17:17:15 -0600, Dustan B Helm wrote: [...] > > We found methods to convert user and group strings into integer IDs in > src/util/virutil.c (the

RE: [PATCH] qemu_conf: Fix double free problem for cfg->firmwares

2020-11-24 Thread Tuguoyi
On a Tuesday in 2020, Ján Tomko wrote: > On a Tuesday in 2020, Tuguoyi wrote: > >cfg->firmwares still points to the original memory address after being > >freed by virFirmwareFreeList(). As cfg get freed, it will be freed again > >even if cfg->nfirmwares=0 which eventually lead to crash. > > >

[PATCH 11/11] news: defining/undefining domains & device attachment for Hyper-V

2020-11-24 Thread Matt Coleman
Signed-off-by: Matt Coleman --- NEWS.rst | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/NEWS.rst b/NEWS.rst index aa8a217eb6..f5b6dfe6a3 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -37,8 +37,11 @@ v6.10.0 (unreleased) ``virDomainGetSchedulerType()``,

[PATCH 10/11] hyperv: implement domainAttachDevice and domainAttachDeviceFlags

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 118 + 1 file changed, 118 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 14371eda39..43d84340ec 100644 ---

[PATCH 06/11] hyperv: attach virtual disks when defining domains

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 244 +++- src/hyperv/hyperv_wmi_classes.h | 1 + 2 files changed, 242 insertions(+), 3 deletions(-) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c

[PATCH 08/11] hyperv: attach virtual optical disks when defining domains

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 128 + 1 file changed, 128 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 3d4aa8ab8e..914f0c743f 100644 ---

[PATCH 05/11] hyperv: create SCSI controllers when defining domains

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 51 ++ 1 file changed, 51 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 559b60d3df..1ad52e598a 100644 ---

[PATCH 02/11] hyperv: implement domainUndefine and domainUndefineFlags

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 60 ++ 1 file changed, 60 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 6d81deb4d9..8e16ff529f 100644 ---

[PATCH 03/11] hyperv: implement domainCreateXML and domainDefineXML

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 114 + 1 file changed, 114 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 8e16ff529f..559b60d3df 100644 ---

[PATCH 07/11] hyperv: attach physical disks when defining domains

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 111 + 1 file changed, 111 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index a3da2ec524..3d4aa8ab8e 100644 ---

[PATCH 09/11] hyperv: attach floppy disks when defining domains

2020-11-24 Thread Matt Coleman
Co-authored-by: Sri Ramanujam Signed-off-by: Matt Coleman --- src/hyperv/hyperv_driver.c | 54 ++ 1 file changed, 54 insertions(+) diff --git a/src/hyperv/hyperv_driver.c b/src/hyperv/hyperv_driver.c index 914f0c743f..14371eda39 100644 ---

Re: [PATCH 00/11] hyperv: implement defining/undefining domains and

2020-11-24 Thread Matt Coleman
`git send-email` did something wonky with the subject and cut off "attaching storage devices" -- Matt

[PATCH 04/11] hyperv: add hypervMsvmVSMSAddResourceSettings

2020-11-24 Thread Matt Coleman
Signed-off-by: Matt Coleman --- src/hyperv/hyperv_wmi.c | 52 + src/hyperv/hyperv_wmi.h | 5 2 files changed, 57 insertions(+) diff --git a/src/hyperv/hyperv_wmi.c b/src/hyperv/hyperv_wmi.c index 466296fe2a..4bace10874 100644 ---

[PATCH 01/11] hyperv: ambiguous VM names will throw an error

2020-11-24 Thread Matt Coleman
Since Hyper-V allows multiple VMs to be created with the same name, some commands produce unpredictable results due to hypervDomainLookupByName's WMI query selecting the wrong domain. For example, this prevents `virsh dumpxml` from outputting XML for the wrong domain. Signed-off-by: Matt Coleman

[PATCH 00/11] hyperv: implement defining/undefining domains and

2020-11-24 Thread Matt Coleman
This series starts by fixing a some dangerous behavior due to ambiguous VM names, since Hyper-V allows multiple VMs to be defined with the same name. That meant that `virsh dumpxml` could return XML for the wrong domain. Additionally, when I implemented `undefine`, it would just select one of the

[PATCH] qemu: Tweak debug message for qemuMigrationSrcPerformPeer2Peer3

2020-11-24 Thread Martin Kletzander
Commit 49186372dbe8 forgot to add the new parameter. Signed-off-by: Martin Kletzander --- Pushed as 'trivial'. src/qemu/qemu_migration.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c index

Re: [libvirt PATCH v3 10/10] cpu_map: Define and enable Snowridge model

2020-11-24 Thread Jiri Denemark
On Mon, Nov 23, 2020 at 15:14:33 +0100, Tim Wiederhake wrote: > Signed-off-by: Tim Wiederhake > --- > src/cpu_map/index.xml | 1 + > src/cpu_map/meson.build | 1 + > src/cpu_map/x86_Snowridge.xml | 71 +++ >

Re: [libvirt PATCH 2/2] docs: Document SELinux caveats when migrating over UNIX sockets

2020-11-24 Thread Jiri Denemark
On Wed, Nov 18, 2020 at 21:10:03 +0100, Martin Kletzander wrote: > The information about sockets having different label than the one on the file > and the way it needs to be set is very difficult to find for those who did not > come across it before. Let's describe what needs to happen in order

Re: [libvirt PATCH 1/2] qemu: Disable NBD TLS migration over UNIX socket

2020-11-24 Thread Jiri Denemark
On Wed, Nov 18, 2020 at 21:10:02 +0100, Martin Kletzander wrote: > Even though it is technically possible, when running the migrations QEMU's > nbd-server-start errors out with: > > "TLS is only supported with IPv4/IPv6" > > We can always enable it when QEMU adds this feature, but for now it

Re: Issue 90 Further Clarifications

2020-11-24 Thread Dustan B Helm
On Tue, Nov 24, 2020 at 12:59 AM Peter Krempa wrote: > On Mon, Nov 23, 2020 at 17:17:15 -0600, Dustan B Helm wrote: > > On Mon, Nov 23, 2020 at 2:33 AM Peter Krempa wrote: > > > > > On Sat, Nov 21, 2020 at 11:20:57 -0600, Dustan B Helm wrote: > > > > We plan to support NFS protocol according to

Re: [PATCH v2 0/5] Hypervisor CPU Baseline Cleanups and Fixes

2020-11-24 Thread Collin Walling
On 11/24/20 3:05 PM, Jiri Denemark wrote: > On Mon, Oct 26, 2020 at 12:12:40 -0400, Collin Walling wrote: >> Polite ping. Have there been relevant updates elsewhere that I might've >> missed? Thanks! > > Oops, sorry about the delay. I replaced the for loop with > virDomainCapsCPUModelsGet in

Re: [PATCH v2 0/5] Hypervisor CPU Baseline Cleanups and Fixes

2020-11-24 Thread Jiri Denemark
On Mon, Oct 26, 2020 at 12:12:40 -0400, Collin Walling wrote: > Polite ping. Have there been relevant updates elsewhere that I might've > missed? Thanks! Oops, sorry about the delay. I replaced the for loop with virDomainCapsCPUModelsGet in patch 4/5 as mentioned in my reply to it and pushed the

Re: [PATCH v2 4/5] qemu: check if cpu model is supported before baselining

2020-11-24 Thread Jiri Denemark
On Thu, Sep 24, 2020 at 20:22:38 -0400, Collin Walling wrote: > Check the provided CPU models against the CPU models > known by the hypervisor before baselining and print > an error if an unrecognized model is found. > > Signed-off-by: Collin Walling > --- > src/qemu/qemu_driver.c | 18

[PATCH 19/21] domain_conf.c: modernize virDomainDefControllersParse()

2020-11-24 Thread Daniel Henrique Barboza
The 'error' label is just returning -1, so let's 'return -1' directly. Use g_autoptr() with virDomainControllerDefPtr to remove the need to call virDomainControllerDefFree() in the error path. There is no need to VIR_FREE(nodes) explictly since 'nodes' is using g_autofree. Signed-off-by: Daniel

[PATCH 20/21] domain_conf.c: use VIR_ERR_CONFIG_UNSUPPORTED in post parse

2020-11-24 Thread Daniel Henrique Barboza
Some occurrences in post parse functions of domain_conf.c are using VIR_ERR_XML_ERROR. Use VIR_ERR_CONFIG_UNSUPPORTED instead since these errors might not be related to a XML use case. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 10 +- 1 file changed, 5

[PATCH 21/21] domain_conf.c: move idmapEntry checks to post parse

2020-11-24 Thread Daniel Henrique Barboza
Create a new function called virDomainDefIdMapPostParse() and use it to move these checks out of virDomainIdmapDefParseXML(). Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 42 ++ 1 file changed, 26 insertions(+), 16 deletions(-)

[PATCH 18/21] domain_conf.c: modernize virDomainControllerDefParseXML()

2020-11-24 Thread Daniel Henrique Barboza
Let's register AUTOPTR_CLEANUP_FUNC for virDomainControllerDefPtr and modernize this function, removing the 'error' label using g_autoptr(). Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 60 -- src/conf/domain_conf.h | 1 + 2 files

[PATCH 17/21] domain_conf.c: move pci-root/pcie-root address check to post parse

2020-11-24 Thread Daniel Henrique Barboza
Move the check made in virDomainControllerDefParseXML() to virDomainControllerDefPostParse(). Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 16 ++-- tests/qemuxml2argvdata/pci-root-address.err | 2 +- 2 files changed, 11 insertions(+), 7

[PATCH 14/21] domain_conf.c: remove 'error' label in virDomainDefTunablesParse()

2020-11-24 Thread Daniel Henrique Barboza
The 'error' label is just doing a 'return -1'. There's also a couple of 'VIR_FREE(nodes)' calls that are happening right before exiting on error, but 'nodes' is already set for autocleanup. These calls can also be removed. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 77

[PATCH 16/21] domain_conf.c: move virDomainPCIControllerOpts checks to post parse

2020-11-24 Thread Daniel Henrique Barboza
virDomainControllerDefParseXML() does a lot of checks with virDomainPCIControllerOpts parameters that can be moved to post parse time, sharing the logic with other use cases that does not rely on XML parsing. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c

[PATCH 05/21] domain_conf.c: do not leak 'video' in virDomainDefParseXML()

2020-11-24 Thread Daniel Henrique Barboza
The 'video' pointer is only being freed on error path, meaning that we're leaking it after each loop restart. There are more opportunities for auto cleanups of virDomainVideoDef pointers, so let's register AUTOPTR_CLEANUP_FUNC for it to use g_autoptr() later on. Signed-off-by: Daniel Henrique

[PATCH 15/21] domain_conf.c: move duplicate blkio path check to post parse

2020-11-24 Thread Daniel Henrique Barboza
Use this check to create a virDomainDefTunablesPostParse() function, that is called on post parse time. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 35 +-- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git

[PATCH 06/21] domain_conf.c: move primary video check to virDomainDefPostParseVideo()

2020-11-24 Thread Daniel Henrique Barboza
Move it to post parse since it's not related to XML parsing. Since we don't have a failure test for this scenario, a new 'video-multiple-primaries' test was added to test this failure case. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c| 24

[PATCH 08/21] domain_conf.c: move QXL attributes check to virDomainVideoDefPostParse()

2020-11-24 Thread Daniel Henrique Barboza
These checks are not related to XML parsing and can be moved to post parse time. Errors were changed from VIR_ERR_XML_ERROR to VIR_ERR_CONFIG_UNSUPPORTED. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 43 -- 1 file changed, 25

[PATCH 03/21] domain_conf.c: modernize virDomainDefBootOrderPostParse()

2020-11-24 Thread Daniel Henrique Barboza
Use g_autoptr() with the hash and remove the 'cleanup' label. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 15 +-- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 4229add26d..f0300b870d

[PATCH 04/21] domain_conf.c: move boot related timeouts check to post parse

2020-11-24 Thread Daniel Henrique Barboza
This patch creates a new function, virDomainDefBootPostParse(), to host the validation of boot menu timeout and rebootTimeout to post parse time. The checks in virDomainDefParseBootXML() were changed to throw VIR_ERR_XML_ERROR in case of parse error of those values. Signed-off-by: Daniel Henrique

[PATCH 12/21] domain_conf.c: move smartcard address check to post parse

2020-11-24 Thread Daniel Henrique Barboza
This check is not related to XML parsing and can be moved to post parse time. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 25 ++--- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index

[PATCH 13/21] domain_conf.c: modernize virDomainSmartcardDefParseXML

2020-11-24 Thread Daniel Henrique Barboza
Register a AUTOPTR_CLEANUP_FUNC for virDomainSmartcardDef and use g_autoptr() to eliminate the 'error' label. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 34 +++--- src/conf/domain_conf.h | 1 + 2 files changed, 16 insertions(+), 19

[PATCH 07/21] domain_conf.c: use g_autoptr() with virDomainVideoDefPtr

2020-11-24 Thread Daniel Henrique Barboza
This will modernize virDomainVideoDefParseXML() and virDomainDefAddImplicitVideo() by removing unneeded cleanup labels. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 48 ++ 1 file changed, 20 insertions(+), 28 deletions(-) diff

[PATCH 10/21] domain_conf: modernize virDomainDiskDefParseXML()

2020-11-24 Thread Daniel Henrique Barboza
Register an AUTOPTR_CLEANUP_FUNC for virDomainDiskDefPtr, then use g_autoptr() in virDomainDiskDef and virStorageEncryption pointers to get rid of the 'cleanup' and 'error' labels. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 95 +++---

[PATCH 09/21] virstorageencryption.h: add AUTOPTR_CLEANUP_FUNC for virStorageEncryptionPtr

2020-11-24 Thread Daniel Henrique Barboza
This will open an opportunity to modernize virDomainDiskDefParseXML() in the next patch. Signed-off-by: Daniel Henrique Barboza --- src/util/virstorageencryption.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/util/virstorageencryption.h b/src/util/virstorageencryption.h index

[PATCH 11/21] domain_conf.c: move vendor, product and tray checks to post parse

2020-11-24 Thread Daniel Henrique Barboza
The 'tray' check isn't a XML parse specific code and can be pushed to post, in virDomainDiskDefPostParse(). 'vendor' and 'product' string sizes are already checked by the domaincommon.rng schema, but can be of use in post parse time since not all scenarios will go through the XML parsing.

[PATCH 00/21] move checks from parse functions to post parse

2020-11-24 Thread Daniel Henrique Barboza
Hi, This started as a simple NVDIMM change, then I realized there is a Gitlab work item for it [1], so I took the extra mile and did a bit more. I'll copy/paste here the motivation for this kind of change, provided by Cole in [1]: - The code that handles domain/VM XML parsing

[PATCH 02/21] domain_conf.c: use g_autofree in 'dev' in virDomainDefParseBootXML()

2020-11-24 Thread Daniel Henrique Barboza
This spares us of 2 explicit VIR_FREE() calls. Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 5e5905f483..4229add26d 100644 ---

[PATCH 01/21] domain_conf.c: move NVDIMM 'labelsize' check to post parse

2020-11-24 Thread Daniel Henrique Barboza
Move 'labelsize' validation to virDomainMemoryDefPostParse(). Signed-off-by: Daniel Henrique Barboza --- src/conf/domain_conf.c | 43 +- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index

Re: [PATCH 8/8] util: call iptables directly rather than via firewalld

2020-11-24 Thread Laine Stump
On 11/24/20 7:01 AM, Daniel Henrique Barboza wrote: On 11/24/20 12:30 AM, Laine Stump wrote: When libvirt added support for firewalld, we were unable to use firewalld's higher level rules, because they weren't detailed enough and could not be applied to the iptables FORWARD or OUTPUT chains

Re: [PATCH v3 0/2] hyperv: storage volume XML changes

2020-11-24 Thread Daniel P . Berrangé
On Mon, Nov 23, 2020 at 12:39:51PM -0500, Matt Coleman wrote: > Changes since v2: > * raise an error if the parent device cannot be located > * correct the disk count and use constants instead of magic numbers > > Here's a GitLab MR if you'd prefer to review it there: >

Re: [PATCH 0/2] hyperv: storage volume XML changes

2020-11-24 Thread Matt Coleman
> On Nov 23, 2020, at 10:13 AM, Daniel P. Berrangé wrote: > > Side-point > > > Looking at these patches makes me quite aware of the lack of unit > test coverage. The native <-> XML conversions are one of the places > we find most benefit from unit testing, as it catches many regrssions >

Re: [PATCH 0/7] qemu: migration: TLS enforcement and non-shared-storage error improvement

2020-11-24 Thread Ján Tomko
On a Tuesday in 2020, Peter Krempa wrote: A collection of fixes for migration. Peter Krempa (7): docs: migration: Fix example for unix socket migration qemu: migration: Remove TODO about implementing NBD for TUNNELLED migration qemu: migration: Aggregate logic depending on tunnelled

Re: [PATCH 7/7] docs: migration: Add a mention of VIR_MIGRATE_TLS and it's enforcement for qemu

2020-11-24 Thread Ján Tomko
In the commit summary: s/it's/its/ On a Tuesday in 2020, Peter Krempa wrote: Mention the flag to enable TLS and also the knob to enforce it in the qmemu hypervisor driver. s/qmemu/qemu/ Signed-off-by: Peter Krempa --- docs/migration.html.in | 8 1 file changed, 8 insertions(+)

Re: [PATCH 2/7] qemu: migration: Remove TODO about implementing NBD for TUNNELLED migration

2020-11-24 Thread Ján Tomko
On a Tuesday in 2020, Peter Krempa wrote: Our streams are not the best transport for migration data and we support TLS for security now. It's unlikely that there will be enough motivation to add a new migration protocol to tunnell NBD too. s/tunnell/tunnel/ Jano Signed-off-by: Peter Krempa

Re: [PATCH 0/2] qemu: Fix setting of 'current' checkpoint/snapshot

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Peter Krempa wrote: See patch 1 Peter Krempa (2): qemu: snapshot: Write metadata of previously-'current' snapshot on update qemu: checkpoint: Write metadata of previously-'current' checkpoint on update src/qemu/qemu_checkpoint.c | 35

Re: [PATCH 0/5] qemu: Don't abort() when creating internal snapshot with

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Peter Krempa wrote: See patch 5/5 Peter Krempa (5): virCommandAddArg: Don't abort on invalid input virDomainDiskTranslateSourcePool: Don't break error message in half qemuDomainSnapshotForEachQcow2Raw: Avoid a level of indentation qemuDomainSnapshotForEachQcow2Raw: Lock

Re: Migration with "--p2p --tunnelled" hanging in v6.9.0

2020-11-24 Thread Peter Krempa
On Tue, Nov 24, 2020 at 16:05:53 +0100, Christian Ehrhardt wrote: > Hi, [...] > In git/news I only found these changes which sounded to be relevant: > f51cbe92c0 qemu: Allow migration over UNIX socket > c69915ccaf peer2peer migration: allow connecting to local sockets > But I'm not using

Migration with "--p2p --tunnelled" hanging in v6.9.0

2020-11-24 Thread Christian Ehrhardt
Hi, I'm wondering about the best next steps to debug a migration issue. What I found is that with libvirt v6.9.0 a migration hangs if used like: $ virsh migrate --unsafe --live --p2p --tunnelled h-migr-test \ qemu+ssh://testkvm-hirsute-to/system Just "--live --p2p" works fine. Also a bunch

Re: [libvirt PATCH 0/3] Introudce virCommandPassFDIndex

2020-11-24 Thread Peter Krempa
On Tue, Nov 24, 2020 at 15:02:24 +0100, Ján Tomko wrote: > Simplify passing file descriptors via add-fd by adding a new > parameter to virCommandPassFD that returns the index of the passed > FD right away, removing the need to look it up later and pretend > to handle errors which cannot happen -

Re: [PATCH v2 2/2] virnetdaemon: Wait for "daemon-stop" thread to finish before quitting

2020-11-24 Thread Ján Tomko
On a Friday in 2020, Michal Privoznik wrote: When the host is shutting down then we get PrepareForShutdown signal on DBus to which we react by creating a thread which runs virStateStop() and thus qemuStateStop(). But if scheduling the thread is delayed just a but it may happen that we receive

[libvirt PATCH 3/3] qemu: use qemuVirCommandGetDevSet less

2020-11-24 Thread Ján Tomko
Do not look up the index of the passed FD in places where we already have it. Signed-off-by: Ján Tomko --- src/qemu/qemu_command.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index d9c6c4bc43..33f9b96bf8 100644

[libvirt PATCH 1/3] util: introduce virCommandPassFDIndex

2020-11-24 Thread Ján Tomko
Just like virCommandPassFD, but it also returns an index of the passed FD in the FD set. Signed-off-by: Ján Tomko --- src/libvirt_private.syms | 1 + src/util/vircommand.c| 28 ++-- src/util/vircommand.h| 5 + 3 files changed, 32 insertions(+), 2

[libvirt PATCH 2/3] qemu: introduce qemuBuildFDSet

2020-11-24 Thread Ján Tomko
An alternative to qemuVirCommandGetFDSet that takes the index into the passed FD set as an argument and does not try to look it up. Use it as well ass virCommandPassFDIndex in qemuBuildChrChardevFileStr and qemuBuildInterfaceCommandLine. Signed-off-by: Ján Tomko --- src/qemu/qemu_command.c |

[libvirt PATCH 0/3] Introudce virCommandPassFDIndex

2020-11-24 Thread Ján Tomko
Simplify passing file descriptors via add-fd by adding a new parameter to virCommandPassFD that returns the index of the passed FD right away, removing the need to look it up later and pretend to handle errors which cannot happen - we've just put the file descriptor there, why would it not be

[PATCH 7/7] docs: migration: Add a mention of VIR_MIGRATE_TLS and it's enforcement for qemu

2020-11-24 Thread Peter Krempa
Mention the flag to enable TLS and also the knob to enforce it in the qmemu hypervisor driver. Signed-off-by: Peter Krempa --- docs/migration.html.in | 8 1 file changed, 8 insertions(+) diff --git a/docs/migration.html.in b/docs/migration.html.in index c3c64fb51f..b080e3a7f5 100644

[PATCH 5/7] docs: migration: Mention that features may not work with tunnelled migration

2020-11-24 Thread Peter Krempa
Enumerate some features which are incompatible with tunnelled migration. Signed-off-by: Peter Krempa --- docs/migration.html.in | 8 1 file changed, 8 insertions(+) diff --git a/docs/migration.html.in b/docs/migration.html.in index e84e5f5452..c3c64fb51f 100644 ---

[PATCH 4/7] qemu: migration: Forbid tunnelled non-shared storage migration with -blockdev

2020-11-24 Thread Peter Krempa
qemu's internals were not prepared for switching to -blockdev for the legacy storage migration. Add a proper error message since qemu is unlikely to attempt fixing the old protocol. Resolves: https://gitlab.com/libvirt/libvirt/-/issues/65 Signed-off-by: Peter Krempa ---

[PATCH 3/7] qemu: migration: Aggregate logic depending on tunnelled migration

2020-11-24 Thread Peter Krempa
Move and aggregate all the logic which is switched based on whether the migration is tunnelled or not before other checks. Further checks will be added later. While the code is being moved the error message is put on a single line per new coding style. Signed-off-by: Peter Krempa ---

[PATCH 2/7] qemu: migration: Remove TODO about implementing NBD for TUNNELLED migration

2020-11-24 Thread Peter Krempa
Our streams are not the best transport for migration data and we support TLS for security now. It's unlikely that there will be enough motivation to add a new migration protocol to tunnell NBD too. Signed-off-by: Peter Krempa --- src/qemu/qemu_migration.c | 5 + 1 file changed, 1

[PATCH 1/7] docs: migration: Fix example for unix socket migration

2020-11-24 Thread Peter Krempa
Fix the following issues: 1) the very long line is overflowing the code box 2) '--migrateuri' was missing for the qemu data stream 3) '--desturi' was not used making it non-obvious what the argument corresponds to Signed-off-by: Peter Krempa --- docs/migration.html.in | 5 - 1 file

[PATCH 6/7] qemu: conf: Introduce "migrate_tls_force" qemu.conf option

2020-11-24 Thread Peter Krempa
Forgetting to use the VIR_MIGRATE_TLS flag with migration can lead to leak of sensitive information. Add an administrative knob to force use of the flag. Note that without VIR_MIGRATE_PEER2PEER, the migration is driven by an instance of the client library which doesn't necessarily run on either

[PATCH 0/7] qemu: migration: TLS enforcement and non-shared-storage error improvement

2020-11-24 Thread Peter Krempa
A collection of fixes for migration. Peter Krempa (7): docs: migration: Fix example for unix socket migration qemu: migration: Remove TODO about implementing NBD for TUNNELLED migration qemu: migration: Aggregate logic depending on tunnelled migration qemu: migration: Forbid tunnelled

Re: [libvirt PATCH v3] ci: Switch to meson build system

2020-11-24 Thread Andrea Bolognani
On Mon, 2020-11-23 at 18:37 +0100, Erik Skultety wrote: > +++ b/ci/Makefile > @@ -221,12 +203,15 @@ ci-run-command@%: ci-prepare-tree > --user="#$(CI_UID)" \ > --group="#$(CI_GID)" \ > CONFIGURE_OPTS="$$CONFIGURE_OPTS" \ > +

Re: [PATCH 01/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Tuesday in 2020, Ján Tomko wrote: I've changed the commit summary to: util: xml: convert pointers to use g_autofree to distinguish this from the other commits in places where only summaries are shown. On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld -

Re: [PATCH 30/30] util: dnsmasq: remove cleanup labels

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virdnsmasq.c Signed-off-by: Barrett Schonefeld --- src/util/virdnsmasq.c | 46 +-- 1 file changed, 14 insertions(+), 32 deletions(-) diff --git a/src/util/virdnsmasq.c

Re: [PATCH 29/30] util: remove cleanup labels

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virlog.c Signed-off-by: Barrett Schonefeld --- src/util/virlog.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/util/virlog.c b/src/util/virlog.c index e12fd58831..2bf606b8c5 100644 ---

Re: [PATCH 25/30] util: remove cleanup labels

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virsecret.c Signed-off-by: Barrett Schonefeld --- src/util/virsecret.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 24/30] util: remove cleanup labels

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virstorageencryption.c Signed-off-by: Barrett Schonefeld --- src/util/virstorageencryption.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc

Re: [PATCH 22/30] util: remove cleanup labels

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/viruri.c Signed-off-by: Barrett Schonefeld --- src/util/viruri.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/util/viruri.c b/src/util/viruri.c index 704e5b2132..d49821451e 100644 ---

Re: [PATCH 21/30] util: remove cleanup label

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virutil.c Signed-off-by: Barrett Schonefeld --- src/util/virutil.c | 45 - 1 file changed, 16 insertions(+), 29 deletions(-) diff --git a/src/util/virutil.c

Re: [PATCH 20/30] util: remove cleanup label

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virvhba.c Signed-off-by: Barrett Schonefeld --- src/util/virvhba.c | 24 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/src/util/virvhba.c b/src/util/virvhba.c index

Re: [PATCH 19/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/vircgroupv1.c Signed-off-by: Barrett Schonefeld --- src/util/vircgroupv1.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 18/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virdnsmasq.c Signed-off-by: Barrett Schonefeld --- src/util/virdnsmasq.c | 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP

Re: [PATCH 17/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virfile.c Signed-off-by: Barrett Schonefeld --- src/util/virfile.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/util/virfile.c b/src/util/virfile.c index f57272ca2f..38207f1948

Re: [PATCH 16/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virhostcpu.c Signed-off-by: Barrett Schonefeld --- src/util/virhostcpu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 14/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virlog.c Signed-off-by: Barrett Schonefeld --- src/util/virlog.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/util/virlog.c b/src/util/virlog.c index 6b7a4512e9..e12fd58831 100644

Re: [PATCH 15/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virlockspace.c Signed-off-by: Barrett Schonefeld --- src/util/virlockspace.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 13/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virmacmap.c Signed-off-by: Barrett Schonefeld --- src/util/virmacmap.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 12/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virnetdevbandwidth.c Signed-off-by: Barrett Schonefeld --- src/util/virnetdevbandwidth.c | 44 --- 1 file changed, 15 insertions(+), 29 deletions(-) diff --git

Re: [PATCH 0/8] run iptables directly rather than via firewalld

2020-11-24 Thread Daniel Henrique Barboza
On 11/24/20 12:29 AM, Laine Stump wrote: The reasoning for this is explained in Patch 8/8 Laine Stump (8): util: fix typo in VIR_MOCK_WRAP_RET_ARGS() util/tests: enable locking on iptables/ebtables commandlines in unit tests util/tests: enable locking on iptables/ebtables

Re: [PATCH 11/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
util: resctl: convert pointers to use g_autofree On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virresctrl.c Signed-off-by: Barrett Schonefeld --- src/util/virresctrl.c | 25 - 1 file changed, 8 insertions(+), 17 deletions(-) diff --git

Re: [PATCH 8/8] util: call iptables directly rather than via firewalld

2020-11-24 Thread Daniel Henrique Barboza
On 11/24/20 12:30 AM, Laine Stump wrote: When libvirt added support for firewalld, we were unable to use firewalld's higher level rules, because they weren't detailed enough and could not be applied to the iptables FORWARD or OUTPUT chains (only to the INPUT chain). Instead we changed our

Re: [PATCH 10/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virrotatingfile.c Signed-off-by: Barrett Schonefeld --- src/util/virrotatingfile.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/util/virrotatingfile.c b/src/util/virrotatingfile.c

Re: [PATCH 09/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virscsihost.c Signed-off-by: Barrett Schonefeld --- src/util/virscsihost.c | 15 +-- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/util/virscsihost.c b/src/util/virscsihost.c index

Re: [PATCH 08/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virsecret.c Signed-off-by: Barrett Schonefeld --- src/util/virsecret.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 07/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virstorageencryption.c Signed-off-by: Barrett Schonefeld --- src/util/virstorageencryption.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc

Re: [PATCH 06/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virstoragefilebackend.c Signed-off-by: Barrett Schonefeld --- src/util/virstoragefilebackend.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description:

Re: [PATCH 05/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
util: sysinfo: in the commit summary On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virsysinfo.c No need to mention the file. Signed-off-by: Barrett Schonefeld --- src/util/virsysinfo.c | 15 +-- 1 file changed, 5 insertions(+), 10

Re: [PATCH 04/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/viruri.c Signed-off-by: Barrett Schonefeld --- src/util/viruri.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) Reviewed-by: Ján Tomko Jano signature.asc Description: PGP signature

Re: [PATCH 7/8] util: synchronize with firewalld before we start calling iptables directly

2020-11-24 Thread Daniel Henrique Barboza
On 11/24/20 12:30 AM, Laine Stump wrote: When it is starting up, firewalld will delete all existing iptables rules and chains before adding its own rules. If libvirtd were to try to directly add iptables rules during the time before firewalld has finished initializing, firewalld would end up

Re: [PATCH 03/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virutil.c Signed-off-by: Barrett Schonefeld --- src/util/virutil.c | 33 ++--- 1 file changed, 10 insertions(+), 23 deletions(-) diff --git a/src/util/virutil.c b/src/util/virutil.c index

Re: [PATCH 02/30] util: convert pointers to use g_autofree

2020-11-24 Thread Ján Tomko
util: vhba: convert pointers to use g_autofree On a Monday in 2020, Ryan Gahagan wrote: From: Barrett Schonefeld - src/util/virvhba.c No need to mention the file here. Signed-off-by: Barrett Schonefeld --- src/util/virvhba.c | 35 --- 1 file changed, 12

  1   2   >