Suspend-then-hibernate not working since upgrade (december-2022)

Good morning everyone:

I was using flawlessly suspend-then-hibernate in my system. But since December upgrades it stopped working.
At change to linux515-5-15-84 I also suffered the infamous sound problem, so I was more worried abut that question. But it seemed to start then. And then the solution was to change into linux60 or linux61 (both working fine for me, with the ibt=off booting parameter). But there were some problems with the suspend or hibernate options. Probably for the big tinkering during the sound problems. Reinstalling systemd package, to overwrite changes on modified files, solve that, and both are working nicely now again.
But the suspend-then-hibernate option (that I really like, I have to say) stopped working.
It doesn’t seem machine related, since I didn’t change anything on bios nor any other thing. And I have now the default options on systemd that worked on previous kernels. So, it seems to me like something has changed in kernel management of the sleep system, but I cannot find anywhere info about that.
The problem is just that process arrives properly to suspend state, but there is no waking up to change to hibernate on designated time (no matter if just default 120 min or changed into any other time frame in /etc/systemd/sleep.conf, no sleep.conf.d folder used).

It’s not a big problem, I can manage perfectly with working suspend and hibernate, as I have, but I was very comfortable option to have for laptop (for a shot time stands on suspend, fast boot, and the changes into hibernate, no battery draining, for longer time without use).

Any clue is welcome.

My inxi -Fxa

System:
  Host: nacho-Lenovo Kernel: 6.1.1-1-MANJARO arch: x86_64 bits: 64
    compiler: gcc v: 12.2.0 parameters: BOOT_IMAGE=/boot/vmlinuz-6.1-x86_64
    root=UUID=4d2d0e11-44f4-4f14-a6dc-d1f83f358998 rw quiet
    cryptdevice=UUID=95fc649b-53b3-4137-813b-69f906456198:luks-95fc649b-53b3-4137-813b-69f906456198
    root=/dev/mapper/luks-95fc649b-53b3-4137-813b-69f906456198 apparmor=1
    security=apparmor
    resume=/dev/mapper/luks-e4419e8b-5200-43f2-9f1f-8f886ee1616a
    udev.log_priority=3 ibt=off
  Desktop: Xfce v: 4.18.0 tk: Gtk v: 3.24.35 info: xfce4-panel, cairo-dock
    wm: xfwm v: 4.18.0 dm: LightDM v: 1.32.0 Distro: Manjaro Linux
    base: Arch Linux
Machine:
  Type: Laptop System: LENOVO product: 82K1 v: IdeaPad Gaming 3 15IHU6
    serial: MP27KY52 Chassis: type: 10 v: IdeaPad Gaming 3 15IHU6
    serial: MP27KY52
  Mobo: LENOVO model: LNVNB161216 v: No DPK serial: MP27KY52 UEFI: LENOVO
    v: H4CN23WW(V1.08) date: 02/11/2022
Battery:
  ID-1: BAT1 charge: 27.9 Wh (59.5%) condition: 46.9/45.0 Wh (104.1%)
    volts: 11.9 min: 11.5 model: SMP L20M3PC2 type: Li-ion serial: 1182
    status: not charging cycles: 6
CPU:
  Info: model: 11th Gen Intel Core i5-11320H socket: U3E1 bits: 64
    type: MT MCP arch: Tiger Lake gen: core 11 level: v4 note: check built: 2020
    process: Intel 10nm family: 6 model-id: 0x8C (140) stepping: 2
    microcode: 0x28
  Topology: cpus: 1x cores: 4 tpc: 2 threads: 8 smt: enabled cache:
    L1: 320 KiB desc: d-4x48 KiB; i-4x32 KiB L2: 5 MiB desc: 4x1.2 MiB L3: 8 MiB
    desc: 1x8 MiB
  Speed (MHz): avg: 2617 high: 3200 min/max: 400/4500 base/boost: 4300/4500
    scaling: driver: intel_pstate governor: powersave volts: 0.9 V
    ext-clock: 100 MHz cores: 1: 3200 2: 3200 3: 3200 4: 3200 5: 3200 6: 881
    7: 3200 8: 860 bogomips: 51008
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data status: Not affected
  Type: retbleed status: Not affected
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via
    prctl
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer
    sanitization
  Type: spectre_v2 mitigation: Enhanced IBRS, IBPB: conditional, RSB
    filling, PBRSB-eIBRS: SW sequence
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel TigerLake-LP GT2 [Iris Xe Graphics] vendor: Lenovo
    driver: i915 v: kernel arch: Gen-12.1 process: Intel 10nm built: 2020-21
    ports: active: eDP-1 empty: DP-1, DP-2, DP-3, HDMI-A-1
    bus-ID: 0000:00:02.0 chip-ID: 8086:9a49 class-ID: 0300
  Device-2: NVIDIA TU117M [GeForce GTX 1650 Mobile / Max-Q] vendor: Lenovo
    driver: nvidia v: 525.60.11 alternate: nouveau,nvidia_drm non-free: 525.xx+
    status: current (as of 2022-12) arch: Turing code: TUxxx
    process: TSMC 12nm FF built: 2018-22 bus-ID: 0000:01:00.0
    chip-ID: 10de:1f9d class-ID: 0302
  Device-3: Syntek Integrated Camera type: USB driver: uvcvideo
    bus-ID: 1-6:3 chip-ID: 174f:244c class-ID: 0e02 serial: 0001
  Display: x11 server: X.Org v: 21.1.6 compositor: xfwm v: 4.18.0 driver: X:
    loaded: modesetting,nvidia alternate: fbdev,nouveau,nv,vesa dri: iris
    gpu: i915 display-ID: :0.0 screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.00x11.22")
    s-diag: 582mm (22.93")
  Monitor-1: eDP-1 model: BOE Display 0x09d2 built: 2020 res: 1920x1080
    hz: 60 dpi: 142 gamma: 1.2 size: 344x194mm (13.54x7.64") diag: 395mm (15.5")
    ratio: 16:9 modes: 1920x1080
  API: OpenGL v: 4.6 Mesa 22.3.1 renderer: Mesa Intel Xe Graphics (TGL GT2)
    direct render: Yes
Audio:
  Device-1: Intel Tiger Lake-LP Smart Sound Audio vendor: Lenovo
    driver: sof-audio-pci-intel-tgl
    alternate: snd_hda_intel,snd_sof_pci_intel_tgl bus-ID: 0000:00:1f.3
    chip-ID: 8086:a0c8 class-ID: 0401
  Sound API: ALSA v: k6.1.1-1-MANJARO running: yes
  Sound Interface: sndio v: N/A running: no
  Sound Server-1: JACK v: 1.9.21 running: no
  Sound Server-2: PulseAudio v: 16.1 running: no
  Sound Server-3: PipeWire v: 0.3.63 running: yes
Network:
  Device-1: Intel Wi-Fi 6 AX201 driver: iwlwifi v: kernel bus-ID: 0000:00:14.3
    chip-ID: 8086:a0f0 class-ID: 0280
  IF: wlp0s20f3 state: up mac: fe:26:74:be:4d:04
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: Lenovo driver: r8169 v: kernel port: 3000 bus-ID: 0000:02:00.0
    chip-ID: 10ec:8168 class-ID: 0200
  IF: enp2s0 state: down mac: e4:a8:df:c7:bc:e3
Bluetooth:
  Device-1: Intel AX201 Bluetooth type: USB driver: btusb v: 0.8
    bus-ID: 1-10:5 chip-ID: 8087:0026 class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 5 state: up address: see --recommends
RAID:
  Hardware-1: Intel Volume Management Device NVMe RAID Controller driver: vmd
    v: 0.6 port: N/A bus-ID: 0000:00:0e.0 chip-ID: 8086:9a0b rev: class-ID: 0104
Drives:
  Local Storage: total: 1.38 TiB used: 545.94 GiB (38.8%)
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Intel model: SSDPEKNW512GZL
    size: 476.94 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
    lanes: 4 type: SSD serial: PHKA2134035A512A rev: C01C temp: 28.9 C
    scheme: GPT
  SMART: yes health: PASSED on: 32d 2h cycles: 189
    read-units: 2,565,544 [1.31 TB] written-units: 2,372,631 [1.21 TB]
  ID-2: /dev/sda maj-min: 8:0 type: USB vendor: SanDisk model: Extreme 55AE
    size: 931.48 GiB block-size: physical: 512 B logical: 512 B type: N/A
    serial: 323233353256343030393939 rev: 3001 scheme: GPT
  SMART Message: Unknown USB bridge. Flash drive/Unsupported enclosure?
Partition:
  ID-1: / raw-size: 459.68 GiB size: 451.4 GiB (98.20%)
    used: 109.39 GiB (24.2%) fs: ext4 block-size: 4096 B dev: /dev/dm-0
    maj-min: 254:0 mapped: luks-95fc649b-53b3-4137-813b-69f906456198
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 14.5 MiB (4.8%) fs: vfat block-size: 512 B dev: /dev/nvme0n1p1
    maj-min: 259:1
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: partition size: 16.95 GiB used: 270.8 MiB (1.6%)
    priority: -2 dev: /dev/dm-1 maj-min: 254:1
    mapped: luks-e4419e8b-5200-43f2-9f1f-8f886ee1616a
Sensors:
  System Temperatures: cpu: 37.0 C mobo: N/A
  Fan Speeds (RPM): N/A
Info:
  Processes: 305 Uptime: 2d 17h 28m wakeups: 55 Memory: 15.41 GiB
  used: 5.53 GiB (35.9%) Init: systemd v: 252 default: graphical
  tool: systemctl Compilers: gcc: 12.2.0 clang: 14.0.6 Packages: 1946
  pm: pacman pkgs: 1910 libs: 476 tools: octopi,pacaur,pamac,trizen,yay
  pm: flatpak pkgs: 36 Shell: Bash (sudo) v: 5.1.16 running-in: xfce4-terminal
  inxi: 3.3.24

you are on RAID, which is not good… switching from RAID to AHCI is advised - if you are dual booting with windows, dont switch, otherwise you will not be able to boot into windows

1 Like

Thanks! Not even conscious… Was the default install from Manjaro.
I’m not dual booting, so not problem on changing that.
I don’t know how to change, or if possible to do that without reinstall. I’ll have to in investigate that!

you change it in BIOS … reinstall should not be needed … but i saw others who had issues on raid, and switching to ahci didnt resolve them, but reinstalling manjaro while on ahci did helped…
so switch to ahci, and try suspend, to see if it helped… if not try with different kernel, the 5.15 for example

Hi @Nachordez :wave:!

I was/am facing some of your problems with my system. I “solved” the one you are referring to about suspend-then-hibernate but the other remains. So I will try to address everything in the most straightforward way possible while not hijacking this thread :sweat_smile:.


December update and system-then-hibernate issue

This issue turns out to be a systemd one.

TL;DR: You have to downgrade systemd and relative packages to v251.*

Identify the packages that have been updated

$ cat /var/log/pacman.log | grep '2022-12-24' | grep -i 'systemd'

...
[2022-12-24T16:59:40+0100] [ALPM] upgraded systemd-libs (251.8-1 -> 252.4-2)
[2022-12-24T16:59:40+0100] [ALPM] upgraded systemd (251.8-1 -> 252.4-2)
[2022-12-24T16:59:46+0100] [ALPM] upgraded lib32-systemd (251.8-1 -> 252.4-1)
[2022-12-24T16:59:51+0100] [ALPM] upgraded systemd-sysvcompat (251.8-1 -> 252.4-2)
...

Then downgrade these packages to the previous version:

sudo DOWNGRADE_FROM_ALA=1 downgrade \
  systemd systemd-libs \
  lib32-systemd systemd-sysvcompat 

Details:

v252, part of the 24th December update (for Manjaro Stable), has changed the behavior of the HibernateDelaySec option … It is quite a debate on systemd GitHub repo. A new option should be introduced in v253 to “handle” it properly.

Ref:

4 Likes

Thanks, that makes sense, I’ll try it!

@Nachordez, regarding the other issues you mention in your initial post, I have to admit that I have some trouble following and understanding everything :sweat_smile:

1

I was using flawlessly suspend-then-hibernate in my system. But since December upgrades it stopped working.

OK, that is what led me to the previous answer I posted (systemd v252 issue).

2

At change to linux515-5-15-84 I also suffered the infamous sound problem, so I was more worried about that question. But it seemed to start then. And then the solution was to change into linux60 or linux61 (both working fine for me, with the ibt=off booting parameter).

Which “infamous sound problem” are you referring to?

I am facing a sound problem for a week now (because I was not using my laptop with Linux for a while for professional reasons) but I was not yet able to identify precisely what the cause is or any workaround.

The sound works properly after boot and then, after some time or after resuming, no sound anymore. I am running the Linux kernel 5.15.85-1-MANJARO.

  • Do I have to upgrade to Linux kernel >= 6.x for the sound issue?
  • What does the ibt=off kernel parameter do in that regard?

3

But there were some problems with the suspend or hibernate options. Probably for the big tinkering during the sound problems. Reinstalling systemd package, to overwrite changes on modified files, solve that, and both are working nicely now again.

  • What kind of issue have you faced regarding suspend and hibernate?
  • Were they with the kernels 6.x?

I am asking because I face another issue with kernels > 5.15 where:

  • suspend works
  • hibernate works (state is written to disk)
  • suspend-then-hibernate works (the transition from suspend to hibernate)
  • BUT the laptop is not powered-off when hibernating …

Ref: Hibernate mode - power is not turned off - #4 by xakraz


Thanks in advance for your answers :pray:

PS: I hope I am not hijacking the initial topic (I am completely ok with simple answers that redirect me to other topics or RTFM links :smile: )

Don’t worry at all, and thanks!
I’ll answer you on some hours since now (I’m out of home right now). I’m glad if I can help!

2

The problem that is happening to people with some integrated intel sound cards (tiger-like, for example). Sound stops often, and a restart of sound server is needed continually. Seems to happen on 5.15.84 and 5.15.85.
Yup, that could be your case, and the only solution by now is to downgrade kernel 5.15, or better to change into 6.0 or 6.1. &.1 is the new default in Manjaro, so it’s a good option.
But: if you have a nvidia gpu, it will not boot properly unless you add ibt=off to the grub boot line.

See:

for example

3

My problems were caused for many tinkering on config files experimenting trying to solve the suspend and hibernate questions. Or was this the mixing from the previous systemd and the new defective one? Sometimes they were not working properly, but just reinstall of systemd repaired that (except the suspend-then-hibernate). The problems did happen with linux515, and linux 60 and linux61.
I didn’t have the problem with the laptop not powering-off. But sometimes suspend or hibernate did not complete, and returned to the login screen, perhaps is related.

Hope that helps!

I’m having the same issue for “Sleepstate to disk”. I guess that’s the translation for suspend-then-hibernate? :thinking:

And holy crap that Github Issue.

The dismissive behaviour of that bluca-guy got my blood boiling.

Still flabbergasting that code changes got merged into master without proper testing while the test itself is not that hard to do.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.