无法通过盖盖操作暂停

无法通过盖盖操作暂停

我最近升级到了 ubuntu 22.10,升级之前一切都运行正常,但升级后,我的笔记本电脑在合上盖子时无法正常挂起

HandleLidSwitch=suspend
HandleLidSwitchExternalPower=suspend
HandleLidSwitchDocked=ignore
SuspendKeyIgnoreInhibited=yes
LidSwitchIgnoreInhibited=yes

我取消了上面的注释/etc/systemd/logind.conf,但仍然没有效果,我也安装了调整并使用它来在盖子关闭时暂停,但没有运气[之后卸载]。

的结果systemd-inhibit

WHO                          UID  USER  PID  COMM            WHAT                                                     WHY                                                       MODE 
ModemManager                 0    root  876  ModemManager    sleep                                                    ModemManager needs to reset devices                       delay
NetworkManager               0    root  872  NetworkManager  sleep                                                    NetworkManager needs to turn off networks                 delay
UPower                       0    root  1254 upowerd         sleep                                                    Pause device polling                                      delay
Unattended Upgrades Shutdown 0    root  977  unattended-upgr shutdown                                                 Stop ongoing upgrades or perform upgrades before shutdown delay
GNOME Shell                  1000 aryan 2949 gnome-shell     sleep                                                    GNOME needs to lock the screen                            delay
aryan                        1000 aryan 3158 gsd-media-keys  handle-power-key:handle-suspend-key:handle-hibernate-key GNOME handling keypresses                                 block
aryan                        1000 aryan 3158 gsd-media-keys  sleep                                                    GNOME handling keypresses                                 delay
aryan                        1000 aryan 3166 gsd-power       sleep                                                    GNOME needs to lock the screen                            delay

我已经尝试过其他各种方法,但都不起作用

  • 暂停本身可以很好地工作sudo systemctl suspend

/编辑/

输出ps aux | grep power

root         747  0.0  0.0 239440  7472 ?        Ssl  17:22   0:00 /usr/libexec/power-profiles-daemon
root        1018  0.0  0.0 236408  6948 ?        Ssl  17:22   0:00 /usr/libexec/upowerd
aryan       3870  0.0  0.2 525428 27484 ?        Ssl  17:23   0:00 /usr/libexec/gsd-power
aryan       6490  0.0  0.0   9056  2236 pts/1    S+   17:26   0:00 grep --color=auto power

/编辑2/

journalctl --unit=systemd-logind --follow盖上盖子的结果

Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: New seat seat0.
Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Watching system buttons on /dev/input/event2 (Power Button)
Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Watching system buttons on /dev/input/event0 (Power Button)
Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Watching system buttons on /dev/input/event1 (Lid Switch)
Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Watching system buttons on /dev/input/event3 (AT Translated Set 2 keyboard)
Oct 30 17:49:17 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd[1]: Started User Login Management.
Oct 30 17:49:18 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: New session c1 of user gdm.
Oct 30 17:49:28 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: New session 3 of user aryan.
Oct 30 17:49:38 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Session c1 logged out. Waiting for processes to exit.
Oct 30 17:49:38 aryan-VivoBook-ASUSLaptop-X571GT-F571GT systemd-logind[836]: Removed session c1.

相关内容