|
|
4e77bf |
From 601fbd22bbf812cb0ef60b039fc8214dadbdffaa Mon Sep 17 00:00:00 2001
|
|
|
4e77bf |
Message-Id: <601fbd22bbf812cb0ef60b039fc8214dadbdffaa@dist-git>
|
|
|
4e77bf |
From: Martin Kletzander <mkletzan@redhat.com>
|
|
|
4e77bf |
Date: Tue, 1 May 2018 15:54:22 +0200
|
|
|
4e77bf |
Subject: [PATCH] logging: Don't inhibit shutdown in system daemon
|
|
|
4e77bf |
MIME-Version: 1.0
|
|
|
4e77bf |
Content-Type: text/plain; charset=UTF-8
|
|
|
4e77bf |
Content-Transfer-Encoding: 8bit
|
|
|
4e77bf |
|
|
|
4e77bf |
That is a job of libvirtd and virtlogd has a dependency on it, so that will
|
|
|
4e77bf |
prevent it properly. Doing it one extra time in virtlogd might also cause AVC
|
|
|
4e77bf |
denials because it is not allowed to call that dbus method.
|
|
|
4e77bf |
|
|
|
4e77bf |
Caused by commit df34363d58bb.
|
|
|
4e77bf |
|
|
|
4e77bf |
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1547250
|
|
|
4e77bf |
|
|
|
4e77bf |
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
|
|
|
4e77bf |
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
|
|
|
4e77bf |
(cherry picked from commit f94e5b215720c91c60219f1694783a603f0b619c)
|
|
|
4e77bf |
|
|
|
4e77bf |
https: //bugzilla.redhat.com/show_bug.cgi?id=1573268
|
|
|
4e77bf |
Reviewed-by: Erik Skultety <eskultet@redhat.com>
|
|
|
4e77bf |
---
|
|
|
4e77bf |
src/logging/log_daemon.c | 6 ++++++
|
|
|
4e77bf |
1 file changed, 6 insertions(+)
|
|
|
4e77bf |
|
|
|
4e77bf |
diff --git a/src/logging/log_daemon.c b/src/logging/log_daemon.c
|
|
|
4e77bf |
index 5a136c59d1..b00b37878a 100644
|
|
|
4e77bf |
--- a/src/logging/log_daemon.c
|
|
|
4e77bf |
+++ b/src/logging/log_daemon.c
|
|
|
4e77bf |
@@ -129,6 +129,12 @@ virLogDaemonInhibitor(bool inhibit, void *opaque)
|
|
|
4e77bf |
{
|
|
|
4e77bf |
virLogDaemonPtr dmn = opaque;
|
|
|
4e77bf |
|
|
|
4e77bf |
+ /* virtlogd uses inhibition only to stop session daemon being killed after
|
|
|
4e77bf |
+ * the specified timeout, for the system daemon this is taken care of by
|
|
|
4e77bf |
+ * libvirtd and the dependencies between the services. */
|
|
|
4e77bf |
+ if (virNetDaemonIsPrivileged(dmn->dmn))
|
|
|
4e77bf |
+ return;
|
|
|
4e77bf |
+
|
|
|
4e77bf |
if (inhibit)
|
|
|
4e77bf |
virNetDaemonAddShutdownInhibition(dmn->dmn);
|
|
|
4e77bf |
else
|
|
|
4e77bf |
--
|
|
|
4e77bf |
2.17.1
|
|
|
4e77bf |
|