[Pkg-libvirt-maintainers] Bug#903348: Bug#903348: libvirt-daemon-system: libvirt-guests.sh service can't connect on system shutdown when using polkit access driver

Guido Günther agx at sigxcpu.org
Tue Jul 17 09:00:38 BST 2018


Hi,
On Sun, Jul 08, 2018 at 06:59:33PM -0300, Fabricio wrote:
> Package: libvirt-daemon-system
> Version: 3.0.0-4+deb9u3
> Severity: normal
> 
> Dear Maintainer,
> 
> libvirt-guests service can't connect to qemu:///system on system shutdown when
> using polkit auth_driver.
> 
> Steps to reproduce:
> 
> 1 - Activate polkit access driver (access_drivers = [ "polkit" ]
> [/etc/libvirt/libvirtd.conf])
> 
> 2 - Do the apropriate configuration (.pkla files, as debian still uses 1.05)
> 
> 3 - Shutdown the system. Service libvirt-guests reports: "Unable to connect to
> libvirt currently. Retrying .."
> 
> Related libvirt log message:
> 
> 2018-07-08 20:44:28.092+0000: 867: info : virDBusCall:1548 : DBUS_METHOD_CALL:
> 'org.freedesktop.PolicyKit1.Authority.CheckAuthorization' on
> '/org/freedesktop/PolicyKit1/Authority' at 'org.freedesktop.PolicyKit1'
> 2018-07-08 20:44:28.092+0000: 867: info : virDBusCall:1558 : DBUS_METHOD_ERROR:
> 'org.freedesktop.PolicyKit1.Authority.CheckAuthorization' on
> '/org/freedesktop/PolicyKit1/Authority' at 'org.freedesktop.PolicyKit1' error
> org.freedesktop.systemd1.ShuttingDown: Refusing activation, D-Bus is shutting
> down.
> 2018-07-08 20:44:28.092+0000: 867: error : virDBusCall:1570 : error from
> service: CheckAuthorization: Refusing activation, D-Bus is shutting down.
> 
> 
> From the libvirt's log messages i have found that it seems polkitd services
> stops before libvirt-guests shutdown. So, adding the following line to the unit
> section in/lib/systemd/system/libvirt-guests.services solved the problem:
> 
> After=polkit.service

PolicyKit is a dbus activated service so I'd rather not add it to a
before/after relationship. Can you check if doing a

After=dbus.service

works as well?
Cheers,
 -- Guido



More information about the Pkg-libvirt-maintainers mailing list