import libvirt-8.0.0-2.module+el8.6.0+14025+ca131e0a

This commit is contained in:
CentOS Sources 2022-02-07 18:04:28 +00:00 committed by Stepan Oksanichenko
parent 91c4ee2155
commit 26a6c1c6e0
16 changed files with 320 additions and 141 deletions

2
.gitignore vendored
View File

@ -1 +1 @@
SOURCES/libvirt-7.10.0.tar.xz
SOURCES/libvirt-8.0.0.tar.xz

View File

@ -1 +1 @@
fcaf7b763bf6e930d8b0a131b32752ebc2b8af9f SOURCES/libvirt-7.10.0.tar.xz
e440412e9b45d7e24f0ef492d8edf5cf2cbd3f4c SOURCES/libvirt-8.0.0.tar.xz

View File

@ -1,5 +1,5 @@
From 804b6b95f243d4f3dcf4bca3f08e835fc88bfdfd Mon Sep 17 00:00:00 2001
Message-Id: <804b6b95f243d4f3dcf4bca3f08e835fc88bfdfd@dist-git>
From f0d0a6a9701522eee013682eb0ef566ef7cdac61 Mon Sep 17 00:00:00 2001
Message-Id: <f0d0a6a9701522eee013682eb0ef566ef7cdac61@dist-git>
From: =?UTF-8?q?J=C3=A1n=20Tomko?= <jtomko@redhat.com>
Date: Mon, 22 Feb 2016 12:51:51 +0100
Subject: [PATCH] RHEL: Add rhel machine types to qemuDomainMachineNeedsFDC
@ -13,31 +13,35 @@ https://bugzilla.redhat.com/show_bug.cgi?id=1227880
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
---
src/qemu/qemu_domain.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
src/qemu/qemu_domain.c | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 1f45b30975..0f6b9f980a 100644
index a8401bac30..40fe9985e6 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -8696,10 +8696,16 @@ static bool
qemuDomainMachineNeedsFDC(const char *machine,
const virArch arch)
@@ -8767,8 +8767,19 @@ qemuDomainHasBuiltinIDE(const virDomainDef *def)
bool
qemuDomainNeedsFDC(const virDomainDef *def)
{
+ const char *p = STRSKIP(machine, "pc-q35-");
- /* all supported Q35 machines need explicit FDC */
- return qemuDomainIsQ35(def);
+ const char *p;
+
if (!ARCH_IS_X86(arch))
return false;
- if (!STRPREFIX(machine, "pc-q35-"))
+ if (!p)
+ /* all supported Q35 machines need explicit FDC except for old RHEL-7
+ * machine types */
+ if (!qemuDomainIsQ35(def))
+ return false;
+
+ if (STRPREFIX(p, "rhel7.0.0") ||
+ STRPREFIX(p, "rhel7.1.0"))
return false;
+ if ((p = STRSKIP(def->os.machine, "pc-q35-")) &&
+ (STRPREFIX(p, "rhel7.0.0") ||
+ STRPREFIX(p, "rhel7.1.0")))
+ return false;
+
+ return true;
}
return true;
--
2.34.1

View File

@ -1,5 +1,5 @@
From 10561682792d0ea540235636e80b0b3e85ce412a Mon Sep 17 00:00:00 2001
Message-Id: <10561682792d0ea540235636e80b0b3e85ce412a@dist-git>
From b2529d5ff3a18a2b0022da75431cea5bf037819e Mon Sep 17 00:00:00 2001
Message-Id: <b2529d5ff3a18a2b0022da75431cea5bf037819e@dist-git>
From: Peter Krempa <pkrempa@redhat.com>
Date: Wed, 28 Jul 2021 17:37:21 +0200
Subject: [PATCH] RHEL: Enable usage of x-blockdev-reopen
@ -29,20 +29,20 @@ Reviewed-by: Ján Tomko <jtomko@redhat.com>
---
src/qemu/qemu_block.c | 24 +++++++++++++++---------
src/qemu/qemu_block.h | 3 ++-
src/qemu/qemu_capabilities.c | 11 +++++++++++
src/qemu/qemu_capabilities.h | 1 +
src/qemu/qemu_capabilities.c | 13 +++++++++++++
src/qemu/qemu_capabilities.h | 3 +++
src/qemu/qemu_monitor.c | 5 +++--
src/qemu/qemu_monitor.h | 3 ++-
src/qemu/qemu_monitor_json.c | 12 +++++++++---
src/qemu/qemu_monitor_json.h | 3 ++-
tests/qemumonitorjsontest.c | 2 +-
9 files changed, 46 insertions(+), 18 deletions(-)
9 files changed, 50 insertions(+), 18 deletions(-)
diff --git a/src/qemu/qemu_block.c b/src/qemu/qemu_block.c
index 53a0b919f9..8871eb9fdc 100644
index e5ff653a60..aa566d0097 100644
--- a/src/qemu/qemu_block.c
+++ b/src/qemu/qemu_block.c
@@ -3322,7 +3322,8 @@ qemuBlockBitmapsHandleCommitFinish(virStorageSource *topsrc,
@@ -3331,7 +3331,8 @@ qemuBlockBitmapsHandleCommitFinish(virStorageSource *topsrc,
int
qemuBlockReopenFormatMon(qemuMonitor *mon,
@ -52,7 +52,7 @@ index 53a0b919f9..8871eb9fdc 100644
{
g_autoptr(virJSONValue) reopenprops = NULL;
g_autoptr(virJSONValue) srcprops = NULL;
@@ -3331,15 +3332,19 @@ qemuBlockReopenFormatMon(qemuMonitor *mon,
@@ -3340,15 +3341,19 @@ qemuBlockReopenFormatMon(qemuMonitor *mon,
if (!(srcprops = qemuBlockStorageSourceGetBlockdevProps(src, src->backingStore)))
return -1;
@ -79,7 +79,7 @@ index 53a0b919f9..8871eb9fdc 100644
return -1;
return 0;
@@ -3363,6 +3368,7 @@ qemuBlockReopenFormat(virDomainObj *vm,
@@ -3372,6 +3377,7 @@ qemuBlockReopenFormat(virDomainObj *vm,
{
qemuDomainObjPrivate *priv = vm->privateData;
virQEMUDriver *driver = priv->driver;
@ -87,20 +87,20 @@ index 53a0b919f9..8871eb9fdc 100644
int rc;
/* If we are lacking the object here, qemu might have opened an image with
@@ -3376,7 +3382,7 @@ qemuBlockReopenFormat(virDomainObj *vm,
@@ -3385,7 +3391,7 @@ qemuBlockReopenFormat(virDomainObj *vm,
if (qemuDomainObjEnterMonitorAsync(driver, vm, asyncJob) < 0)
return -1;
- rc = qemuBlockReopenFormatMon(priv->mon, src);
+ rc = qemuBlockReopenFormatMon(priv->mon, src, downstream);
if (qemuDomainObjExitMonitor(driver, vm) < 0 || rc < 0)
return -1;
qemuDomainObjExitMonitor(driver, vm);
if (rc < 0)
diff --git a/src/qemu/qemu_block.h b/src/qemu/qemu_block.h
index 54601a48a9..88fc9974c4 100644
index 184a549d5c..130cfcdefd 100644
--- a/src/qemu/qemu_block.h
+++ b/src/qemu/qemu_block.h
@@ -268,7 +268,8 @@ qemuBlockBitmapsHandleCommitFinish(virStorageSource *topsrc,
@@ -267,7 +267,8 @@ qemuBlockBitmapsHandleCommitFinish(virStorageSource *topsrc,
/* only for use in qemumonitorjsontest */
int
qemuBlockReopenFormatMon(qemuMonitor *mon,
@ -111,18 +111,20 @@ index 54601a48a9..88fc9974c4 100644
int
qemuBlockReopenReadWrite(virDomainObj *vm,
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 30a557706b..f6ea51d17e 100644
index 5f1eb5014c..8ae80ef8d7 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -651,6 +651,7 @@ VIR_ENUM_IMPL(virQEMUCaps,
"device.json", /* QEMU_CAPS_DEVICE_JSON */
"query-dirty-rate", /* QEMU_CAPS_QUERY_DIRTY_RATE */
@@ -654,6 +654,9 @@ VIR_ENUM_IMPL(virQEMUCaps,
"rbd-encryption", /* QEMU_CAPS_RBD_ENCRYPTION */
"sev-guest-kernel-hashes", /* QEMU_CAPS_SEV_GUEST_KERNEL_HASHES */
"sev-inject-launch-secret", /* QEMU_CAPS_SEV_INJECT_LAUNCH_SECRET */
+
+ /* 420 */
+ "blockdev-reopen.__com.redhat_rhel-av-8_2_0-api", /* QEMU_CAPS_BLOCKDEV_REOPEN_COM_REDHAT_AV_8_2_0_API */
);
@@ -1536,6 +1537,7 @@ static struct virQEMUCapsDevicePropsFlags virQEMUCapsDevicePropsVhostUserFS[] =
@@ -1540,6 +1543,7 @@ static struct virQEMUCapsDevicePropsFlags virQEMUCapsDevicePropsVhostUserFS[] =
/* see documentation for virQEMUQAPISchemaPathGet for the query format */
static struct virQEMUCapsStringFlags virQEMUCapsQMPSchemaQueries[] = {
{ "block-commit/arg-type/*top", QEMU_CAPS_ACTIVE_COMMIT },
@ -130,7 +132,7 @@ index 30a557706b..f6ea51d17e 100644
{ "blockdev-add/arg-type/options/+gluster/debug-level", QEMU_CAPS_GLUSTER_DEBUG_LEVEL},
{ "blockdev-add/arg-type/+gluster/debug", QEMU_CAPS_GLUSTER_DEBUG_LEVEL},
{ "blockdev-add/arg-type/+vxhs", QEMU_CAPS_VXHS},
@@ -5189,6 +5191,15 @@ virQEMUCapsInitProcessCaps(virQEMUCaps *qemuCaps)
@@ -5235,6 +5239,15 @@ virQEMUCapsInitProcessCaps(virQEMUCaps *qemuCaps)
qemuCaps->arch == VIR_ARCH_MIPS)
virQEMUCapsSet(qemuCaps, QEMU_CAPS_SCSI_NCR53C90);
@ -147,22 +149,24 @@ index 30a557706b..f6ea51d17e 100644
}
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
index 61bdbdb2ac..79c05d603c 100644
index e3a3ab4445..cde6c18b4c 100644
--- a/src/qemu/qemu_capabilities.h
+++ b/src/qemu/qemu_capabilities.h
@@ -631,6 +631,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
QEMU_CAPS_DEVICE_JSON, /* -device accepts JSON */
QEMU_CAPS_QUERY_DIRTY_RATE, /* accepts query-dirty-rate */
QEMU_CAPS_RBD_ENCRYPTION, /* Ceph RBD encryption support */
+ QEMU_CAPS_BLOCKDEV_REOPEN_COM_REDHAT_AV_8_2_0_API, /* downstream support for blockdev reopen in rhel-av-8.2.0 */
@@ -634,6 +634,9 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
QEMU_CAPS_SEV_GUEST_KERNEL_HASHES, /* sev-guest.kernel-hashes= */
QEMU_CAPS_SEV_INJECT_LAUNCH_SECRET, /* 'sev-inject-launch-secret' qmp command present */
+ /* 420 */
+ QEMU_CAPS_BLOCKDEV_REOPEN_COM_REDHAT_AV_8_2_0_API, /* downstream support for blockdev reopen in rhel-av-8.2.0 */
+
QEMU_CAPS_LAST /* this must always be the last item */
} virQEMUCapsFlags;
diff --git a/src/qemu/qemu_monitor.c b/src/qemu/qemu_monitor.c
index 26b59801b8..ad00e471d6 100644
index babf9e62fb..23638d3fe8 100644
--- a/src/qemu/qemu_monitor.c
+++ b/src/qemu/qemu_monitor.c
@@ -4291,14 +4291,15 @@ qemuMonitorBlockdevAdd(qemuMonitor *mon,
@@ -4247,14 +4247,15 @@ qemuMonitorBlockdevAdd(qemuMonitor *mon,
int
qemuMonitorBlockdevReopen(qemuMonitor *mon,
@ -181,10 +185,10 @@ index 26b59801b8..ad00e471d6 100644
diff --git a/src/qemu/qemu_monitor.h b/src/qemu/qemu_monitor.h
index 99ecebc648..acbc49cc69 100644
index 9b2e4e1421..d2037914be 100644
--- a/src/qemu/qemu_monitor.h
+++ b/src/qemu/qemu_monitor.h
@@ -1422,7 +1422,8 @@ int qemuMonitorBlockdevAdd(qemuMonitor *mon,
@@ -1426,7 +1426,8 @@ int qemuMonitorBlockdevAdd(qemuMonitor *mon,
virJSONValue **props);
int qemuMonitorBlockdevReopen(qemuMonitor *mon,
@ -195,10 +199,10 @@ index 99ecebc648..acbc49cc69 100644
int qemuMonitorBlockdevDel(qemuMonitor *mon,
const char *nodename);
diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c
index 56f0b22b2a..efaee0d28c 100644
index b0b513683b..34a46b9b41 100644
--- a/src/qemu/qemu_monitor_json.c
+++ b/src/qemu/qemu_monitor_json.c
@@ -8009,13 +8009,19 @@ qemuMonitorJSONBlockdevAdd(qemuMonitor *mon,
@@ -8051,13 +8051,19 @@ qemuMonitorJSONBlockdevAdd(qemuMonitor *mon,
int
qemuMonitorJSONBlockdevReopen(qemuMonitor *mon,
@ -222,24 +226,24 @@ index 56f0b22b2a..efaee0d28c 100644
if (qemuMonitorJSONCommand(mon, cmd, &reply) < 0)
return -1;
diff --git a/src/qemu/qemu_monitor_json.h b/src/qemu/qemu_monitor_json.h
index f7fb13f56c..61389d9dd8 100644
index 64d9ebdaa3..15ce03d7af 100644
--- a/src/qemu/qemu_monitor_json.h
+++ b/src/qemu/qemu_monitor_json.h
@@ -594,7 +594,8 @@ int qemuMonitorJSONBlockdevAdd(qemuMonitor *mon,
@@ -748,7 +748,8 @@ qemuMonitorJSONBlockdevAdd(qemuMonitor *mon,
int
qemuMonitorJSONBlockdevReopen(qemuMonitor *mon,
- virJSONValue **props)
+ virJSONValue **props,
+ bool downstream)
ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2);
int qemuMonitorJSONBlockdevReopen(qemuMonitor *mon,
- virJSONValue **props)
+ virJSONValue **props,
+ bool downstream)
ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2);
int qemuMonitorJSONBlockdevDel(qemuMonitor *mon,
int
diff --git a/tests/qemumonitorjsontest.c b/tests/qemumonitorjsontest.c
index bcf5caa9a4..b6cec5e362 100644
index 48e2a457ab..8624a547b5 100644
--- a/tests/qemumonitorjsontest.c
+++ b/tests/qemumonitorjsontest.c
@@ -2784,7 +2784,7 @@ testQemuMonitorJSONBlockdevReopen(const void *opaque)
@@ -2780,7 +2780,7 @@ testQemuMonitorJSONBlockdevReopen(const void *opaque)
if (qemuMonitorTestAddItem(test, "blockdev-reopen", "{\"return\":{}}") < 0)
return -1;

View File

@ -1,5 +1,5 @@
From 91233ed20b9682d68aceeeba269f3cd9b6a32f50 Mon Sep 17 00:00:00 2001
Message-Id: <91233ed20b9682d68aceeeba269f3cd9b6a32f50@dist-git>
From 29eb7b77805cf5fb756c964cdbe7fb7fb2c01f5f Mon Sep 17 00:00:00 2001
Message-Id: <29eb7b77805cf5fb756c964cdbe7fb7fb2c01f5f@dist-git>
From: =?UTF-8?q?J=C3=A1n=20Tomko?= <jtomko@redhat.com>
Date: Mon, 27 Aug 2018 13:09:38 +0200
Subject: [PATCH] RHEL: Fix virConnectGetMaxVcpus output
@ -26,10 +26,10 @@ Reviewed-by: Andrea Bolognani <abologna@redhat.com>
1 file changed, 5 insertions(+)
diff --git a/src/util/virhostcpu.c b/src/util/virhostcpu.c
index 67b6910626..d5d7d5eae0 100644
index a07c00a0e9..35f41daef2 100644
--- a/src/util/virhostcpu.c
+++ b/src/util/virhostcpu.c
@@ -1189,6 +1189,11 @@ virHostCPUGetKVMMaxVCPUs(void)
@@ -1166,6 +1166,11 @@ virHostCPUGetKVMMaxVCPUs(void)
return -1;
}

View File

@ -1,5 +1,5 @@
From 1519bcc302d20d30b5115d53aa4c1735c72d7db0 Mon Sep 17 00:00:00 2001
Message-Id: <1519bcc302d20d30b5115d53aa4c1735c72d7db0@dist-git>
From 1d93a3944a200b7c955800faa598e0e11da098f8 Mon Sep 17 00:00:00 2001
Message-Id: <1d93a3944a200b7c955800faa598e0e11da098f8@dist-git>
From: Jiri Denemark <jdenemar@redhat.com>
Date: Fri, 27 Mar 2015 12:48:40 +0100
Subject: [PATCH] RHEL: Hack around changed Broadwell/Haswell CPUs
@ -30,10 +30,10 @@ Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
9 files changed, 30 insertions(+), 8 deletions(-)
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index c47998aabd..b5feaeb2c2 100644
index d822533ccb..6b4647a711 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -6614,6 +6614,8 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
@@ -6521,6 +6521,8 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
{
size_t i;
virCPUDef *cpu = def->cpu;
@ -42,7 +42,7 @@ index c47998aabd..b5feaeb2c2 100644
switch ((virCPUMode) cpu->mode) {
case VIR_CPU_MODE_HOST_PASSTHROUGH:
@@ -6680,6 +6682,12 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
@@ -6587,6 +6589,12 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
for (i = 0; i < cpu->nfeatures; i++) {
const char *featname =
virQEMUCapsCPUFeatureToQEMU(qemuCaps, cpu->features[i].name);
@ -55,7 +55,7 @@ index c47998aabd..b5feaeb2c2 100644
switch ((virCPUFeaturePolicy) cpu->features[i].policy) {
case VIR_CPU_FEATURE_FORCE:
case VIR_CPU_FEATURE_REQUIRE:
@@ -6697,6 +6705,20 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
@@ -6604,6 +6612,20 @@ qemuBuildCpuModelArgStr(virQEMUDriver *driver,
}
}
@ -116,7 +116,7 @@ index 09141106d5..ace08d5d76 100644
-overcommit mem-lock=off \
-smp 1,sockets=1,cores=1,threads=1 \
diff --git a/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args b/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args
index 866b7363b8..4f662703e6 100644
index 2dab572a6b..a9f7c4b910 100644
--- a/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/cpu-translation.x86_64-latest.args
@@ -12,7 +12,7 @@ XDG_CONFIG_HOME=/tmp/lib/domain--1-QEMUGuest1/.config \

View File

@ -1,5 +1,5 @@
From 654e03568f76bad59e73c3dde61edc1b508fab8b Mon Sep 17 00:00:00 2001
Message-Id: <654e03568f76bad59e73c3dde61edc1b508fab8b@dist-git>
From d6956a1aaa8757fab60132c3ee46c2bb199a78a8 Mon Sep 17 00:00:00 2001
Message-Id: <d6956a1aaa8757fab60132c3ee46c2bb199a78a8@dist-git>
From: John Ferlan <jferlan@redhat.com>
Date: Mon, 17 Dec 2018 20:42:30 -0500
Subject: [PATCH] RHEL: qemu: Add ability to set sgio values for hostdev
@ -22,10 +22,10 @@ Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
1 file changed, 16 insertions(+), 9 deletions(-)
diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index 7eb04e66a0..b4e4b0fe81 100644
index 6077457ff4..ba85fc6e22 100644
--- a/src/qemu/qemu_conf.c
+++ b/src/qemu/qemu_conf.c
@@ -1835,8 +1835,9 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
@@ -1841,8 +1841,9 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
virDomainDiskDef *disk = NULL;
virDomainHostdevDef *hostdev = NULL;
g_autofree char *sysfs_path = NULL;
@ -36,7 +36,7 @@ index 7eb04e66a0..b4e4b0fe81 100644
/* "sgio" is only valid for block disk; cdrom
* and floopy disk can have empty source.
@@ -1852,17 +1853,14 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
@@ -1858,17 +1859,14 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
} else if (dev->type == VIR_DOMAIN_DEVICE_HOSTDEV) {
hostdev = dev->data.hostdev;
@ -58,7 +58,7 @@ index 7eb04e66a0..b4e4b0fe81 100644
} else {
return 0;
}
@@ -1871,7 +1869,16 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
@@ -1877,7 +1875,16 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
return -1;
/* By default, filter the SG_IO commands, i.e. set unpriv_sgio to 0. */

View File

@ -1,5 +1,5 @@
From a5de71de8ed6b67511209f3652f74d5877018b00 Mon Sep 17 00:00:00 2001
Message-Id: <a5de71de8ed6b67511209f3652f74d5877018b00@dist-git>
From f562b4c83d342002291f6bd7c5776eaecbd3147f Mon Sep 17 00:00:00 2001
Message-Id: <f562b4c83d342002291f6bd7c5776eaecbd3147f@dist-git>
From: John Ferlan <jferlan@redhat.com>
Date: Mon, 17 Dec 2018 20:42:31 -0500
Subject: [PATCH] RHEL: qemu: Add check for unpriv sgio for SCSI generic host
@ -26,10 +26,10 @@ Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
1 file changed, 18 insertions(+), 2 deletions(-)
diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index b4e4b0fe81..846ec1c729 100644
index ba85fc6e22..28c334761b 100644
--- a/src/qemu/qemu_conf.c
+++ b/src/qemu/qemu_conf.c
@@ -1743,13 +1743,29 @@ qemuSharedHostdevAddRemoveInternal(virQEMUDriver *driver,
@@ -1749,13 +1749,29 @@ qemuSharedHostdevAddRemoveInternal(virQEMUDriver *driver,
{
g_autofree char *dev_path = NULL;
g_autofree char *key = NULL;

View File

@ -1,5 +1,5 @@
From b2bfe4e417e1a8a3703ef88320d38b555ef9d79f Mon Sep 17 00:00:00 2001
Message-Id: <b2bfe4e417e1a8a3703ef88320d38b555ef9d79f@dist-git>
From 9c5daeb8c99ca12a66387de448f585742887fd75 Mon Sep 17 00:00:00 2001
Message-Id: <9c5daeb8c99ca12a66387de448f585742887fd75@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Fri, 6 Mar 2020 15:52:21 +0100
Subject: [PATCH] RHEL: virscsi: Check device type before getting it's /dev

View File

@ -1,5 +1,5 @@
From 1029f562d8eb54e8866e671dfa8c731b5f656dbe Mon Sep 17 00:00:00 2001
Message-Id: <1029f562d8eb54e8866e671dfa8c731b5f656dbe@dist-git>
From 1ce4faffcd4616bbcea4d198c3f60cbcfddd784e Mon Sep 17 00:00:00 2001
Message-Id: <1ce4faffcd4616bbcea4d198c3f60cbcfddd784e@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Fri, 6 Mar 2020 15:52:23 +0100
Subject: [PATCH] RHEL: virscsi: Introduce and use
@ -30,10 +30,10 @@ Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
6 files changed, 50 insertions(+), 32 deletions(-)
diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms
index b98cb0f66d..98bf2352dd 100644
index 5b76e66e61..2c42e2a5e8 100644
--- a/src/libvirt_private.syms
+++ b/src/libvirt_private.syms
@@ -3201,6 +3201,7 @@ virSCSIDeviceGetSgName;
@@ -3191,6 +3191,7 @@ virSCSIDeviceGetSgName;
virSCSIDeviceGetShareable;
virSCSIDeviceGetTarget;
virSCSIDeviceGetUnit;
@ -42,10 +42,10 @@ index b98cb0f66d..98bf2352dd 100644
virSCSIDeviceListAdd;
virSCSIDeviceListCount;
diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index 846ec1c729..e0f1272153 100644
index 28c334761b..a0b8076d6b 100644
--- a/src/qemu/qemu_conf.c
+++ b/src/qemu/qemu_conf.c
@@ -1500,7 +1500,7 @@ qemuCheckUnprivSGIO(GHashTable *sharedDevices,
@@ -1506,7 +1506,7 @@ qemuCheckUnprivSGIO(GHashTable *sharedDevices,
if (!(virHashLookup(sharedDevices, key)))
return 0;
@ -54,7 +54,7 @@ index 846ec1c729..e0f1272153 100644
return -1;
/* Error message on failure needs to be handled in caller
@@ -1851,39 +1851,46 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
@@ -1857,39 +1857,46 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
virDomainDiskDef *disk = NULL;
virDomainHostdevDef *hostdev = NULL;
g_autofree char *sysfs_path = NULL;
@ -110,7 +110,7 @@ index 846ec1c729..e0f1272153 100644
/* By default, filter the SG_IO commands, i.e. set unpriv_sgio to 0. */
if (dev->type == VIR_DOMAIN_DEVICE_DISK) {
if (disk->sgio == VIR_DOMAIN_DEVICE_SGIO_UNFILTERED)
@@ -1903,11 +1910,11 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
@@ -1909,11 +1916,11 @@ qemuSetUnprivSGIO(virDomainDeviceDef *dev)
if (virFileExists(sysfs_path) || val == 1) {
int curr_val;

View File

@ -1,5 +1,5 @@
From 7ea0c04c8a96a420be459427f9d15768cfccce70 Mon Sep 17 00:00:00 2001
Message-Id: <7ea0c04c8a96a420be459427f9d15768cfccce70@dist-git>
From 5b96a8773d33af9822f6b6ccddc8f372841895a6 Mon Sep 17 00:00:00 2001
Message-Id: <5b96a8773d33af9822f6b6ccddc8f372841895a6@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Fri, 6 Mar 2020 15:52:22 +0100
Subject: [PATCH] RHEL: virscsi: Support TAPEs in virSCSIDeviceGetDevName()

View File

@ -1,5 +1,5 @@
From 00973f13a68ba4b7645ca66ecea8cdbecea29203 Mon Sep 17 00:00:00 2001
Message-Id: <00973f13a68ba4b7645ca66ecea8cdbecea29203@dist-git>
From ac8357ab7dd676af82b971673f8d7e862ff07624 Mon Sep 17 00:00:00 2001
Message-Id: <ac8357ab7dd676af82b971673f8d7e862ff07624@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Fri, 6 Mar 2020 15:52:24 +0100
Subject: [PATCH] RHEL: virutil: Accept non-block devices in virGetDeviceID()

View File

@ -0,0 +1,103 @@
From 732113455fb7eadeea178c71cc77f0ffdf639f24 Mon Sep 17 00:00:00 2001
Message-Id: <732113455fb7eadeea178c71cc77f0ffdf639f24@dist-git>
From: Michal Privoznik <mprivozn@redhat.com>
Date: Tue, 18 Jan 2022 12:40:09 +0100
Subject: [PATCH] Revert "report error when virProcessGetStatInfo() is unable
to parse data"
This reverts commit 938382b60ae5bd1f83b5cb09e1ce68b9a88f679a.
Turns out, the commit did more harm than good. It changed
semantics on some public APIs. For instance, while
qemuDomainGetInfo() previously did not returned an error it does
now. While the calls to virProcessGetStatInfo() is guarded with
virDomainObjIsActive() it doesn't necessarily mean that QEMU's
PID is still alive. QEMU might be gone but we just haven't
realized it (e.g. because the eof handler thread is waiting for a
job).
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=2041610
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
(cherry picked from commit 105dace22cc7b5b18d72a4dcad4a2cf386ce5c99)
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
---
src/ch/ch_driver.c | 2 ++
src/qemu/qemu_driver.c | 7 ++++++-
src/util/virprocess.c | 8 ++------
3 files changed, 10 insertions(+), 7 deletions(-)
diff --git a/src/ch/ch_driver.c b/src/ch/ch_driver.c
index 3cbc668489..53e0872207 100644
--- a/src/ch/ch_driver.c
+++ b/src/ch/ch_driver.c
@@ -1073,6 +1073,8 @@ chDomainHelperGetVcpus(virDomainObj *vm,
if (virProcessGetStatInfo(&vcpuinfo->cpuTime,
&vcpuinfo->cpu, NULL,
vm->pid, vcpupid) < 0) {
+ virReportSystemError(errno, "%s",
+ _("cannot get vCPU placement & pCPU time"));
return -1;
}
}
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index 65ac5ef367..d3d76c003f 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -1359,6 +1359,8 @@ qemuDomainHelperGetVcpus(virDomainObj *vm,
if (virProcessGetStatInfo(&vcpuinfo->cpuTime,
&vcpuinfo->cpu, NULL,
vm->pid, vcpupid) < 0) {
+ virReportSystemError(errno, "%s",
+ _("cannot get vCPU placement & pCPU time"));
return -1;
}
}
@@ -2519,6 +2521,8 @@ qemuDomainGetInfo(virDomainPtr dom,
if (virDomainObjIsActive(vm)) {
if (virProcessGetStatInfo(&(info->cpuTime), NULL, NULL,
vm->pid, 0) < 0) {
+ virReportError(VIR_ERR_OPERATION_FAILED, "%s",
+ _("cannot read cputime for domain"));
goto cleanup;
}
}
@@ -10526,7 +10530,8 @@ qemuDomainMemoryStatsInternal(virQEMUDriver *driver,
}
if (virProcessGetStatInfo(NULL, NULL, &rss, vm->pid, 0) < 0) {
- virResetLastError();
+ virReportError(VIR_ERR_OPERATION_FAILED, "%s",
+ _("cannot get RSS for domain"));
} else {
stats[ret].tag = VIR_DOMAIN_MEMORY_STAT_RSS;
stats[ret].val = rss;
diff --git a/src/util/virprocess.c b/src/util/virprocess.c
index 85d8c8e747..b559a4257e 100644
--- a/src/util/virprocess.c
+++ b/src/util/virprocess.c
@@ -1784,10 +1784,7 @@ virProcessGetStatInfo(unsigned long long *cpuTime,
virStrToLong_ullp(proc_stat[VIR_PROCESS_STAT_STIME], NULL, 10, &systime) < 0 ||
virStrToLong_l(proc_stat[VIR_PROCESS_STAT_RSS], NULL, 10, &rss) < 0 ||
virStrToLong_i(proc_stat[VIR_PROCESS_STAT_PROCESSOR], NULL, 10, &cpu) < 0) {
- virReportError(VIR_ERR_INTERNAL_ERROR,
- _("cannot parse process status data for pid '%d/%d'"),
- (int) pid, (int) tid);
- return -1;
+ VIR_WARN("cannot parse process status data");
}
/* We got jiffies
@@ -1884,8 +1881,7 @@ virProcessGetStatInfo(unsigned long long *cpuTime G_GNUC_UNUSED,
pid_t pid G_GNUC_UNUSED,
pid_t tid G_GNUC_UNUSED)
{
- virReportSystemError(ENOSYS, "%s",
- _("Process statistics data is not supported on this platform"));
+ errno = ENOSYS;
return -1;
}
--
2.35.0

View File

@ -0,0 +1,44 @@
From 94bc9eaf3bbcaec47bd233378bbbb45f5f1523ca Mon Sep 17 00:00:00 2001
Message-Id: <94bc9eaf3bbcaec47bd233378bbbb45f5f1523ca@dist-git>
From: =?UTF-8?q?J=C3=A1n=20Tomko?= <jtomko@redhat.com>
Date: Thu, 20 Jan 2022 14:53:33 +0100
Subject: [PATCH] qemu: fix inactive snapshot revert
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The commit splitting out the qemuSnapshotRevertInactive function
dropped the 'defined = true' line by accident and instead
returned -1, leaving the user with a cryptic error:
error: An error occurred, but the cause is unknown
https://bugzilla.redhat.com/show_bug.cgi?id=2039136
https://gitlab.com/libvirt/libvirt/-/issues/266
Fixes: 85e4a13c3f19078fb6af5ffb4a80022c142cbc7e
Signed-off-by: Ján Tomko <jtomko@redhat.com>
(cherry picked from commit 76deb656132bb8817ddae4b7f417930c4db824c9)
https://bugzilla.redhat.com/show_bug.cgi?id=2043584
Signed-off-by: Ján Tomko <jtomko@redhat.com>
---
src/qemu/qemu_snapshot.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c
index f92e00f9c0..ac7bab90f8 100644
--- a/src/qemu/qemu_snapshot.c
+++ b/src/qemu/qemu_snapshot.c
@@ -2193,7 +2193,7 @@ qemuSnapshotRevertInactive(virDomainObj *vm,
if (*inactiveConfig) {
virDomainObjAssignDef(vm, inactiveConfig, false, NULL);
- return -1;
+ defined = true;
}
if (flags & (VIR_DOMAIN_SNAPSHOT_REVERT_RUNNING |
--
2.35.0

View File

@ -177,12 +177,14 @@ tests/qemuxml2xmloutdata/intel-iommu-caching-mode.x86_64-latest.xml ../qemuxml2a
tests/qemuxml2xmloutdata/intel-iommu-device-iotlb.x86_64-latest.xml ../qemuxml2argvdata/intel-iommu-device-iotlb.xml
tests/qemuxml2xmloutdata/intel-iommu-eim.x86_64-latest.xml ../qemuxml2argvdata/intel-iommu-eim.xml
tests/qemuxml2xmloutdata/intel-iommu.x86_64-latest.xml ../qemuxml2argvdata/intel-iommu.xml
tests/qemuxml2xmloutdata/luks-disks.xml ../qemuxml2argvdata/luks-disks.xml
tests/qemuxml2xmloutdata/kvm-features-off.xml ../qemuxml2argvdata/kvm-features-off.xml
tests/qemuxml2xmloutdata/kvm-features.xml ../qemuxml2argvdata/kvm-features.xml
tests/qemuxml2xmloutdata/luks-disks.x86_64-latest.xml ../qemuxml2argvdata/luks-disks.xml
tests/qemuxml2xmloutdata/mach-virt-console-native.xml mach-virt-serial-compat.xml
tests/qemuxml2xmloutdata/mach-virt-serial+console-native.xml mach-virt-serial-compat.xml
tests/qemuxml2xmloutdata/mach-virt-serial-native.xml mach-virt-serial-compat.xml
tests/qemuxml2xmloutdata/memfd-memory-default-hugepage.xml ../qemuxml2argvdata/memfd-memory-default-hugepage.xml
tests/qemuxml2xmloutdata/memfd-memory-numa.xml ../qemuxml2argvdata/memfd-memory-numa.xml
tests/qemuxml2xmloutdata/memfd-memory-default-hugepage.x86_64-latest.xml ../qemuxml2argvdata/memfd-memory-default-hugepage.xml
tests/qemuxml2xmloutdata/memfd-memory-numa.x86_64-latest.xml ../qemuxml2argvdata/memfd-memory-numa.xml
tests/qemuxml2xmloutdata/memory-hotplug-nvdimm-access.xml ../qemuxml2argvdata/memory-hotplug-nvdimm-access.xml
tests/qemuxml2xmloutdata/memory-hotplug-nvdimm-align.xml ../qemuxml2argvdata/memory-hotplug-nvdimm-align.xml
tests/qemuxml2xmloutdata/memory-hotplug-nvdimm-label.xml ../qemuxml2argvdata/memory-hotplug-nvdimm-label.xml
@ -208,6 +210,13 @@ tests/qemuxml2xmloutdata/pseries-serial+console-native.xml pseries-serial-native
tests/qemuxml2xmloutdata/pseries-serial-compat.xml pseries-serial-native.xml
tests/qemuxml2xmloutdata/serial-tcp-tlsx509-chardev-notls.xml ../qemuxml2argvdata/serial-tcp-tlsx509-chardev-notls.xml
tests/qemuxml2xmloutdata/smbios-type-fwcfg.xml ../qemuxml2argvdata/smbios-type-fwcfg.xml
tests/qemuxml2xmloutdata/tpm-emulator-spapr.ppc64-latest.xml ../qemuxml2argvdata/tpm-emulator-spapr.xml
tests/qemuxml2xmloutdata/tpm-emulator-tpm2-enc.x86_64-latest.xml ../qemuxml2argvdata/tpm-emulator-tpm2-enc.xml
tests/qemuxml2xmloutdata/tpm-emulator-tpm2-pstate.x86_64-latest.xml ../qemuxml2argvdata/tpm-emulator-tpm2-pstate.xml
tests/qemuxml2xmloutdata/tpm-emulator-tpm2.x86_64-latest.xml ../qemuxml2argvdata/tpm-emulator-tpm2.xml
tests/qemuxml2xmloutdata/tpm-emulator.x86_64-latest.xml ../qemuxml2argvdata/tpm-emulator.xml
tests/qemuxml2xmloutdata/tpm-passthrough-crb.x86_64-latest.xml ../qemuxml2argvdata/tpm-passthrough-crb.xml
tests/qemuxml2xmloutdata/tpm-passthrough.x86_64-latest.xml ../qemuxml2argvdata/tpm-passthrough.xml
tests/qemuxml2xmloutdata/user-aliases.xml ../qemuxml2argvdata/user-aliases.xml
tests/qemuxml2xmloutdata/vcpu-placement-static.xml ../qemuxml2argvdata/vcpu-placement-static.xml
tests/qemuxml2xmloutdata/vhost-user-fs-fd-memory.x86_64-latest.xml ../qemuxml2argvdata/vhost-user-fs-fd-memory.xml
@ -215,10 +224,11 @@ tests/qemuxml2xmloutdata/vhost-user-fs-hugepages.x86_64-latest.xml ../qemuxml2ar
tests/qemuxml2xmloutdata/vhost-user-fs-sock.x86_64-latest.xml ../qemuxml2argvdata/vhost-user-fs-sock.xml
tests/qemuxml2xmloutdata/vhost-vsock-ccw-iommu.s390x-latest.xml ../qemuxml2argvdata/vhost-vsock-ccw-iommu.xml
tests/qemuxml2xmloutdata/vhost-vsock-ccw.xml ../qemuxml2argvdata/vhost-vsock-ccw.xml
tests/qemuxml2xmloutdata/vhost-vsock.xml ../qemuxml2argvdata/vhost-vsock.xml
tests/qemuxml2xmloutdata/vhost-vsock.x86_64-latest.xml ../qemuxml2argvdata/vhost-vsock.xml
tests/qemuxml2xmloutdata/video-qxl-resolution.xml ../qemuxml2argvdata/video-qxl-resolution.xml
tests/qemuxml2xmloutdata/video-virtio-vga-gpu-gl.x86_64-latest.xml ../qemuxml2argvdata/video-virtio-vga-gpu-gl.xml
tests/qemuxml2xmloutdata/virtio-options.x86_64-latest.xml ../qemuxml2argvdata/virtio-options.xml
tests/qemuxml2xmloutdata/x86_64-default-cpu-tcg-features.x86_64-latest.xml ../qemuxml2argvdata/x86_64-default-cpu-tcg-features.xml
tests/vircaps2xmldata/linux-basic-dies/system/cpu ../../../virhostcpudata/linux-with-die/cpu
tests/vircaps2xmldata/linux-basic-dies/system/node ../../../virhostcpudata/linux-with-die/node
tests/vircaps2xmldata/linux-basic/system/node/node0/cpu0 ../../cpu/cpu0

View File

@ -209,8 +209,8 @@
Summary: Library providing a simple virtualization API
Name: libvirt
Version: 7.10.0
Release: 1%{?dist}%{?extra_release}
Version: 8.0.0
Release: 2%{?dist}%{?extra_release}
License: LGPLv2+
URL: https://libvirt.org/
@ -230,6 +230,8 @@ Patch7: libvirt-RHEL-virscsi-Support-TAPEs-in-virSCSIDeviceGetDevName.patch
Patch8: libvirt-RHEL-virscsi-Introduce-and-use-virSCSIDeviceGetUnprivSGIOSysfsPath.patch
Patch9: libvirt-RHEL-virutil-Accept-non-block-devices-in-virGetDeviceID.patch
Patch10: libvirt-RHEL-Enable-usage-of-x-blockdev-reopen.patch
Patch11: libvirt-Revert-report-error-when-virProcessGetStatInfo-is-unable-to-parse-data.patch
Patch12: libvirt-qemu-fix-inactive-snapshot-revert.patch
Requires: libvirt-daemon = %{version}-%{release}
Requires: libvirt-daemon-config-network = %{version}-%{release}
@ -299,7 +301,6 @@ BuildRequires: libnl3-devel
BuildRequires: libselinux-devel
BuildRequires: dnsmasq >= 2.41
BuildRequires: iptables
BuildRequires: radvd
BuildRequires: ebtables
BuildRequires: module-init-tools
BuildRequires: cyrus-sasl-devel
@ -324,8 +325,6 @@ BuildRequires: libiscsi-devel
BuildRequires: parted-devel
# For Multipath support
BuildRequires: device-mapper-devel
# For XFS reflink clone support
BuildRequires: xfsprogs-devel
%if %{with_storage_rbd}
BuildRequires: librados-devel
BuildRequires: librbd-devel
@ -337,12 +336,6 @@ BuildRequires: glusterfs-devel >= 3.4.1
%if %{with_storage_sheepdog}
BuildRequires: sheepdog
%endif
%if %{with_storage_zfs}
# Support any conforming implementation of zfs. On stock Fedora
# this is zfs-fuse, but could be zfsonlinux upstream RPMs
BuildRequires: /sbin/zfs
BuildRequires: /sbin/zpool
%endif
%if %{with_numactl}
# For QEMU/LXC numa info
BuildRequires: numactl-devel
@ -419,8 +412,12 @@ Summary: Server side daemon and supporting files for libvirt library
# The client side, i.e. shared libs are in a subpackage
Requires: %{name}-libs = %{version}-%{release}
# (client invokes 'nc' against the UNIX socket on the server)
Requires: /usr/bin/nc
# netcat is needed on the server side so that clients that have
# libvirt < 6.9.0 can connect, but newer versions will prefer
# virt-ssh-helper. Making this a Recommends means that it gets
# installed by default, but can still be removed if compatibility
# with old clients is not required
Recommends: /usr/bin/nc
# for modprobe of pci devices
Requires: module-init-tools
@ -480,7 +477,6 @@ Summary: Network driver plugin for the libvirtd daemon
Requires: libvirt-daemon = %{version}-%{release}
Requires: libvirt-libs = %{version}-%{release}
Requires: dnsmasq >= 2.41
Requires: radvd
Requires: iptables
%description daemon-driver-network
@ -1312,14 +1308,18 @@ then \
fi \
%libvirt_daemon_finish_restart %1
# For daemons with only UNIX sockets
%define libvirt_daemon_systemd_post() %systemd_post %1.socket %1-ro.socket %1-admin.socket %1.service
%define libvirt_daemon_systemd_post_inet() %systemd_post %1.socket %1-ro.socket %1-admin.socket %1-tls.socket %1-tcp.socket %1.service
%define libvirt_daemon_systemd_preun() %systemd_preun %1.service %1-ro.socket %1-admin.socket %1.socket
# For daemons with UNIX and INET sockets
%define libvirt_daemon_systemd_post_inet() %systemd_post %1.socket %1-ro.socket %1-admin.socket %1-tls.socket %1-tcp.socket %1.service
%define libvirt_daemon_systemd_preun_inet() %systemd_preun %1.service %1-ro.socket %1-admin.socket %1-tls.socket %1-tcp.socket %1.socket
# For daemons with only UNIX sockets and no unprivileged read-only access
%define libvirt_daemon_systemd_post_priv() %systemd_post %1.socket %1-admin.socket %1.service
%define libvirt_daemon_systemd_preun_priv() %systemd_preun %1.service %1-admin.socket %1.socket
%pre daemon
# 'libvirt' group is just to allow password-less polkit access to
# libvirtd. The uid number is irrelevant, so we use dynamic allocation
@ -1329,8 +1329,8 @@ getent group libvirt >/dev/null || groupadd -r libvirt
exit 0
%post daemon
%libvirt_daemon_systemd_post virtlogd
%libvirt_daemon_systemd_post virtlockdd
%libvirt_daemon_systemd_post_priv virtlogd
%libvirt_daemon_systemd_post_priv virtlockd
%if %{with_modular_daemons}
%libvirt_daemon_systemd_post_inet virtproxyd
%else
@ -1346,8 +1346,8 @@ exit 0
%libvirt_daemon_systemd_preun_inet libvirtd
%libvirt_daemon_systemd_preun_inet virtproxyd
%libvirt_daemon_systemd_preun virtlogd
%libvirt_daemon_systemd_preun virtlockdd
%libvirt_daemon_systemd_preun_priv virtlogd
%libvirt_daemon_systemd_preun_priv virtlockd
%postun daemon
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
@ -1419,7 +1419,7 @@ fi
%endif
%libvirt_daemon_schedule_restart virtnetworkd
%preun
%preun daemon-driver-network
%libvirt_daemon_systemd_preun virtnetworkd
%postun daemon-driver-network
@ -1497,6 +1497,21 @@ fi
%if %{with_qemu}
%pre daemon-driver-qemu
# We want soft static allocation of well-known ids, as disk images
# are commonly shared across NFS mounts by id rather than name; see
# https://fedoraproject.org/wiki/Packaging:UsersAndGroups
getent group kvm >/dev/null || groupadd -f -g 36 -r kvm
getent group qemu >/dev/null || groupadd -f -g 107 -r qemu
if ! getent passwd qemu >/dev/null; then
if ! getent passwd 107 >/dev/null; then
useradd -r -u 107 -g qemu -G kvm -d / -s /sbin/nologin -c "qemu user" qemu
else
useradd -r -g qemu -G kvm -d / -s /sbin/nologin -c "qemu user" qemu
fi
fi
exit 0
%post daemon-driver-qemu
%if %{with_modular_daemons}
%libvirt_daemon_systemd_post virtqemud
@ -1618,23 +1633,6 @@ done
%libvirt_daemon_perform_restart libvirtd
%libvirt_daemon_perform_restart virtnwfilterd
%if %{with_qemu}
%pre daemon-driver-qemu
# We want soft static allocation of well-known ids, as disk images
# are commonly shared across NFS mounts by id rather than name; see
# https://fedoraproject.org/wiki/Packaging:UsersAndGroups
getent group kvm >/dev/null || groupadd -f -g 36 -r kvm
getent group qemu >/dev/null || groupadd -f -g 107 -r qemu
if ! getent passwd qemu >/dev/null; then
if ! getent passwd 107 >/dev/null; then
useradd -r -u 107 -g qemu -G kvm -d / -s /sbin/nologin -c "qemu user" qemu
else
useradd -r -g qemu -G kvm -d / -s /sbin/nologin -c "qemu user" qemu
fi
fi
exit 0
%endif
%if %{with_lxc}
%pre login-shell
getent group virtlogin >/dev/null || groupadd -r virtlogin
@ -1730,6 +1728,7 @@ exit 0
%{_mandir}/man1/virt-admin.1*
%{_mandir}/man1/virt-host-validate.1*
%{_mandir}/man8/virt-ssh-helper.8*
%{_mandir}/man8/libvirtd.8*
%{_mandir}/man8/virtlogd.8*
%{_mandir}/man8/virtlockd.8*
@ -1892,6 +1891,7 @@ exit 0
%files daemon-driver-qemu
%config(noreplace) %{_sysconfdir}/sysconfig/virtqemud
%config(noreplace) %{_sysconfdir}/libvirt/virtqemud.conf
%config(noreplace) %{_prefix}/lib/sysctl.d/60-qemu-postcopy-migration.conf
%{_datadir}/augeas/lenses/virtqemud.aug
%{_datadir}/augeas/lenses/tests/test_virtqemud.aug
%{_unitdir}/virtqemud.service
@ -2018,6 +2018,7 @@ exit 0
%files client
%{_mandir}/man1/virsh.1*
%{_mandir}/man1/virt-xml-validate.1*
%{_mandir}/man1/virt-pki-query-dn.1*
%{_mandir}/man1/virt-pki-validate.1*
%{_bindir}/virsh
%{_bindir}/virt-xml-validate
@ -2104,6 +2105,19 @@ exit 0
%changelog
* Wed Jan 26 2022 Jiri Denemark <jdenemar@redhat.com> - 8.0.0-2
- Revert "report error when virProcessGetStatInfo() is unable to parse data" (rhbz#2041610)
- qemu: fix inactive snapshot revert (rhbz#2043584)
* Fri Jan 14 2022 Jiri Denemark <jdenemar@redhat.com> - 8.0.0-1
- Rebased to libvirt-8.0.0 (rhbz#2012802)
* Thu Jan 13 2022 Jiri Denemark <jdenemar@redhat.com> - 8.0.0-0rc1.1
- Rebased to libvirt-8.0.0-rc1 (rhbz#2012802)
- The rebase also fixes the following bugs:
rhbz#1689202, rhbz#2014369, rhbz#2030119, rhbz#2029380, rhbz#2035237
rhbz#2035714, rhbz#2034180
* Wed Dec 1 2021 Jiri Denemark <jdenemar@redhat.com> - 7.10.0-1
- Rebased to libvirt-7.10.0 (rhbz#2012802)
- The rebase also fixes the following bugs: