1

I just use CentOS 7.2, and default systemd version (systemd 219) used by CentOS 7.2; I just find my physical host, systemctl command can not use. eg. if I execute systemctl restart syslog-ng it will be stuck.

And only reboot can solve this problem.

[root@localhost /root]
#time systemctl restart syslog-ng
Error getting authority: Error initializing authority: Error calling StartServiceByName for org.freedesktop.PolicyKit1: Timeout was reached (g-io-error-quark, 24)
Failed to restart syslog-ng.service: Connection timed out

real   0m25.031s
user   0m0.004s
sys    0m0.003s

So , I just find that polkit actived by dbus failed.

[root@localhost /root]
#time systemctl restart polkit
Error getting authority: Error initializing authority: Error calling StartServiceByName for org.freedesktop.PolicyKit1: GDBus.Error:org.freedesktop.DBus.Error.TimedOut: Activation of org.freedesktop.PolicyKit1 timed out (g-dbus-error-quark, 20)

Job for polkit.service failed because a timeout was exceeded. See "systemctl status polkit.service" and "journalctl -xe" for details.

real   1m33.771s
user   0m0.003s
sys    0m0.005s

busctl cann't see problems

[root@localhost /root]
#busctl
NAME                              PID PROCESS         USER             CONNECTION    UNIT                      SESSION    DESCRIPTION
:1.4                            74375 polkitd         polkitd          :1.4          polkit.service            -          -
:1.7                            75062 busctl          root             :1.7          sshd.service              -          -
net.reactivated.Fprint              - -               -                (activatable) -                         -
org.freedesktop.DBus                - -               -                -             -                         -          -
org.freedesktop.PolicyKit1      74375 polkitd         polkitd          :1.4          polkit.service            -          -
org.freedesktop.hostname1           - -               -                (activatable) -                         -
org.freedesktop.locale1             - -               -                (activatable) -                         -
org.freedesktop.login1              - -               -                (activatable) -                         -
org.freedesktop.machine1            - -               -                (activatable) -                         -
org.freedesktop.systemd1            - -               -                (activatable) -                         -
org.freedesktop.timedate1           - -               -                (activatable) -                         -

But, if I manually start polkit, everting gonna be OK, systemctl command can use.

[root@localhost /root]
#/usr/lib/polkit-1/polkitd

And, if I use busctl also can't active polkit. So I think there is bug in dbus?

#busctl call org.freedesktop.systemd1 /org/freedesktop/systemd1 org.freedesktop.systemd1.Manager StartUnit ss polkit.service replace

Anybody see this problem? I also checked /etc/passwd exists polkit user account.

  • What does the service template look like? – Raman Sailopal Oct 26 '17 at 14:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.