Hibernation / resume not working

inxi -Faz:

λ sudo inxi -Faz
[sudo] password for user:         
System:
Kernel: 5.16.2-zen1-1-zen x86_64 bits: 64 compiler: gcc v: 11.1.0
parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
root=UUID=5fd785db-f9a7-4515-816e-f54b36574491 rw [email protected]
quiet
cryptdevice=UUID=eae2febe-4274-4d25-b2cd-d5d15920efb0:luks-eae2febe-4274-4d25-b2cd-d5d15920efb0
root=/dev/mapper/luks-eae2febe-4274-4d25-b2cd-d5d15920efb0 splash
rd.udev.log_priority=3 vt.global_cursor_default=0
systemd.unified_cgroup_hierarchy=1
resume=/dev/mapper/luks-e6d34873-11e4-4ff1-8938-ddf0538a9c07 loglevel=3
Console: pty pts/1 wm: kwin_x11 DM: SDDM Distro: Garuda Linux
base: Arch Linux
Machine:
Type: Laptop System: Dell product: XPS 13 9370 v: N/A serial: <filter>
Chassis: type: 10 serial: <filter>
Mobo: Dell model: 0XXY7V v: A00 serial: <filter> UEFI: Dell v: 1.16.0
date: 07/09/2021
Battery:
ID-1: BAT0 charge: 34.4 Wh (81.9%) condition: 42.0/52.0 Wh (80.7%)
volts: 7.8 min: 7.6 model: SMP DELL G8VCF6C type: Li-poly serial: <filter>
status: Discharging
CPU:
Info: model: Intel Core i5-8350U socket: BGA1356 (U3E1) note: check
bits: 64 type: MT MCP arch: Coffee Lake family: 6 model-id: 0x8E (142)
stepping: 0xA (10) microcode: 0xEA
Topology: cpus: 1x cores: 4 tpc: 2 threads: 8 smt: enabled cache:
L1: 256 KiB desc: d-4x32 KiB; i-4x32 KiB L2: 1024 KiB desc: 4x256 KiB
L3: 6 MiB desc: 1x6 MiB
Speed (MHz): avg: 792 high: 800 min/max: 400/3600 base/boost: 3600/1700
scaling: driver: intel_pstate governor: powersave volts: 1.1 V
ext-clock: 100 MHz cores: 1: 789 2: 766 3: 791 4: 800 5: 800 6: 800
7: 795 8: 799 bogomips: 30399
Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Vulnerabilities:
Type: itlb_multihit status: KVM: VMX disabled
Type: l1tf
mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable
Type: mds mitigation: Clear CPU buffers; SMT vulnerable
Type: meltdown mitigation: PTI
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: Full generic retpoline, IBPB: conditional,
IBRS_FW, STIBP: conditional, RSB filling
Type: srbds mitigation: Microcode
Type: tsx_async_abort mitigation: TSX disabled
Graphics:
Device-1: Intel UHD Graphics 620 vendor: Dell driver: i915 v: kernel
bus-ID: 00:02.0 chip-ID: 8086:5917 class-ID: 0300
Device-2: Realtek Integrated_Webcam_HD type: USB driver: uvcvideo
bus-ID: 1-5:2 chip-ID: 0bda:58f4 class-ID: 0e02 serial: <filter>
Display: server: X.Org 1.21.1.3 compositor: kwin_x11 driver:
loaded: intel unloaded: modesetting alternate: fbdev,vesa display-ID: :0
screens: 1
Screen-1: 0 s-res: 3840x2160 s-dpi: 96 s-size: 1016x571mm (40.0x22.5")
s-diag: 1165mm (45.9")
Monitor-1: eDP1 res: 3840x2160 hz: 60 dpi: 336
size: 290x170mm (11.4x6.7") diag: 336mm (13.2")
Message: Unable to show advanced data. Required tool glxinfo missing.
Audio:
Device-1: Intel Sunrise Point-LP HD Audio vendor: Dell
driver: snd_hda_intel v: kernel alternate: snd_soc_skl bus-ID: 00:1f.3
chip-ID: 8086:9d71 class-ID: 0403
Sound Server-1: ALSA v: k5.16.2-zen1-1-zen running: yes
Sound Server-2: JACK v: 1.9.20 running: no
Sound Server-3: PulseAudio v: 15.0 running: no
Sound Server-4: PipeWire v: 0.3.43 running: yes
Network:
Device-1: Intel Wireless 8265 / 8275 driver: iwlwifi v: kernel
bus-ID: 02:00.0 chip-ID: 8086:24fd class-ID: 0280
IF: wlp2s0 state: up mac: <filter>
Bluetooth:
Device-1: Intel Bluetooth wireless interface type: USB driver: btusb v: 0.8
bus-ID: 1-7:3 chip-ID: 8087:0a2b class-ID: e001
Report: bt-adapter ID: hci0 rfk-id: 1 state: up address: <filter>
Drives:
Local Storage: total: 931.51 GiB used: 572.47 GiB (61.5%)
ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Kingston model: SA2000M81000G
size: 931.51 GiB block-size: physical: 512 B logical: 512 B
speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter> rev: S5Z42105
temp: 28.9 C scheme: GPT
SMART: yes health: PASSED on: 90d 13h cycles: 285
read-units: 37,229,048 [19.0 TB] written-units: 47,022,845 [24.0 TB]
Partition:
ID-1: / raw-size: 914.35 GiB size: 914.35 GiB (100.00%)
used: 572.46 GiB (62.6%) fs: btrfs block-size: 4096 B dev: /dev/dm-0
maj-min: 254:0 mapped: luks-eae2febe-4274-4d25-b2cd-d5d15920efb0
ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
used: 720 KiB (0.2%) fs: vfat block-size: 512 B dev: /dev/nvme0n1p1
maj-min: 259:1
ID-3: /home raw-size: 914.35 GiB size: 914.35 GiB (100.00%)
used: 572.46 GiB (62.6%) fs: btrfs block-size: 4096 B dev: /dev/dm-0
maj-min: 254:0 mapped: luks-eae2febe-4274-4d25-b2cd-d5d15920efb0
ID-4: /var/log raw-size: 914.35 GiB size: 914.35 GiB (100.00%)
used: 572.46 GiB (62.6%) fs: btrfs block-size: 4096 B dev: /dev/dm-0
maj-min: 254:0 mapped: luks-eae2febe-4274-4d25-b2cd-d5d15920efb0
ID-5: /var/tmp raw-size: 914.35 GiB size: 914.35 GiB (100.00%)
used: 572.46 GiB (62.6%) fs: btrfs block-size: 4096 B dev: /dev/dm-0
maj-min: 254:0 mapped: luks-eae2febe-4274-4d25-b2cd-d5d15920efb0
Swap:
Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default)
ID-1: swap-1 type: zram size: 15.33 GiB used: 0 KiB (0.0%) priority: 100
dev: /dev/zram0
ID-2: swap-2 type: partition size: 16.86 GiB used: 0 KiB (0.0%)
priority: -2 dev: /dev/dm-1 maj-min: 254:1
mapped: luks-e6d34873-11e4-4ff1-8938-ddf0538a9c07
Sensors:
System Temperatures: cpu: 50.0 C pch: 45.0 C mobo: 33.0 C sodimm: SODIMM C
Fan Speeds (RPM): cpu: 0
Info:
Processes: 314 Uptime: 3m wakeups: 212 Memory: 15.33 GiB
used: 4.33 GiB (28.2%) Init: systemd v: 250 tool: systemctl Compilers:
gcc: 11.1.0 clang: 13.0.0 Packages: pacman: 1500 lib: 371
Shell: fish (sudo) v: 3.3.1 default: Bash v: 5.1.16 running-in: yakuake
inxi: 3.3.12

Can't get hibernate or resume to work. I've got a relatively new install with swap with hibernate selected at install. I checked arch wiki and garuda wiki, but couldn't find any help from there.

I have the following settings in KDE power management under "On Battery":

  • Dim screen after 2 min
  • Screen energy saving: switch off after 5 min
  • Suspend session: automatically lock screen after 10 min
    • While asleep, hibernate after a period of inactivity
  • When laptop lid closed, hibernate

But when I leave the system to idle, or close the lid, I cannot resume from hibernation. I don't know if this is a hibernation or resume problem.

Thanks.

Common issues with Linux. I am currently fighting a build on a machine that takes 34sec to wake up, whether it's Garuda or Manjaro, no difference. However if using Garuda from 210225 ISO (yes 11 months ago), it works fine! Then I upgrade to today's specs from that ISO and bam, 34sec wake up. No log data for the 1st 30sec, so I hope you get luckier than me...

I highly doubt your issue is Garuda-specific related, though. What I'd do is try out at least another Arch-based distro (cuz Debian doesn't act the same way) and see if I'm right.

  • What does journalctl -r say? Try to pinpoint the 10sec before and 10sec after you try to wake it up and I guess then hard power it down.
  • Does your computer suspend/hibernates completely or are the fans, lights still on with heat coming out of the box even long after the suspend/hibernation?
  • Secondly, what do you do to try to take it out of sleep? Do you press a key on the kbd, move the mouse, press the power button or something awkward like hammering on the box? (hey we never know :slight_smile: )
2 Likes

It could also be something super simple like your USB devices not allowed to wake up the computer.

grep . /sys/bus/usb/devices/*/product will give you a list of devices, one of those is the right one when you press a key or move the mouse. Take note of the numbers between DEVICES and POWER.

Then take those numbers and grep . /sys/bus/usb/devices/*/power/wakeup will tell you if it's disabled or not.

Let me know what you find.

1 Like

Thanks for the replies.

I closed the lid (causing the system to hibernate) and tried to wake it back up. Touchpad or keyboard didn't have any effect. I short-pressed power, which caused the computer to boot. I pasted journalctl -r output here.

Some things that may be interesting in that output:


...
tammi 23 18:09:43 MACHINE kernel: [mem 0x4f800000-0xdfffffff] available for PCI devices
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xff000000-0xffffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfee01000-0xfeffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfee00000-0xfee00fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfec01000-0xfedfffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfec00000-0xfec00fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfe011000-0xfebfffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xfe000000-0xfe010fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xf0000000-0xfdffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0xe0000000-0xefffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x4f800000-0xdfffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x48e00000-0x4f7fffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x40000000-0x47ffffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x3ff26000-0x3fffefff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x3e525000-0x3ff25fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x3de6d000-0x3e524fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x3de20000-0x3de6cfff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x3da60000-0x3de1ffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x38305000-0x38378fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x2c32a000-0x2c32afff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x2c329000-0x2c329fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x0009f000-0x000fffff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x00058000-0x00058fff]
tammi 23 18:09:43 MACHINE kernel: PM: hibernation: Registered nosave memory: [mem 0x00000000-0x00000fff]
...
tammi 23 18:09:43 MACHINE kernel: Command line: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen root=UUID=5fd785db-f9a7-4515-816e-f54b36574491 rw [email protected] quiet cryptdevice=UUID=eae2febe-4274-4d25-b2cd-d5d15920efb0:luks-eae2febe-4274-4d2>
tammi 23 18:09:43 MACHINE kernel: Linux version 5.16.2-zen1-1-zen ([email protected]) (gcc (GCC) 11.1.0, GNU ld (GNU Binutils) 2.36.1) #1 ZEN SMP PREEMPT Thu, 20 Jan 2022 16:18:31 +0000
-- Boot 7d04d4a8025747a08aa6d37c1b8a4605 --
tammi 23 18:07:55 MACHINE kscreenlocker_greet[7144]: qt.svg: <input>:303:258: Could not add child element to parent element because the types are incorrect.
tammi 23 18:07:55 MACHINE kscreenlocker_greet[7144]: file:///usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/components/UserList.qml:41:9: Unable to assign [undefined] to bool
tammi 23 18:07:55 MACHINE kscreenlocker_greet[7144]: file:///usr/share/plasma/look-and-feel/org.kde.breeze.desktop/contents/components/VirtualKeyboard.qml:8:1: module "QtQuick.VirtualKeyboard" is not installed
tammi 23 18:07:55 MACHINE kernel: PM: hibernation: hibernation entry
tammi 23 18:07:55 MACHINE systemd-sleep[7172]: Entering sleep state 'hibernate'...
tammi 23 18:07:55 MACHINE kernel: PM: Image not found (code -16)
tammi 23 18:07:55 MACHINE systemd[1]: Starting Hibernate...
tammi 23 18:07:55 MACHINE systemd[1]: Reached target Sleep.
...
tammi 23 18:07:54 MACHINE NetworkManager[790]: <info>  [1642954074.1494] device (wlp2s0): state change: activated -> deactivating (reason 'sleeping', sys-iface-state: 'managed')
tammi 23 18:07:54 MACHINE NetworkManager[790]: <info>  [1642954074.1489] manager: NetworkManager state is now ASLEEP
tammi 23 18:07:54 MACHINE NetworkManager[790]: <info>  [1642954074.1475] device (p2p-dev-wlp2s0): state change: disconnected -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
tammi 23 18:07:54 MACHINE ModemManager[853]: <info>  [sleep-monitor] system is about to suspend
tammi 23 18:07:54 MACHINE NetworkManager[790]: <info>  [1642954074.1472] manager: sleep: sleep requested (sleeping: no  enabled: yes)
tammi 23 18:07:54 MACHINE kded5[2001]: bluedevil: About to suspend
tammi 23 18:07:53 MACHINE systemd-logind[797]: Lid closed.

Regarding the usb devices, I get this:

[🧱] × grep . /sys/bus/usb/devices/*/product
/sys/bus/usb/devices/1-5/product:Integrated_Webcam_HD
/sys/bus/usb/devices/1-10/product:Goodix Fingerprint Device
/sys/bus/usb/devices/3-2/product:YubiKey OTP+FIDO+CCID
/sys/bus/usb/devices/usb1/product:xHCI Host Controller
/sys/bus/usb/devices/usb2/product:xHCI Host Controller
/sys/bus/usb/devices/usb3/product:xHCI Host Controller
/sys/bus/usb/devices/usb4/product:xHCI Host Controller

And they all seem to be disabled:

grep . /sys/bus/usb/devices/usb1/power/wakeup
disabled

λ grep . /sys/bus/usb/devices/usb2/power/wakeup
disabled

λ grep . /sys/bus/usb/devices/usb2/power/wakeup
disabled

λ grep . /sys/bus/usb/devices/usb4/power/wakeup
disabled

What have you done on the machine at or just before 18:09:43?

I skimmed through your output and it appears to be choking at ACPI.

Please check your BIOS settings to make sure that Hibernation is supported. You may have to change the "state."

Then try different kernels such as the linux or linux-lts.

My best early-morning, not-enough-coffee yet guess is a change in kernels will resolve this issue. At least, I hope so.
:smiley:

5 Likes

Just closed the lid and rebooted. The entire journalctl output is behind the link in my previous post.

Ok, as Cooter mentioned it's a good thing to try a different kernel or kernel version. And sometimes you have to try a lot of them. For exemple it may break before 5.5 but from 5.5 up to 5.12 it works and above 5.12 it's broken again. I am facing this situation on my suspend issue, I am trying to narrow down which kernel versions work and which don't.

So try a few versions, including whichever version LTS is. 5.15 I think.
I assume here you already know how to easily try different kernel versions, am I wrong?

2 Likes

Well, I thought I did :slight_smile:
I have LTS installed, but after trying to switch to it in the boot options, the system still boots to zen.

You must use Advanced in grub menu.

3 Likes

When you boot into Garuda's GRUB screen, use your keyboard's Down arrow to move your cursor to Advanced, as SGS suggests, hit Enter, move your cursor to the LTS kernel, then once again hit enter.

Do you want to futz around with this forever, or just perform one simple task or two, so we can then move on?

Your's was the first post I addressed early this morning, the last one for tonight, and the last on this topic.

2 Likes

Yeah, I thought the "boot options" would set the option that is used to boot.

But even with LTS, the hibernate isn't working. It's weird, this exact same laptop has hibernated with Garuda previously just fine, and I haven't messed around the BIOS in between.

I would really prefer not to futz around this forever, but I just don't know how to solve this. I suggest not answering if it causes undue stress. I understand that I am not entitled to anything here. I'm just using the support channel for the distro I like using.

I would recommend updating your bios. There has been a number of bios releases since the date of your bios listed as urgent and stating on the website "Dell Technologies highly recommends applying this important update as soon as possible. The update contains critical bug fixes and changes to improve functionality, reliability, and stability of your Dell system. It may also include security fixes and other feature enhancements."
https://www.dell.com/support/home/en-us/drivers/driversdetails?driverid=1wm16&oscode=biosa&productcode=xps-13-9370-laptop

3 Likes

This suggestion maybe went unnoticed.
I'd check it, also in relation to this:
https://wiki.archlinux.org/title/Dell_XPS_13_(9370)#Sleep

2 Likes

After reading that, I am even more certain a bios update is in order. Thanks for pointing that out, filo.

1 Like

Thank you very much for eliminating a possible kernel change solution. It is one of the early steps of troubleshooting.

Your BIOS date didn't concern me at first because it was 2021. But @Kayo may very well be correct, so please do so. Looking for a manufacturer's BIOS update is also one of the next logical steps, and one that is heartly advised. Heck, my BIOS had a Nov. 2021 update, but had another just about a week ago. Please check. And cross your fingers. :wink:

I wanted to draw your attention to my prior post because you had ignored changing kernels, advise that could have easily and quickly provided you a solution. I am glad you have done so, but unhappy that did not solve your problem. But please add that to your computer bag o' tricks, as it may help you in the future.
:smiley:

regards

3 Likes

Your bios date indicates relatively new hardware. As others have already commented, updating to the newest bios is very important in cases such as this.

With newer hardware the linux-mainline kernel is you're most likely bet for a fix. Also be sure to install and test the linux-firmware-git package (then reboot).

Trying different settings in your bios relating to sleep states is also a good idea. Unfortunately, Windows has their dirty fingers into people's bios again and it's messing with Linux's ability to suspend on some newer systems. Check carefully for a setting with Linux compatibility in your bios.

Failing a bios fix, you may find some kernel parameters that may help. Search the Archwiki for your computer model and the internet in general for any special parameters that may help with suspend issues.

Good luck, and if you can't find a fix for this you've likely got Microsoft to thank for it.

2 Likes

Hi,
and thanks for your patience.

I installed the new bios and other firmware with linux-firmware. I tried disabling something called C-state from the BIOS, and with different kernels (lts, zen, mainline). Still no luck.

This is the journalctl -r since the most recent boot: tammi 27 11:42:22 MACHINE audit[3294]: USER_START pid=3294 uid=1000 auid=1000 se - Pastebin.com

Hmm... just to be 100% sure, you did try the linux-firmware-git right? Just that something new is needed for this hardware. I'm not sure if the support for the hardware is quite there yet if you have indeed tried all the latest firmware packages, kernels (you even tried LTS, good on you), and even the C-state options in BIOS (I wish my other computer's motherboard with a first gen Ryzen CPU had that option.. lol). Edit: forgot to mention that C-states set to off make it take longer to get out of sleep-like states. Just something to note for others that might look at this thread via a search later on.

At this rate, given the frequency of urgent bios updates Dell is pumping out, there might be another bios update in the works that will fix this issue, or linux-firmware-git might even still have to play some catch-up too. I'll try to investigate on the linux firmware front to at least see if there is a work-in-progress fix in the pipeline. If I come up with nothing, the ball might be in Dell's court after all.

3 Likes

Seems I overlooked this before, the SSD firmware has issues. "The stock firmware version AADA4102 has severe problems when the ssd enters the lowest power state". Thing is, the only reliable way to update this is through Windows. There is a way to do it with Linux, but only "at your own risk" Dell XPS 13 (9370) - ArchWiki

3 Likes