我有 XPS 15 的 2022 型号,并且安装了 Ubuntu 22.04(带有内核 5.19 来解决音频问题)。
我在挂起和休眠方面遇到了一些不同的问题(这是必需的,因为硬件仅支持 s2idle 并且它会非常快地耗尽电池电量 - 根据其他帖子,我已经从 RAID 更改为 ACHI)。
第一个问题:挂起似乎不会让系统进入远程低功耗状态 - 如果我让笔记本电脑在挂起状态下过夜,电池将会完全早上死机了 - 挂起时耗电量似乎和唤醒时一样多。我检查过,当我合上盖子时,它进入挂起状态(通过 dmesg 和 journalctl)。
第二个问题:我设置了暂停然后休眠来解决这个问题 - 它似乎试图进入休眠状态(从 journalctl),但是没有实际上处于休眠状态 - 早上笔记本电脑仍然很热,当我打开它时,键盘和屏幕背光立即亮起(尽管机器随后挂起)。
一些细节:系统有 32GB RAM 和 40GB 交换空间(几乎从未使用过)。磁盘使用 luks 加密,包括根分区和交换分区(在同一个 luks 中,我认为这可能会给我带来麻烦,但一步一步来)
uname -a
Linux laptop-xps 5.19.0-051900rc3-generic #202206192130 SMP PREEMPT_DYNAMIC Sun Jun 19 21:34:04 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
我在笔记本电脑上运行 docker(有时运行容器,有时不运行),除此之外,我没有运行任何特别有趣的东西
从进入挂起状态直到我重新启动(昨晚到今天早上)时 journalctl 的输出。
sudo journalctl --since "22-08-22 22:40:03"
Aug 22 22:40:03 zacknewsham-xps systemd-logind[1480]: Lid closed.
Aug 22 22:40:03 zacknewsham-xps acpid[1440]: received input layer event "button/lid LID close"
Aug 22 22:40:03 zacknewsham-xps gnome-shell[3157]: Initialized single buffered shadow fb for eDP-1
Aug 22 22:40:03 zacknewsham-xps acpid[1440]: rule from /etc/acpi/events/laptop-lid matched
Aug 22 22:40:03 zacknewsham-xps systemd-logind[1480]: Suspending, then hibernating...
Aug 22 22:40:03 zacknewsham-xps acpid[16600]: executing action "/etc/acpi/laptop-lid.sh button/lid LID close"
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.6679] manager: sleep: sleep requested (sleeping: no enabled: yes)
Aug 22 22:40:03 zacknewsham-xps acpid[1440]: action exited with status 0
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.6680] device (p2p-dev-wlp0s20f3): state change: disconnected -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
Aug 22 22:40:03 zacknewsham-xps acpid[1440]: 1 total rule matched
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.6682] manager: NetworkManager state is now ASLEEP
Aug 22 22:40:03 zacknewsham-xps acpid[1440]: completed input layer event "button/lid LID close"
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.6683] device (wlp0s20f3): state change: activated -> deactivating (reason 'sleeping', sys-iface-state: 'managed')
Aug 22 22:40:03 zacknewsham-xps ModemManager[1526]: <info> [sleep-monitor] system is about to suspend
Aug 22 22:40:03 zacknewsham-xps evolution[11286]: Network disconnected. Forced offline.
Aug 22 22:40:03 zacknewsham-xps dbus-daemon[1445]: [system] Activating via systemd: service name='org.freedesktop.nm_dispatcher' unit='dbus-org.freedesktop.nm-dispatcher.service' requested by ':1.13' (uid=0 pid=1447 comm="/usr/sbin/NetworkManager --no-daemon ")
Aug 22 22:40:03 zacknewsham-xps systemd[1]: Starting Network Manager Script Dispatcher Service...
Aug 22 22:40:03 zacknewsham-xps dbus-daemon[1445]: [system] Successfully activated service 'org.freedesktop.nm_dispatcher'
Aug 22 22:40:03 zacknewsham-xps systemd[1]: Started Network Manager Script Dispatcher Service.
Aug 22 22:40:03 zacknewsham-xps kernel: wlp0s20f3: deauthenticating from d4:5d:64:c5:ce:0c by local choice (Reason: 3=DEAUTH_LEAVING)
Aug 22 22:40:03 zacknewsham-xps update-notifier[5812]: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
Aug 22 22:40:03 zacknewsham-xps update-notifier[5812]: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
Aug 22 22:40:03 zacknewsham-xps wpa_supplicant[1484]: wlp0s20f3: CTRL-EVENT-DISCONNECTED bssid=d4:5d:64:c5:ce:0c reason=3 locally_generated=1
Aug 22 22:40:03 zacknewsham-xps wpa_supplicant[1484]: wlp0s20f3: CTRL-EVENT-DSCP-POLICY clear_all
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.8829] device (wlp0s20f3): supplicant interface state: completed -> disconnected
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.8830] device (wlp0s20f3): state change: deactivating -> disconnected (reason 'sleeping', sys-iface-state: 'managed')
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Withdrawing address record for fe80::9cd4:d625:f2ad:b306 on wlp0s20f3.
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Leaving mDNS multicast group on interface wlp0s20f3.IPv6 with address fe80::9cd4:d625:f2ad:b306.
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Interface wlp0s20f3.IPv6 no longer relevant for mDNS.
Aug 22 22:40:03 zacknewsham-xps gnome-shell[3157]: An active wireless connection, in infrastructure mode, involves no access point?
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.9222] dhcp4 (wlp0s20f3): canceled DHCP transaction
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.9223] dhcp4 (wlp0s20f3): activation: beginning transaction (timeout in 45 seconds)
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.9223] dhcp4 (wlp0s20f3): state changed no lease
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.9224] dhcp6 (wlp0s20f3): canceled DHCP transaction
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Withdrawing address record for 192.168.1.114 on wlp0s20f3.
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Leaving mDNS multicast group on interface wlp0s20f3.IPv4 with address 192.168.1.114.
Aug 22 22:40:03 zacknewsham-xps avahi-daemon[1443]: Interface wlp0s20f3.IPv4 no longer relevant for mDNS.
Aug 22 22:40:03 zacknewsham-xps systemd-resolved[1346]: wlp0s20f3: Bus client set default route setting: no
Aug 22 22:40:03 zacknewsham-xps systemd-resolved[1346]: wlp0s20f3: Bus client reset DNS server list.
Aug 22 22:40:03 zacknewsham-xps NetworkManager[1447]: <info> [1661222403.9738] device (wlp0s20f3): state change: disconnected -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: p2p-dev-wlp0s20: CTRL-EVENT-DSCP-POLICY clear_all
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: p2p-dev-wlp0s20: CTRL-EVENT-DSCP-POLICY clear_all
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: nl80211: deinit ifname=p2p-dev-wlp0s20 disabled_11b_rates=0
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: wlp0s20f3: CTRL-EVENT-DSCP-POLICY clear_all
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Reached target Sleep.
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: wlp0s20f3: CTRL-EVENT-DSCP-POLICY clear_all
Aug 22 22:40:04 zacknewsham-xps wpa_supplicant[1484]: nl80211: deinit ifname=wlp0s20f3 disabled_11b_rates=0
Aug 22 22:40:04 zacknewsham-xps kernel: ACPI: button: The lid device is not compliant to SW_LID.
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Starting Record successful boot for GRUB...
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Starting Suspend; Hibernate if not used for a period of time...
Aug 22 22:40:04 zacknewsham-xps systemd[1]: grub-common.service: Deactivated successfully.
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Finished Record successful boot for GRUB.
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Starting GRUB failed boot detection...
Aug 22 22:40:04 zacknewsham-xps systemd[1]: grub-initrd-fallback.service: Deactivated successfully.
Aug 22 22:40:04 zacknewsham-xps systemd[1]: Finished GRUB failed boot detection.
Aug 22 22:40:04 zacknewsham-xps systemd-sleep[16689]: Entering sleep state 'suspend'...
Aug 22 22:40:04 zacknewsham-xps kernel: PM: suspend entry (s2idle)
Aug 22 22:40:04 zacknewsham-xps kernel: Filesystems sync: 0.008 seconds
Aug 23 00:40:04 zacknewsham-xps kernel: Freezing user space processes ... (elapsed 0.347 seconds) done.
Aug 23 00:40:04 zacknewsham-xps kernel: OOM killer disabled.
Aug 23 00:40:04 zacknewsham-xps kernel: Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
Aug 23 00:40:04 zacknewsham-xps kernel: printk: Suspending console(s) (use no_console_suspend to debug)
Aug 23 00:40:04 zacknewsham-xps kernel: ACPI: EC: interrupt blocked
Aug 23 00:40:04 zacknewsham-xps kernel: ACPI: EC: interrupt unblocked
Aug 23 00:40:04 zacknewsham-xps kernel: nvme nvme0: Shutdown timeout set to 10 seconds
Aug 23 00:40:04 zacknewsham-xps kernel: nvme nvme0: 20/0/0 default/read/poll queues
Aug 23 00:40:04 zacknewsham-xps kernel: mei_hdcp 0000:00:16.0-b638ab7e-94e2-4ea2-a552-d1c54b627f04: bound 0000:00:02.0 (ops i915_hdcp_component_ops [i915])
Aug 23 00:40:04 zacknewsham-xps kernel: OOM killer enabled.
Aug 23 00:40:04 zacknewsham-xps systemd-resolved[1346]: Clock change detected. Flushing caches.
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: input device has been disconnected, fd 28
Aug 23 00:40:04 zacknewsham-xps bluetoothd[1912]: src/profile.c:ext_io_disconnected() Unable to get io data for Hands-Free Voice gateway: getpeername: Transport endpoint is not connected (107)
Aug 23 00:40:04 zacknewsham-xps kernel: Restarting tasks ... done.
Aug 23 00:40:04 zacknewsham-xps gnome-shell[3157]: Could not release device '/dev/input/event27' (13,91): GDBus.Error:org.freedesktop.login1.DeviceNotTaken: Device not taken
Aug 23 00:40:04 zacknewsham-xps kernel: thermal thermal_zone13: failed to read out thermal zone (-61)
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Started Run anacron jobs.
Aug 23 00:40:04 zacknewsham-xps anacron[16813]: Anacron 2.3 started on 2022-08-23
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Starting Daily dpkg database backup service...
Aug 23 00:40:04 zacknewsham-xps anacron[16813]: Will run job `cron.daily' in 5 min.
Aug 23 00:40:04 zacknewsham-xps anacron[16813]: Jobs will be executed sequentially
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: received netlink event " 9DBB5994-A997- 000000d0 00000000"
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: 0 total rules matched
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: completed netlink event " 9DBB5994-A997- 000000d0 00000000"
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Starting Rotate log files...
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: received netlink event " 9DBB5994-A997- 000000d0 00000000"
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: 0 total rules matched
Aug 23 00:40:04 zacknewsham-xps acpid[1440]: completed netlink event " 9DBB5994-A997- 000000d0 00000000"
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopping Make remote CUPS printers available locally...
Aug 23 00:40:04 zacknewsham-xps systemd-sleep[16689]: System returned from sleep state.
Aug 23 00:40:04 zacknewsham-xps bluetoothd[1912]: Controller resume with wake event 0x0
Aug 23 00:40:04 zacknewsham-xps kernel: PM: suspend exit
Aug 23 00:40:04 zacknewsham-xps systemd[1]: cups-browsed.service: Deactivated successfully.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopped Make remote CUPS printers available locally.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopping CUPS Scheduler...
Aug 23 00:40:04 zacknewsham-xps systemd[1]: cups.service: Deactivated successfully.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopped CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: cups.path: Deactivated successfully.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopped CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopping CUPS Scheduler...
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Started CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: cups.socket: Deactivated successfully.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Closed CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Stopping CUPS Scheduler...
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Listening on CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps kernel: PM: Image not found (code -16)
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Starting CUPS Scheduler...
Aug 23 00:40:04 zacknewsham-xps systemd[1]: dpkg-db-backup.service: Deactivated successfully.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Finished Daily dpkg database backup service.
Aug 23 00:40:04 zacknewsham-xps audit[17065]: AVC apparmor="DENIED" operation="capable" profile="/usr/sbin/cupsd" pid=17065 comm="cupsd" capability=12 capname="net_admin"
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Started CUPS Scheduler.
Aug 23 00:40:04 zacknewsham-xps systemd[1]: Started Make remote CUPS printers available locally.
Aug 23 00:40:04 zacknewsham-xps kernel: audit: type=1400 audit(1661229604.947:226): apparmor="DENIED" operation="capable" profile="/usr/sbin/cupsd" pid=17065 comm="cupsd" capability=12 capname="net_admin"
Aug 23 00:40:04 zacknewsham-xps audit[17073]: AVC apparmor="DENIED" operation="capable" profile="/usr/sbin/cups-browsed" pid=17073 comm="cups-browsed" capability=23 capname="sys_nice"
Aug 23 00:40:04 zacknewsham-xps kernel: audit: type=1400 audit(1661229604.959:227): apparmor="DENIED" operation="capable" profile="/usr/sbin/cups-browsed" pid=17073 comm="cups-browsed" capability=23 capname="sys_nice"
Aug 23 00:40:04 zacknewsham-xps systemd-sleep[16689]: Entering sleep state 'hibernate'...
-- Boot b6211a86252d4b2fbf33f363e22fe48b --
答案1
我在使用 s2idle 时也遇到了类似的问题。我的解决方案是设置
/sys/module/acpi/parameters/ec_no_wake
到
Y
答案2
这不是一个真正的答案,但我重新安装了 Ubuntu,并且全部我的问题从低音扬声器不工作的问题开始消失了。
现在暂停功能可以正常工作,每小时消耗大约 1% 的电量,休眠功能“可以正常工作” - 包括电池几乎没电时自动休眠(这是一个不错的惊喜)。
我现在已经重新安装了之前运行的所有程序(我以为可能是 docker 或指纹识别器导致了我的问题,但事实并非如此 - 一切都正常)
重新安装时我只做了两件不同的事情:
- 我选择了“安装更新”选项
- 我在安装过程中确保有足够大的交换分区用于休眠,而不是稍后添加。使用全盘加密时,这比听起来要难,因为安装程序不提供指定交换大小的选项,但是会弹出一个小模式询问您是否确定要进行更改,此时您可以打开 gparted 并将 1GB 交换分区的大小调整为您想要的大小