Ubuntu 22.04 使用 Gnome SessionManager 关机/重启时出现超时问题

Ubuntu 22.04 使用 Gnome SessionManager 关机/重启时出现超时问题

有时当我关闭(或重新启动)系统时,需要 25 秒左右的时间才能真正执行某些操作。(例如,在菜单中选择关机->什么都没有发生(桌面仍然像正常模式一样显示)-> 约 25 秒后系统像正常一样关闭)。

我看了一下日志,问题似乎出在这里:

Nov 01 10:21:54 p-Desktop-R7 systemd[1]: Stopping Session 2 of User p...
Nov 01 10:21:54 p-Desktop-R7 systemd-logind[952]: System is rebooting.
Nov 01 10:21:54 p-Desktop-R7 systemd-logind[952]: Delay lock is active (UID 1000/patrick, PID 3553/gnome-session-b) but inhibitor timeout is reached.
Nov 01 10:21:47 p-Desktop-R7 NetworkManager[916]: <info>  [1698830507.3751] policy: set 'Kabelgebundene Verbindung 1' (enp3s0) as default for IPv6 routing and DNS
Nov 01 10:21:38 p-Desktop-R7 NetworkManager[916]: <info>  [1698830498.8817] policy: set 'Kabelgebundene Verbindung 1' (enp3s0) as default for IPv6 routing and DNS
Nov 01 10:21:30 p-Desktop-R7 NetworkManager[916]: <info>  [1698830490.8386] policy: set 'Kabelgebundene Verbindung 1' (enp3s0) as default for IPv6 routing and DNS
Nov 01 10:21:24 p-Desktop-R7 gnome-shell[3595]: endSessionDialog: No XDG_SESSION_ID, fetched from logind: 2
Nov 01 10:21:24 p-Desktop-R7 systemd[1]: unattended-upgrades.service: Deactivated successfully.
Nov 01 10:21:24 p-Desktop-R7 gnome-shell[3595]: Ignored exception from dbus method: Gio.IOErrorEnum: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dio_2derror_2dquark.Code19: Vorgang wurde abgebrochen
Nov 01 10:21:24 p-Desktop-R7 at-spi2-registr[3771]: Unable to register client with session manager
Nov 01 10:21:24 p-Desktop-R7 at-spi2-registr[3771]: Failed to register client: GDBus.Error:org.gnome.SessionManager.AlreadyRegistered: Unable to register client
Nov 01 10:21:24 p-Desktop-R7 gnome-session-binary[3553]: Entering running state
Nov 01 10:21:24 p-Desktop-R7 gnome-session-binary[3553]: WARNING: Failed to get delay inhibitor: GDBus.Error:org.freedesktop.login1.OperationInProgress: The operation inhibition has been requested for is already running
Nov 01 10:21:24 p-Desktop-R7 gnome-session[3553]: gnome-session-binary[3553]: WARNING: Failed to get delay inhibitor: GDBus.Error:org.freedesktop.login1.OperationInProgress: The operation inhibition has been requested for is already running
Nov 01 10:21:24 p-Desktop-R7 gnome-shell[3595]: endSessionDialog: No XDG_SESSION_ID, fetched from logind: 2
Nov 01 10:21:24 p-Desktop-R7 gnome-session-binary[3553]: WARNING: Client '/org/gnome/SessionManager/Client19' failed to reply before timeout
Nov 01 10:21:24 p-Desktop-R7 gnome-session[3553]: gnome-session-binary[3553]: WARNING: Client '/org/gnome/SessionManager/Client19' failed to reply before timeout

问题似乎出在 SessionManager Client19 上,它无法正常终止。

我该如何解决这个问题,或者至少减少超时时间以便更快地做出响应?我已经尝试编辑 system.conf 和 logind.conf,但没有成功。

系统:

System:
  Kernel: 6.2.0-36-generic x86_64 bits: 64 Desktop: GNOME 42.9
    Distro: Ubuntu 22.04.3 LTS (Jammy Jellyfish)
Machine:
  Type: Desktop Mobo: ASRock model: X570 Pro4 serial: <superuser required>
    UEFI: American Megatrends v: P5.50 date: 10/13/2023
CPU:
  Info: 8-core model: AMD Ryzen 7 5800X bits: 64 type: MT MCP cache:
    L2: 4 MiB
  Speed (MHz): avg: 2241 min/max: 2200/4850 cores: 1: 2200 2: 2200 3: 2200
    4: 2200 5: 2200 6: 2200 7: 2200 8: 2200 9: 2200 10: 2200 11: 2200 12: 2196
    13: 2200 14: 2274 15: 2800 16: 2200
Graphics:
  Device-1: AMD driver: amdgpu v: kernel
  Display: wayland server: X.Org v: 1.22.1.1 with: Xwayland v: 22.1.1
    compositor: gnome-shell driver: X: loaded: amdgpu,ati
    unloaded: fbdev,modesetting,radeon,vesa gpu: amdgpu resolution:
    1: 2560x1440~120Hz 2: 2560x1440~120Hz
  OpenGL: renderer: AMD Radeon RX 6650 XT (radeonsi navi23 LLVM 15.0.7 DRM
    3.49 6.2.0-36-generic)
    v: 4.6 Mesa 24.0~git2311010600.da7e6f~oibaf~j (git-da7e6f3 2023-11-01
    jammy-oibaf-ppa)

相关内容