Systemctl commands timeout when ran as root

Solution 1:

Finally I've found the problem.

I figured that process 1 (systemd) was started with --switched-root and --deserialize. And as I found in that link it seems that there are some internal parameters which try to reload some previously saved state.

I've done a kill -9 on process 1 an now the systemd appears without the switched-root and systemctl is working again with or without rebooting.

Solution 2:

Two alternative solutions to the problem:

1- rebooting with

systemctl --force --force reboot

or

2- without reboot, just moving session files

mv /run/systemd/system/session-*.scope /tmp/

Tags:

Linux

Systemd