New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
systemd:amd64 (252-2 -> 252.1-1) brakes suspend/resume #25356
Comments
@axet and @Wallaby111 Could you bisect between v252 and v252.1 ? I cannot find suspicious commits... |
@yuwata I do not see 252.1 tag, What am I missing? debian changelog saying it is here: |
You can find v252.1 tag at https://github.com/systemd/systemd-stable |
'make install' breaks keyboard and mouse on my system (no longer pressed, or moved, even alt+f1 no longer works). running 'apt reinstall systemd' makes it unbootable. I'm doing something wrong here. rebuilding systemd more dangerous then rebuilding kernel EDIT: after full system fresh install, I can confirm: suspend / resume no longer works with recent packages. |
I am commenting here because other bugs have been closed as duplicates. I was using suspend-then-hibernate on my desktop with 251.7 and this was working as expected. aka suspending to RAM, and then if not waken up, hibernating after HibernateDelaySec time. I am very disapointed about the behavior change that seems to use a % of battery to activate the hibernate action. As this would mean, this would not work anymore on a desktop? Or this a bug? explaining, why suspend-then-hibernate does not hibernate here, now with 252.1 ? |
@solsticedhiver That's already reported and discussed at #25269. And I am already working on the issue. See #25374. |
Seems debian bookworm linux-image-6.0.0-4-amd64 works fine. I got successfull suspend / resume cycles 10 times in a row. I'm not sure what was wrong. Maybe it was a kernel issue in my case |
This is strange as I had a similar problem on Debian Bookworm with 252-2 already (didn't test with 252.1-1). And it seems I am not the only one : https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1023483. I found |
Upgrading to the latest Arch kernel seems to have fixed the issue for me as well. Now on 6.0.9-arch1-1 and can both suspend/resume and suspend-then-hibernate/resume with no issues. It did have an issue getting out of betterlockscreen when its auto-lock on suspend service was enabled, but quickly disabling then enabling it fixed that right away. |
Thank you for the reports. So, let's drop the regression tag. @n-peugnet Could you also test with newer kernels? |
Hi, |
Ok. Bug not complete went out. Now after suspend / resume. My keyboard has 5-10 seconds delay before typing keys. Alt+Tab works fine. Alt+F1 works and console works fine. So weird. Also I got gnome-terminal error in journalctl:
|
@testudomarginata Your issue is not relevant, and is #25269. See also #25356 (comment). |
Bug get back! All keys get frozen again and I unable to move windows. To summarize: 1) random 2) kernel in-depended 3) keys can be delayed 4) keys can be ignored. hw-probe journalctl after resume 15:30: |
After reading through the comments on #25269 and seeing @yuwata say that HibernateDelaySeconds= is now hijacked as an interval for measuring discharge rate, I did a little testing. At least on my system, it seems that when going in to suspend-then-hibernate I don't have the resume issues until after that HibernateDelaySeconds= has passed. I tested this by making "HibernateDelaySeconds=30" in If someone else could test this to make sure it's not some issue with my specific setup, that'd be really helpful. Edit: It looks like @yuwata is already working on making some more clear, separate distinctions for HibernateDelaySeconds and the discharge rate measuring interval, so hopefully that will fix the issue, but I'm not sure. |
Unfortunately, I cannot confirm your observation, as far as the original bug report is concerned. |
So I tried with systemd
Here is a setup that almost always triggers it: Setup demo$ uname -a
Linux X260-NICOLAS 6.0.0-2-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.0.5-1 (2022-10-28) x86_64 GNU/Linux
$ systemd --version
systemd 252 (252.1-1)
+PAM +AUDIT +SELINUX +APPARMOR +IMA +SMACK +SECCOMP +GCRYPT -GNUTLS +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD +LIBCRYPTSETUP +LIBFDISK +PCRE2 -PWQUALITY -P11KIT +QRENCODE +TPM2 +BZIP2 +LZ4 +XZ +ZLIB +ZSTD -BPF_FRAMEWORK -XKBCOMMON +UTMP +SYSVINIT default-hierarchy=unified
$ systemctl cat slock@.service
# /etc/systemd/system/slock@.service
[Unit]
Description=Lock X session using slock for user %i
Before=sleep.target
[Service]
User=%i
Environment=DISPLAY=:0
ExecStartPre=/usr/bin/xset dpms force suspend
ExecStart=/usr/local/bin/slock
[Install]
WantedBy=sleep.target
$ cat /etc/systemd/sleep.conf.d/nicolas.conf
[Sleep]
HibernateDelaySec=10 Triggeringsystemctl suspend-then-hibernate Then wait for 10+ seconds and power on the computer. BehaviourThe behaviour varies a little between the different occurences. Usually the screen is left as if slock were not run, but it is completely unresponsive. I can usually only move the mouse and the keyboard does nothing. I can still change TTY using One time slock was visible when loging back in and I can kind of unlock it by typing my password but then gnome-terminal is completely frozen. I can still launch st via dmenu (didn't find other apps working). in this case I can still run Appendices
I will continue to use systemd |
Let me ask again: When you upgrade to 252.2, then shutdown and boot, does the issue still occur? Thx. |
Yes, it does. |
…ming tasks, without affecting the wakeup handler" This change is causing compatibility issues with userspace that cannot handle being frozen for a long period of time. Problems include IPC timeouts between processes in `session.slice` and `user.slice` (including communication over D-Bus or communicating through an X server in `system.slice` as observed in systemd#25356 (comment) and systemd#25356 (comment)), and other potential issues like evdev event queue overflow. Fixes: systemd#25356
Can you check if applying #25662 fixes the problem? (You can find out how to do so by consulting your distribution's packaging documentation) |
Did't help my system. Keys keep freezing. Since here no longer 252.1-1 available in debian repos you have to downgrade it manually. To do so compile 251.4 using following example:
|
Can you execute the following command from SSH when the keys are frozen, and provide the output here? find /sys/fs/cgroup -name cgroup.freeze -print0 | xargs -0 grep 1 Make sure to reboot the system after installing the patched packages first. |
@axet It turns out one of the patches broke cgroup thawing altogether. I just uploaded the fixed patchset. Can you retry applying, rebooting and testing that PR? |
It worked. But wait. It happened before. Lets wait for a week and see if it is stable during the night. BTW on my system HibernateDelaySec=16h. Never hits the delay. |
If you run any QEMU/KVM processes in the user context please re-patch your packages from the latest commits and reboot - there were some changes made specifically for it. |
It looks fine. Stand a night. Few additional suspend / resume. Looks like a fix! Thanks! Congratulations! Tricky one. |
Just built it on Debian bookworm. From the resulted packages I installed For now the issue didn't show up. I will keep you updated. I also tested |
Still no sign of the issue, seems like it fixed it for me too. |
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd#25356.
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of #25356.
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659) (cherry picked from commit ac380e4)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659) (cherry picked from commit ac380e4)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659) (cherry picked from commit ac380e4) (cherry picked from commit d901bfa)
We want thawing operations to still succeed even in the presence of an unfreezable unit type (e.g. mount) appearing under a slice after the slice was frozen. The appearance of such units should never cause the slice thawing operation to fail to prevent potential future repeats of systemd/systemd#25356. (cherry picked from commit b458659) (cherry picked from commit ac380e4) (cherry picked from commit d901bfa)
Sorry to zombie this issue. My AMD Ryzen 7 7700X based motherboard won't resume from suspend. I've been using bookworm, fresh install, not an upgrade, since January. This issue just cropped up since the last update. Additional note, suspend triggers the AMD RX 7900 XT GPU fans to jump to 100%. This is like the boot phase just before POST. The situation occurs when timed out or manually suspended. |
@IamNaN Can you run |
Thanks for looking. Sure thing. And another data point for you: this is a dual boot system. I have another drive I select from BIOS (no shared partitions or drives) with Windows 11, and that does recover from suspend. I don't think it's a hardware issue. |
@IamNaN The log file doesn't contain the necessary information for troubleshooting. Please provide details on whether you're using
|
systemd version the issue has been seen with
252.1-1
Used distribution
debian bookworm
Linux kernel version used
6.0.0-3-amd64
CPU architectures issue was seen on
x86_64
Component
systemd
Expected behaviour you didn't see
suspend resume to work
Unexpected behaviour you saw
after suspend resume I unable to move any windows. I had to switch to console (alt+f2) and press ctrl+alt+del to reboot
Steps to reproduce the problem
call 'systemctl suspend' or close notebook lid
Additional program output to the terminal or log subsystem illustrating the issue
Manually rolling back to 252-2 makes system to work again, windows moves.
EDIT: updated logs https://linux-hardware.org/?probe=b5eb364ac6
The text was updated successfully, but these errors were encountered: