電源ボタンを押してもシャットダウンは実行されません。

電源ボタンを押してもシャットダウンは実行されません。

電源ボタンを押してもシャットダウンは実行されません。

Journalctlに「電源キーを押しました」というメッセージが表示されますが、それはすべてです。

$ sudo journalctl --unit systemd-logind --boot
-- Logs begin at Fri 2020-02-07 16:50:59 CET, end at Wed 2024-03-20 08:55:50 CET. --
mrt 20 08:54:05 STLinux systemd[1]: Starting Login Service...
mrt 20 08:54:07 STLinux systemd-logind[851]: Watching system buttons on /dev/input/event0 (pmic_onkey)
mrt 20 08:54:07 STLinux systemd-logind[851]: New seat seat0.
mrt 20 08:54:07 STLinux systemd[1]: Started Login Service.
mrt 20 08:54:19 STLinux systemd-logind[851]: New session c1 of user yocto.
mrt 20 08:54:50 STLinux systemd-logind[851]: Power key pressed.
mrt 20 08:54:52 STLinux systemd-logind[851]: Power key pressed.
mrt 20 08:54:53 STLinux systemd-logind[851]: Power key pressed.
mrt 20 08:54:54 STLinux systemd-logind[851]: Power key pressed.
mrt 20 08:54:54 STLinux systemd-logind[851]: Power key pressed.
mrt 20 08:54:54 STLinux systemd-logind[851]: Power key pressed.

システムのシャットダウンを妨げる要因は何ですか?

これは私のlogind.confです。

$ cat /etc/systemd/logind.conf 
#  This file is part of systemd.
#
#  systemd is free software; you can redistribute it and/or modify it
#  under the terms of the GNU Lesser General Public License as published by
#  the Free Software Foundation; either version 2.1 of the License, or
#  (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See logind.conf(5) for details.

[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=yes
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
#HandleSuspendKey=suspend
#HandleHibernateKey=hibernate
#HandleLidSwitch=suspend
#HandleLidSwitchExternalPower=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
#InhibitorsMax=8192
#SessionsMax=8192

コメントを削除しても#HandlePowerKey=poweroff何も変わりません。

systemd-inhibitは、シャットダウンを防ぐことが何もないことを示しています。

$ sudo systemd-inhibit --list
No inhibitors.

これはYocto OpenSTLinuxシステムです。

ベストアンサー1

おすすめ記事