You are not logged in.

#1 2016-03-12 11:41:52

cer_nagas
Member
Registered: 2015-07-01
Posts: 25

Cannot systemctl reboot

I have 2 users:

  • cer on tty1

  • and cli on tty2

I logged out of cli in tty2 and go to tty1 to reboot, but cannot.
systemctl reboot:

User cli is logged in on tty2.
Please retry operation after closing inhibitors and logging out other users.
Alternatively, ignore inhibitors and users with 'systemctl reboot -i'.

who:

cer      tty1         2016-03-12 12:15

Please help me. I don't want to reboot -i.

Last edited by cer_nagas (2016-03-12 11:42:38)

Offline

#2 2016-03-12 14:43:26

berbae
Member
From: France
Registered: 2007-02-12
Posts: 1,304

Re: Cannot systemctl reboot

Did you try 'systemctl reboot -i' ?
If you didn't set any inhibitors, this should be without negative effect.

Instead of 'who' use 'loginctl list-sessions' or 'loginctl list-users'.

After you logged out as cli user, check if something is left behind with:

systemd-cgls

Offline

#3 2016-03-12 15:34:37

cer_nagas
Member
Registered: 2015-07-01
Posts: 25

Re: Cannot systemctl reboot

Hi berbae, thanks for replying. I used -i, it worked. But I don't want to force it to reboot if there're any other users.

loginctl list-sessions

   SESSION        UID USER             SEAT            
        c3       1002 cli              seat0           
        c1       1000 cer              seat0  

loginctl list-users

       UID USER            
      1000 cer             
      1002 cli

systemd-cgls

-.slice
├─init.scope
│ └─1 /sbin/init splash
├─system.slice
│ ├─dbus.service
│ │ └─284 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activat
│ ├─system-netctl\x2dauto.slice
│ │ └─netctl-auto@wlp3s0.service
│ │   ├─357 wpa_supplicant -q -B -P /run/wpa_supplicant_wlp3s0.pid -i wlp3s0 -D nl80211,wext -c/r
│ │   ├─359 wpa_actiond -p /run/wpa_supplicant -i wlp3s0 -P /run/network/wpa_actiond_wlp3s0.pid -
│ │   └─748 dhcpcd -4 -q -t 30 -K -L wlp3s0
│ ├─systemd-journald.service
│ │ └─177 /usr/lib/systemd/systemd-journald
│ ├─upower.service
│ │ └─933 /usr/lib/upower/upowerd
│ ├─systemd-timesyncd.service
│ │ └─277 /usr/lib/systemd/systemd-timesyncd
│ ├─systemd-logind.service
│ │ └─291 /usr/lib/systemd/systemd-logind
│ ├─system-getty.slice
│ │ └─getty@tty2.service
│ │   └─2216 /sbin/agetty --noclear tty2 linux
│ ├─sshd.service
│ │ └─360 /usr/bin/sshd -D
│ ├─systemd-udevd.service
│ │ └─195 /usr/lib/systemd/systemd-udevd
│ ├─polkit.service
│ │ └─689 /usr/lib/polkit-1/polkitd --no-debug
│ ├─smartd.service
│ │ └─297 /usr/bin/smartd -n
│ └─rtkit-daemon.service
│   └─685 /usr/lib/rtkit/rtkit-daemon
└─user.slice
  ├─user-1000.slice
  │ ├─user@1000.service
  │ │ ├─dbus.service
  │ │ │ ├─541 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-ac
  │ │ │ ├─600 /usr/lib/at-spi2-core/at-spi-bus-launcher
  │ │ │ ├─605 /usr/bin/dbus-daemon --config-file=/etc/at-spi2/accessibility.conf --nofork --print
  │ │ │ ├─615 /usr/lib/at-spi2-core/at-spi2-registryd --use-gnome-session
  │ │ │ └─647 /usr/lib/GConf/gconfd-2
  │ │ ├─pulseaudio.service
  │ │ │ └─681 /usr/bin/pulseaudio --daemonize=no
  │ │ └─init.scope
  │ │   ├─408 /usr/lib/systemd/systemd --user
  │ │   └─413 (sd-pam)         
  │ └─session-c1.scope
  │   ├─ 304 login -- cer     
  │   ├─ 503 /bin/sh /usr/bin/startx
  │   ├─ 531 xinit /home/cer/.xinitrc -- /etc/X11/xinit/xserverrc :0 vt1 -auth /tmp/serverauth.js
  │   ├─ 532 /usr/lib/xorg-server/Xorg -nolisten tcp :0 vt1 -auth /tmp/serverauth.jse9VVDV7U
  │   ├─ 534 i3
  │   ├─ 556 i3bar --bar_id=bar-0 --socket=/run/user/1000/i3/ipc-socket.534
  │   ├─ 558 urxvt
  │   ├─ 560 urxvt
  │   ├─ 562 firefox
  │   ├─ 563 i3status
  │   ├─ 566 bash
  │   ├─ 567 bash
  │   ├─ 574 ibus-daemon -drx
  │   ├─ 575 ibus-daemon -drx
  │   ├─ 579 /usr/lib/ibus/ibus-dconf
  │   ├─ 582 /usr/lib/ibus/ibus-dconf
  │   ├─ 584 /usr/lib/ibus/ibus-ui-gtk3
  │   ├─ 585 /usr/lib/ibus/ibus-ui-gtk3
  │   ├─ 589 /usr/lib/ibus/ibus-x11 --kill-daemon
  │   ├─ 590 /usr/lib/ibus/ibus-x11 --kill-daemon
  │   ├─ 632 /usr/lib/ibus/ibus-engine-simple
  │   ├─ 776 /usr/lib/ibus/ibus-engine-unikey --ibus
  │   ├─2940 systemd-cgls
  │   └─2941 systemd-cgls
  └─user-1002.slice
    ├─session-c4.scope
    │ ├─2201 ibus-daemon -drx
    │ └─2208 /usr/lib/ibus/ibus-dconf
    └─user@1002.service
      ├─dbus.service
      │ └─847 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-ac
      └─init.scope
        ├─822 /usr/lib/systemd/systemd --user
        └─827 (sd-pam) 

Last edited by cer_nagas (2016-03-12 15:36:05)

Offline

#4 2016-03-12 15:44:48

Scimmia
Fellow
Registered: 2012-09-01
Posts: 13,729

Re: Cannot systemctl reboot

Does /var/lib/systemd/linger/ exist? If so, anything in it?

Offline

#5 2016-03-12 16:49:13

cer_nagas
Member
Registered: 2015-07-01
Posts: 25

Re: Cannot systemctl reboot

No, there's nothing in /var/lib/systemd/linger/.

Offline

#6 2016-03-12 21:55:10

berbae
Member
From: France
Registered: 2007-02-12
Posts: 1,304

Re: Cannot systemctl reboot

You can see that

ibus-daemon -drx

is left behind with dependent processes in the session of the user 1002.

That's why the reboot is blocked, I think.

You could try with the line

KillUserProcesses=yes

in /etc/systemd/logind.conf

or find a way to kill the ibus-daemon process before logging out of cli session.

Offline

#7 2016-03-13 07:50:46

cer_nagas
Member
Registered: 2015-07-01
Posts: 25

Re: Cannot systemctl reboot

Thank you berbae! It's solved.

Now that you mention it, I see there're also 2 ibus-daemon in 'cer' user. That's because I started it both in .xinitrc and .bashrc. Now that I removed that line from .bashrc, it's clean as nothing happened. No need to KillUserProcesses (I think it's never a good idea to force kill processes when you cannot handle it, that's like Windows way smile) )

Offline

Board footer

Powered by FluxBB