Re: Proposal: renaming 'master' branch to 'main'

2023-01-17 Thread Martin Kletzander
On Mon, Jan 16, 2023 at 02:55:10PM +, Daniel P. Berrangé wrote: I don't recall exactly when it first came up, but it has been a few years now since the idea of moving away from 'master' as the git default branch name became a topic in OSS communities. Far from the first mention:

Re: [PATCH 0/3] migration: add qemu multifd migration options

2023-01-17 Thread Claudio Fontana
Hi, On 1/16/23 14:42, Jiang Jiacheng wrote: > Add qemu multifd migration options to set multifd-compression > multifd-zlib-level and multifd-zstd-level. I think what you are adding here is a new parallel compression method and parallel compression level option, and a specific implementation for

Re: [PATCH 1/3] Add public API for parallel compression method

2023-01-17 Thread Claudio Fontana
Hi, On 1/16/23 14:42, Jiang Jiacheng wrote: > Add public API VIR_MIGRATE_PARAM_PARALLEL_COMPRESSION, > VIR_MIGRATE_PARAM_PARALLEL_ZLIB_LEVEL, VIR_MIGRATE_PARAM_PARALLEL_ZSTD_LEVEL > for migration APIs to support set compression method > and compress level used during migration. > >

[PATCH V2 1/1] qemuProcessEventSubmit : rename vm to event->vm

2023-01-17 Thread Shaleen Bathla
In error case, free event->vm instead of vm. This makes it easier for the reader to understand what we should free. Signed-off-by: Shaleen Bathla --- src/qemu/qemu_process.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c

Re: [PATCH 1/1] qemuProcessEventSubmit : rename vm to event->vm

2023-01-17 Thread Peter Krempa
On Tue, Jan 17, 2023 at 11:51:07 +0530, Shaleen Bathla wrote: > Coverity scan reports use after free issue which is a false positive. > In error case, free event->vm instead of vm to avoid this warning in > coverity. This is an insufficient justification. We normally don't modify the code _only_

Re: [libvirt PATCH 0/3] cgroups cpu shares fixes

2023-01-17 Thread Martin Kletzander
On Tue, Jan 17, 2023 at 10:37:24AM +0100, Pavel Hrdina wrote: Pavel Hrdina (3): vircgroupv2: fix cpu.weight limits check domain_validate: drop cpu.shares cgroup check docs: document correct cpu shares limits with both cgroups v1 and v2 Reviewed-by: Martin Kletzander

Re: [External] : Re: [PATCH 1/1] qemuProcessEventSubmit : rename vm to event->vm

2023-01-17 Thread Shaleen Bathla
On Tue, Jan 17, 2023 at 10:09:41AM +0100, Peter Krempa wrote: > On Tue, Jan 17, 2023 at 11:51:07 +0530, Shaleen Bathla wrote: > > Coverity scan reports use after free issue which is a false positive. > > In error case, free event->vm instead of vm to avoid this warning in > > coverity. > > This

[libvirt PATCH 0/3] cgroups cpu shares fixes

2023-01-17 Thread Pavel Hrdina
Pavel Hrdina (3): vircgroupv2: fix cpu.weight limits check domain_validate: drop cpu.shares cgroup check docs: document correct cpu shares limits with both cgroups v1 and v2 docs/formatdomain.rst | 2 +- docs/manpages/virsh.rst| 3 ++- src/conf/domain_validate.c | 10 --

[libvirt PATCH 1/3] vircgroupv2: fix cpu.weight limits check

2023-01-17 Thread Pavel Hrdina
The cgroup v2 cpu.weight limits are different than cgroup v1 cpu.shares limits. Signed-off-by: Pavel Hrdina --- src/util/vircgroup.h | 2 ++ src/util/vircgroupv2.c | 8 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/util/vircgroup.h b/src/util/vircgroup.h index

[libvirt PATCH 3/3] docs: document correct cpu shares limits with both cgroups v1 and v2

2023-01-17 Thread Pavel Hrdina
The limits are different with cgroups v1 and v2 but our XML documentation and virsh manpage mentioned only cgroups v1 limits without explicitly saying it only applies to cgroups v1. Signed-off-by: Pavel Hrdina --- The "Since 0.9.0" applies to the whole paragraph when the attribute itself was

[libvirt PATCH 2/3] domain_validate: drop cpu.shares cgroup check

2023-01-17 Thread Pavel Hrdina
This check is done when VM is defined but doesn't take into account what cgroups version is currently used on the host system so it doesn't work correctly. To make proper check at this point we would have to figure out cgroups version while defining a VM but that will still not guarantee that the

Re: [libvirt PATCH 0/3] cgroups cpu shares fixes

2023-01-17 Thread Erik Skultety
On Tue, Jan 17, 2023 at 10:37:24AM +0100, Pavel Hrdina wrote: > Pavel Hrdina (3): > vircgroupv2: fix cpu.weight limits check > domain_validate: drop cpu.shares cgroup check > docs: document correct cpu shares limits with both cgroups v1 and v2 > > docs/formatdomain.rst | 2 +- >

wiki.libvirt.org | Obsolete snapshots

2023-01-17 Thread Ricky Tigg
Hello The new interfaces of the latest virt-manager made the snapshots presented here obsolete. Regards.

Re: Proposal: renaming 'master' branch to 'main'

2023-01-17 Thread Jim Fehlig
On 1/16/23 07:55, Daniel P. Berrangé wrote: I don't recall exactly when it first came up, but it has been a few years now since the idea of moving away from 'master' as the git default branch name became a topic in OSS communities. Far from the first mention:

Re: [PATCH V9 00/14] spec: Decompose the daemon subpackage

2023-01-17 Thread Daniel P . Berrangé
On Tue, Jan 17, 2023 at 11:50:10AM -0700, Jim Fehlig wrote: > All patches in this series contain a R-B from Andrea or Daniel. Andrea, can > this be pushed now or did you want a final blessing from Daniel? I have no further comments. With regards, Daniel -- |: https://berrange.com -o-

Re: [PATCH] qemu_namespace: Umount the original /dev before replacing it with tmpfs

2023-01-17 Thread Jim Fehlig
On 12/16/22 08:04, Michal Privoznik wrote: Our code relies on mount events propagating into the namespace we create for a domain. However, there's one caveat. In v8.8.0-rc1~8 I've tried to make us detect differences in mount tables between the namespace in which libvirtd runs and the domain

Re: [PATCH V9 00/14] spec: Decompose the daemon subpackage

2023-01-17 Thread Jim Fehlig
All patches in this series contain a R-B from Andrea or Daniel. Andrea, can this be pushed now or did you want a final blessing from Daniel? Regards, Jim On 1/13/23 12:21, Jim Fehlig wrote: This is V9 of https://listman.redhat.com/archives/libvir-list/2023-January/237006.html The end goal

Re: [PATCH] qemu_namespace: Umount the original /dev before replacing it with tmpfs

2023-01-17 Thread Michal Prívozník
On 1/18/23 01:58, Jim Fehlig wrote: > On 12/16/22 08:04, Michal Privoznik wrote: >> Our code relies on mount events propagating into the namespace we >> create for a domain. However, there's one caveat. In v8.8.0-rc1~8 >> I've tried to make us detect differences in mount tables between >> the

Re: Proposal: renaming 'master' branch to 'main'

2023-01-17 Thread Daniel P . Berrangé
On Tue, Jan 17, 2023 at 09:02:23AM +0100, Martin Kletzander wrote: > On Mon, Jan 16, 2023 at 02:55:10PM +, Daniel P. Berrangé wrote: > > I don't recall exactly when it first came up, but it has been a few years > > now since the idea of moving away from 'master' as the git default branch > >

Re: Proposal: renaming 'master' branch to 'main'

2023-01-17 Thread Andrea Bolognani
On Tue, Jan 17, 2023 at 09:02:23AM +0100, Martin Kletzander wrote: > On Mon, Jan 16, 2023 at 02:55:10PM +, Daniel P. Berrangé wrote: > > I'd suggest it is time to libvirt to get on this train and rename our > > default branch to 'main' in all repositories. > > > > There are essentially two

Re: Proposal: renaming 'master' branch to 'main'

2023-01-17 Thread Ján Tomko
On a Monday in 2023, Daniel P. Berrangé wrote: There are essentially two options * Rename 'master' to 'main' With this, anyone pulling from an existing checkout will get an error telling them that 'master' does not exist. It won't tell them about 'main', but at least it gives them a

Re: [PATCH 0/3] migration: add qemu multifd migration options

2023-01-17 Thread Jiang Jiacheng
On 2023/1/17 16:32, Claudio Fontana wrote: > Hi, > > On 1/16/23 14:42, Jiang Jiacheng wrote: >> Add qemu multifd migration options to set multifd-compression >> multifd-zlib-level and multifd-zstd-level. > > I think what you are adding here is a new parallel compression method and > parallel

Re: [PATCH 1/3] Add public API for parallel compression method

2023-01-17 Thread Jiang Jiacheng
On 2023/1/17 16:44, Claudio Fontana wrote: > Hi, > > On 1/16/23 14:42, Jiang Jiacheng wrote: >> Add public API VIR_MIGRATE_PARAM_PARALLEL_COMPRESSION, >> VIR_MIGRATE_PARAM_PARALLEL_ZLIB_LEVEL, VIR_MIGRATE_PARAM_PARALLEL_ZSTD_LEVEL >> for migration APIs to support set compression method >> and

[PATCH] qemu: Provide virDomainGetCPUStats() implementation for session connection

2023-01-17 Thread Michal Privoznik
We have virDomainGetCPUStats() API which offers querying statistics on host CPU usage by given guest. And it works in two modes: getting overall stats (@start_cpu == -1, @ncpus == 1) or getting per host CPU usage. For the QEMU driver it is implemented by looking into values stored in

Re: [PATCH] qemu: Provide virDomainGetCPUStats() implementation for session connection

2023-01-17 Thread Martin Kletzander
On Tue, Jan 17, 2023 at 01:44:44PM +0100, Michal Privoznik wrote: We have virDomainGetCPUStats() API which offers querying statistics on host CPU usage by given guest. And it works in two modes: getting overall stats (@start_cpu == -1, @ncpus == 1) or getting per host CPU usage. For the QEMU

Re: [PATCH 1/3] Add public API for parallel compression method

2023-01-17 Thread Jiri Denemark
On Tue, Jan 17, 2023 at 21:58:39 +0800, Jiang Jiacheng wrote: > > > On 2023/1/17 16:44, Claudio Fontana wrote: > > Hi, > > > > On 1/16/23 14:42, Jiang Jiacheng wrote: > >> Add public API VIR_MIGRATE_PARAM_PARALLEL_COMPRESSION, > >> VIR_MIGRATE_PARAM_PARALLEL_ZLIB_LEVEL, > >>

[PATCH 10/15] virNetLibsshAuthenticateKeyboardInteractive: Use virAuthAskCredential

2023-01-17 Thread Peter Krempa
Rework the code to use the new helper instead of open coding the auth callback interaction. Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 47 ++- 1 file changed, 7 insertions(+), 40 deletions(-) diff --git a/src/rpc/virnetlibsshsession.c

[PATCH] docs: Fix typo

2023-01-17 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- Pushed as trivial. docs/formatdomain.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index 8fc8aeb928..f76c7c3d81 100644 --- a/docs/formatdomain.rst +++ b/docs/formatdomain.rst @@ -2703,7

Re: [PATCH] qemu: Provide virDomainGetCPUStats() implementation for session connection

2023-01-17 Thread Michal Prívozník
On 1/17/23 15:15, Martin Kletzander wrote: > On Tue, Jan 17, 2023 at 01:44:44PM +0100, Michal Privoznik wrote: >> We have virDomainGetCPUStats() API which offers querying >> statistics on host CPU usage by given guest. And it works in two >> modes: getting overall stats (@start_cpu == -1, @ncpus

[PATCH 13/15] virNetLibsshCheckHostKey: Use virAuthAskCredential

2023-01-17 Thread Peter Krempa
Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 57 +-- 1 file changed, 7 insertions(+), 50 deletions(-) diff --git a/src/rpc/virnetlibsshsession.c b/src/rpc/virnetlibsshsession.c index 748c1ed569..ecee30e5df 100644 ---

[PATCH 15/15] virAuthGetPasswordPath: Use virAuthAskCredential for callback interaction

2023-01-17 Thread Peter Krempa
Replace the open-coded variant by the new helper. Signed-off-by: Peter Krempa --- src/util/virauth.c | 39 --- 1 file changed, 4 insertions(+), 35 deletions(-) diff --git a/src/util/virauth.c b/src/util/virauth.c index e33658d356..14c48f7e25 100644 ---

[PATCH 14/15] virNetLibsshAuthenticatePassword: Use virAuthAskPassword instead of virAuthGetPasswordPath

2023-01-17 Thread Peter Krempa
virAuthGetPasswordPath can return the same password over and over if it's configured in the config. We rather want to try that only the first time and then ask the user instead. Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 32 1 file changed,

[PATCH 12/15] util: virauth: Export virAuthGetCredential

2023-01-17 Thread Peter Krempa
Signed-off-by: Peter Krempa --- src/libvirt_private.syms | 1 + src/util/virauth.c | 2 +- src/util/virauth.h | 5 + 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index 5616c0d44c..59ae5c2720 100644 ---

[PATCH 08/15] virnetsshsession: Pass in username via virNetSSHSessionNew rather than auth functions

2023-01-17 Thread Peter Krempa
We only ever allow one username so there's no point passing it to each authentication registration function. Additionally the only caller (virNetClientNewLibSSH2) always passes a username so all the checks were pointless. Signed-off-by: Peter Krempa --- src/rpc/virnetsocket.c | 14 +++

[PATCH 11/15] virNetLibsshAuthenticatePrivkeyCb: Use virAuthAskCredential

2023-01-17 Thread Peter Krempa
Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 26 +++--- 1 file changed, 3 insertions(+), 23 deletions(-) diff --git a/src/rpc/virnetlibsshsession.c b/src/rpc/virnetlibsshsession.c index 942f8526c2..748c1ed569 100644 --- a/src/rpc/virnetlibsshsession.c +++

[PATCH 03/15] util: authconfig: Use automatic pointer clearing for virAuthConfig

2023-01-17 Thread Peter Krempa
Fix and clean up the error paths in virAuthConfigNew*. Signed-off-by: Peter Krempa --- src/util/virauthconfig.c | 28 1 file changed, 8 insertions(+), 20 deletions(-) diff --git a/src/util/virauthconfig.c b/src/util/virauthconfig.c index dabd7cd217..983ac47f6b

[PATCH 02/15] virNetLibsshAuthMethod: Drop 'password' field

2023-01-17 Thread Peter Krempa
The field was never populated so we can remove it and all the associated logic. Both for password authentication and fetching the password for the public key we still can use the authentication callbacks. Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 61

[PATCH 04/15] util: authconfig: Use conteporary and consistent header style

2023-01-17 Thread Peter Krempa
Signed-off-by: Peter Krempa --- src/util/virauthconfig.c | 24 ++-- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/src/util/virauthconfig.c b/src/util/virauthconfig.c index 983ac47f6b..0363a1bef9 100644 --- a/src/util/virauthconfig.c +++

[PATCH 00/15] Clean up credential asking code in SSH transport

2023-01-17 Thread Peter Krempa
Peter Krempa (15): virNetLibsshSessionAuthAddPrivKeyAuth: Drop 'password' argument virNetLibsshAuthMethod: Drop 'password' field util: authconfig: Use automatic pointer clearing for virAuthConfig util: authconfig: Use conteporary and consistent header style

[PATCH 05/15] virNetSSHSessionAuthAddPrivKeyAuth: Remove unused 'password' argument

2023-01-17 Thread Peter Krempa
The only caller doesn't pass the password. Remove the argument. Signed-off-by: Peter Krempa --- src/rpc/virnetsocket.c | 3 +-- src/rpc/virnetsshsession.c | 7 +-- src/rpc/virnetsshsession.h | 3 +-- 3 files changed, 3 insertions(+), 10 deletions(-) diff --git a/src/rpc/virnetsocket.c

[PATCH 07/15] virNetSSHAuthMethod: Remove unused 'password' field

2023-01-17 Thread Peter Krempa
None of the callers actually set it. Remove the field and corresponding logic. Signed-off-by: Peter Krempa --- src/rpc/virnetsshsession.c | 57 +++--- 1 file changed, 22 insertions(+), 35 deletions(-) diff --git a/src/rpc/virnetsshsession.c

[PATCH 01/15] virNetLibsshSessionAuthAddPrivKeyAuth: Drop 'password' argument

2023-01-17 Thread Peter Krempa
The only caller doesn't actually populate it. Remove it to simplify internals. Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 4 +--- src/rpc/virnetlibsshsession.h | 3 +-- src/rpc/virnetsocket.c| 4 +--- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git

[PATCH 09/15] util: auth: Introduce virAuthAskCredential

2023-01-17 Thread Peter Krempa
The helper uses the user-provided auth callbacks to ask the user. The helper encapsulates the steps we do to query the user in few places into a common helper which can be then used further. Signed-off-by: Peter Krempa --- src/libvirt_private.syms | 2 ++ src/util/virauth.c | 66

Re: [PATCH 03/15] util: authconfig: Use automatic pointer clearing for virAuthConfig

2023-01-17 Thread Jonathon Jongsma
On 1/17/23 10:20 AM, Peter Krempa wrote: Fix and clean up the error paths in virAuthConfigNew*. Signed-off-by: Peter Krempa --- src/util/virauthconfig.c | 28 1 file changed, 8 insertions(+), 20 deletions(-) diff --git a/src/util/virauthconfig.c

[PATCH 06/15] virNetSSHSessionAuthAddPrivKeyAuth: Refactor cleanup

2023-01-17 Thread Peter Krempa
With g_strdup not failing we can remove all of the 'error' section. Signed-off-by: Peter Krempa --- src/rpc/virnetsshsession.c | 18 +++--- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/src/rpc/virnetsshsession.c b/src/rpc/virnetsshsession.c index

Re: [PATCH 09/15] util: auth: Introduce virAuthAskCredential

2023-01-17 Thread Jonathon Jongsma
On 1/17/23 10:20 AM, Peter Krempa wrote: The helper uses the user-provided auth callbacks to ask the user. The helper encapsulates the steps we do to query the user in few places into a common helper which can be then used further. Signed-off-by: Peter Krempa --- src/libvirt_private.syms |

Re: [PATCH 10/15] virNetLibsshAuthenticateKeyboardInteractive: Use virAuthAskCredential

2023-01-17 Thread Jonathon Jongsma
I personally would've preferred to have this patch combined with the previous one so that it's easier to verify that the refactored code maintains the same functionality as the replaced code. But I understand that you're refactoring more cases in the upcoming commits, so I guess there's not

Re: [PATCH 06/15] virNetSSHSessionAuthAddPrivKeyAuth: Refactor cleanup

2023-01-17 Thread Jonathon Jongsma
On 1/17/23 10:20 AM, Peter Krempa wrote: With g_strdup not failing we can remove all of the 'error' section. Signed-off-by: Peter Krempa --- src/rpc/virnetsshsession.c | 18 +++--- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/src/rpc/virnetsshsession.c

Re: [PATCH 13/15] virNetLibsshCheckHostKey: Use virAuthAskCredential

2023-01-17 Thread Jonathon Jongsma
On 1/17/23 10:20 AM, Peter Krempa wrote: Signed-off-by: Peter Krempa --- src/rpc/virnetlibsshsession.c | 57 +-- 1 file changed, 7 insertions(+), 50 deletions(-) diff --git a/src/rpc/virnetlibsshsession.c b/src/rpc/virnetlibsshsession.c index

Re: [PATCH 00/15] Clean up credential asking code in SSH transport

2023-01-17 Thread Jonathon Jongsma
On 1/17/23 10:20 AM, Peter Krempa wrote: Peter Krempa (15): virNetLibsshSessionAuthAddPrivKeyAuth: Drop 'password' argument virNetLibsshAuthMethod: Drop 'password' field util: authconfig: Use automatic pointer clearing for virAuthConfig util: authconfig: Use conteporary and