Hibernation does not work after upgrading from kernel 5.4 to 5.10 or from 5.4 to 5.15

Dear community,

Since I have downloaded and installed the actual kernel 5.10 using sudo mhwd-kernel -i linux510, I cannot hibernate my computer. Instead of hibernating, it shuts down or, more precisely, when I want to turn it on, it turn on as if I had shut it down and I cannot find the different softwares and documents open as it was before the hibernation try. Since I have not removed my 5.4.222-1 kernel that I used before, I can select this kernel and I can see that the hibernation still works with it. Does anyone have an idea how to solve this?

Below some hopefully useful information:

journalctl --system --boot=0 --priority=3
nov. 21 01:12:00 Strauss kernel: Unrecognized hibernate image header format!
nov. 21 01:12:00 Strauss kernel: PM: Image mismatch: architecture specific data
nov. 21 01:12:00 Strauss kernel: PM: Failed to load hibernation image, recovering.
nov. 21 01:12:00 Strauss kernel: cgroup2: Unknown parameter 'memory_recursiveprot'
nov. 21 01:13:10 Strauss bluetoothd[812]: src/plugin.c:plugin_init() Failed to init vcp plugin
nov. 21 01:13:10 Strauss bluetoothd[812]: src/plugin.c:plugin_init() Failed to init mcp plugin
nov. 21 01:13:10 Strauss bluetoothd[812]: src/plugin.c:plugin_init() Failed to init bap plugin
nov. 21 01:13:10 Strauss bluetoothd[812]: src/adapter.c:reset_adv_monitors_complete() Failed to reset Adv Monitors: Unkn>
nov. 21 01:13:12 Strauss lightdm[1136]: pam_faillock(lightdm:auth): Unknown option: onerr
nov. 21 01:13:12 Strauss lightdm[1136]: pam_faillock(lightdm:auth): Unknown option: file
nov. 21 01:14:45 Strauss systemd[1]: Failed to start 'ClamAV Milter'.
nov. 21 01:25:14 Strauss lightdm[1136]: gkr-pam: unable to locate daemon control file
nov. 21 01:27:00 Strauss bluetoothd[812]: src/adapter.c:reset_adv_monitors_complete() Failed to reset Adv Monitors: Unkn>
nov. 21 01:27:01 Strauss lightdm[2783]: pam_faillock(lightdm:auth): Unknown option: onerr
nov. 21 01:27:01 Strauss lightdm[2783]: pam_faillock(lightdm:auth): Unknown option: file
nov. 21 01:27:04 Strauss lightdm[2783]: gkr-pam: unable to locate daemon control file
inxi -Fxz --no-host with 5.4
System:
  Kernel: 5.4.224-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.2.0
    Desktop: Xfce v: 4.16.1 Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Laptop System: Notebook product: N650DU v: N/A
    serial: <superuser required>
  Mobo: Notebook model: N650DU serial: <superuser required>
    UEFI: American Megatrends v: 5.12 date: 02/26/2018
Battery:
  ID-1: BAT0 charge: 40.8 Wh (100.0%) condition: 40.8/62.2 Wh (65.6%)
    volts: 12.7 min: 11.1 model: Notebook BAT status: full
CPU:
  Info: quad core model: Intel Core i5-7500T bits: 64 type: MCP
    arch: Kaby Lake rev: 9 cache: L1: 256 KiB L2: 1024 KiB L3: 6 MiB
  Speed (MHz): avg: 1600 min/max: 800/3300 cores: 1: 1600 2: 1600 3: 1600
    4: 1600 bogomips: 21607
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Graphics:
  Device-1: Intel HD Graphics 630 vendor: CLEVO/KAPOK driver: i915 v: kernel
    arch: Gen-9.5 bus-ID: 00:02.0
  Device-2: Chicony USB2.0 Camera type: USB driver: uvcvideo bus-ID: 1-6:2
  Display: x11 server: X.org v: 1.21.1.4 driver: X: loaded: modesetting
    dri: iris gpu: i915 resolution: 1280x720~60Hz
  API: OpenGL Message: Unable to show GL data. Required tool glxinfo
    missing.
Audio:
  Device-1: Intel 100 Series/C230 Series Family HD Audio vendor: CLEVO/KAPOK
    driver: snd_hda_intel v: kernel bus-ID: 00:1f.3
  Sound API: ALSA v: k5.4.224-1-MANJARO running: yes
  Sound Server-1: JACK v: 0.125.0 running: no
  Sound Server-2: PulseAudio v: 16.1 running: yes
  Sound Server-3: PipeWire v: 0.3.59 running: no
Network:
  Device-1: Intel Wireless 8265 / 8275 driver: iwlwifi v: kernel
    bus-ID: 01:00.0
  IF: wlp1s0 state: down mac: <filter>
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: CLEVO/KAPOK driver: r8168 v: 8.050.03-NAPI port: e000
    bus-ID: 05:00.0
  IF: enp5s0 state: up speed: 100 Mbps duplex: full mac: <filter>
Bluetooth:
  Device-1: Intel Bluetooth wireless interface type: USB driver: btusb v: 0.8
    bus-ID: 1-10:3
  Report: rfkill ID: hci0 rfk-id: 4 state: up address: see --recommends
Drives:
  Local Storage: total: 1.14 TiB used: 784.76 GiB (67.4%)
  ID-1: /dev/nvme0n1 vendor: Samsung model: SSD 960 EVO 250GB
    size: 232.89 GiB
  ID-2: /dev/sda vendor: Seagate model: ST1000LM048-2E7172 size: 931.51 GiB
Partition:
  ID-1: / size: 227.18 GiB used: 41.43 GiB (18.2%) fs: ext4
    dev: /dev/nvme0n1p2
  ID-2: /boot/efi size: 1022 MiB used: 288 KiB (0.0%) fs: vfat
    dev: /dev/nvme0n1p1
  ID-3: /home size: 911.88 GiB used: 743.33 GiB (81.5%) fs: ext4
    dev: /dev/sda2
Swap:
  ID-1: swap-1 type: file size: 8 GiB used: 120.4 MiB (1.5%) file: /swapfile
Sensors:
  System Temperatures: cpu: 57.0 C pch: 63.0 C mobo: N/A
  Fan Speeds (RPM): N/A
Info:
  Processes: 207 Uptime: 10h 29m Memory: 7.69 GiB used: 5.44 GiB (70.7%)
  Init: systemd Compilers: gcc: 12.2.0 clang: 14.0.6 Packages: 1800
  Shell: Bash v: 5.1.16 inxi: 3.3.23

Thanks a lot for your attention!

If you want a newer kernel, try 5.15 and see if hibernation works.

1 Like

Thanks @Jim.B . I will try with it but I thought that 5.10 should be more stable than 5.15, so I have first tried to “upgrade” my 5.4 to a 5.10 kernel.

5.15 is pretty good, and its a lts kernel. Cant hurt to try.

1 Like

Unfortunately the hibernation does not work neither with the 5.15.78-1 kernel I am currently using. Instead of hibernating, it shuts down…

Below some maybe useful information:

journalctl --system --boot=0 --priority=3
nov. 21 14:34:34 Strauss kernel: x86/cpu: SGX disabled by BIOS.
nov. 21 14:34:34 Strauss kernel: ACPI BIOS Error (bug): Could not resolve symbol [\_PR.CPU0._CPC], AE_NOT_FOUND (2021073>
nov. 21 14:34:34 Strauss kernel: ACPI Error: Aborting method \_PR.CPU1._CPC due to previous error (AE_NOT_FOUND) (202107>
nov. 21 14:34:34 Strauss kernel: ACPI BIOS Error (bug): Could not resolve symbol [\_PR.CPU0._CPC], AE_NOT_FOUND (2021073>
nov. 21 14:34:34 Strauss kernel: ACPI Error: Aborting method \_PR.CPU2._CPC due to previous error (AE_NOT_FOUND) (202107>
nov. 21 14:34:34 Strauss kernel: ACPI BIOS Error (bug): Could not resolve symbol [\_PR.CPU0._CPC], AE_NOT_FOUND (2021073>
nov. 21 14:34:34 Strauss kernel: ACPI Error: Aborting method \_PR.CPU3._CPC due to previous error (AE_NOT_FOUND) (202107>
nov. 21 14:34:37 Strauss kernel: Bluetooth: hci0: Reading supported features failed (-16)
nov. 21 14:34:55 Strauss bluetoothd[642]: src/plugin.c:plugin_init() Failed to init vcp plugin
nov. 21 14:34:55 Strauss bluetoothd[642]: src/plugin.c:plugin_init() Failed to init mcp plugin
nov. 21 14:34:55 Strauss bluetoothd[642]: src/plugin.c:plugin_init() Failed to init bap plugin
nov. 21 14:34:57 Strauss lightdm[970]: pam_faillock(lightdm:auth): Unknown option: onerr
nov. 21 14:34:57 Strauss lightdm[970]: pam_faillock(lightdm:auth): Unknown option: file
nov. 21 14:35:00 Strauss lightdm[970]: gkr-pam: unable to locate daemon control file
inxi -Fxzc0 --no-host with 5.15 kernel
System:
  Kernel: 5.15.78-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.2.0
    Desktop: Xfce v: 4.16.1 Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Laptop System: Notebook product: N650DU v: N/A
    serial: <superuser required>
  Mobo: Notebook model: N650DU serial: <superuser required>
    UEFI: American Megatrends v: 5.12 date: 02/26/2018
Battery:
  ID-1: BAT0 charge: 40.8 Wh (100.0%) condition: 40.8/62.2 Wh (65.6%)
    volts: 12.7 min: 11.1 model: Notebook BAT status: full
CPU:
  Info: quad core model: Intel Core i5-7500T bits: 64 type: MCP
    arch: Kaby Lake rev: 9 cache: L1: 256 KiB L2: 1024 KiB L3: 6 MiB
  Speed (MHz): avg: 1444 high: 1477 min/max: 800/3300 cores: 1: 1418 2: 1407
    3: 1474 4: 1477 bogomips: 21607
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Graphics:
  Device-1: Intel HD Graphics 630 vendor: CLEVO/KAPOK driver: i915 v: kernel
    arch: Gen-9.5 bus-ID: 00:02.0
  Device-2: Chicony USB2.0 Camera type: USB driver: uvcvideo bus-ID: 1-6:2
  Display: x11 server: X.org v: 1.21.1.4 driver: X: loaded: modesetting
    dri: iris gpu: i915 resolution: 1280x720~60Hz
  API: OpenGL Message: Unable to show GL data. Required tool glxinfo
    missing.
Audio:
  Device-1: Intel 100 Series/C230 Series Family HD Audio vendor: CLEVO/KAPOK
    driver: snd_hda_intel v: kernel bus-ID: 00:1f.3
  Sound API: ALSA v: k5.15.78-1-MANJARO running: yes
  Sound Server-1: JACK v: 0.125.0 running: no
  Sound Server-2: PulseAudio v: 16.1 running: yes
  Sound Server-3: PipeWire v: 0.3.59 running: no
Network:
  Device-1: Intel Wireless 8265 / 8275 driver: iwlwifi v: kernel
    bus-ID: 01:00.0
  IF: wlp1s0 state: down mac: <filter>
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: CLEVO/KAPOK driver: r8168 v: 8.050.03-NAPI port: e000
    bus-ID: 05:00.0
  IF: enp5s0 state: up speed: 100 Mbps duplex: full mac: <filter>
Bluetooth:
  Device-1: Intel Bluetooth wireless interface type: USB driver: btusb v: 0.8
    bus-ID: 1-10:3
  Report: rfkill ID: hci0 rfk-id: 1 state: up address: see --recommends
Drives:
  Local Storage: total: 1.14 TiB used: 785.17 GiB (67.4%)
  ID-1: /dev/nvme0n1 vendor: Samsung model: SSD 960 EVO 250GB
    size: 232.89 GiB temp: 44.9 C
  ID-2: /dev/sda vendor: Seagate model: ST1000LM048-2E7172 size: 931.51 GiB
Partition:
  ID-1: / size: 227.18 GiB used: 41.83 GiB (18.4%) fs: ext4
    dev: /dev/nvme0n1p2
  ID-2: /boot/efi size: 1022 MiB used: 288 KiB (0.0%) fs: vfat
    dev: /dev/nvme0n1p1
  ID-3: /home size: 911.88 GiB used: 743.33 GiB (81.5%) fs: ext4
    dev: /dev/sda2
Swap:
  ID-1: swap-1 type: file size: 8 GiB used: 16.8 MiB (0.2%) file: /swapfile
Sensors:
  System Temperatures: cpu: 49.0 C pch: 63.5 C mobo: N/A
  Fan Speeds (RPM): N/A
Info:
  Processes: 204 Uptime: 15m Memory: 7.68 GiB used: 3.64 GiB (47.4%)
  Init: systemd Compilers: gcc: 12.2.0 clang: 14.0.6 Packages: 1803
  Shell: Bash v: 5.1.16 inxi: 3.3.23

Does anyone have please an idea how to solve it?

Thanks again for your attention!

Thanks again @Jim.B for your answers.

I have the following this post written by @FancierTech which seems somehow similar:

According to him the solution would be found on this post written by @Wollie :

My /etc/fstab is the following:
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a device; this may
# be used with UUID= as a more robust way to name devices that works even if
# disks are added and removed. See fstab(5).
#
# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=CB2B-F14D                            /boot/efi      vfat    defaults,noatime 0 2
UUID=9bb57f6c-3448-4344-b74a-4bf0077ff48a /              ext4    defaults,noatime 0 1
UUID=0ad0883f-6f99-4b41-b4c7-2bc76822afb5 /home          ext4    defaults,noatime 0 2
/swapfile none swap defaults 0 0
UUID=24718325-ae45-4a9e-a52d-6a6b91d976b2 /home/ricardo/Supplément/ ext4 defaults,noatime 0 2

The swapfile is mentioned so it could be good.

My /etc/default/grub is the following:
GRUB_DEFAULT=saved
GRUB_TIMEOUT=5
GRUB_TIMEOUT_STYLE=hidden
GRUB_DISTRIBUTOR="Manjaro"
GRUB_CMDLINE_LINUX_DEFAULT="quiet udev.log_priority=3"
GRUB_CMDLINE_LINUX="quiet resume=UUID=9bb57f6c-3448-4344-b74a-4bf0077ff48a resume_offset=2916352"

# If you want to enable the save default function, uncomment the following
# line, and set GRUB_DEFAULT to saved.
GRUB_SAVEDEFAULT=true

# Uncomment to disable submenus in boot menu
#GRUB_DISABLE_SUBMENU=y

# Preload both GPT and MBR modules so that they are not missed
GRUB_PRELOAD_MODULES="part_gpt part_msdos"

# Uncomment to enable booting from LUKS encrypted devices
#GRUB_ENABLE_CRYPTODISK=y

# Uncomment to use basic console
GRUB_TERMINAL_INPUT=console

# Uncomment to disable graphical terminal
#GRUB_TERMINAL_OUTPUT=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command 'videoinfo'
GRUB_GFXMODE=auto

# Uncomment to allow the kernel use the same resolution used by grub
GRUB_GFXPAYLOAD_LINUX=keep

# Uncomment if you want GRUB to pass to the Linux kernel the old parameter 
# format "root=/dev/xxx" instead of "root=/dev/disk/by-uuid/xxx" 
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
GRUB_DISABLE_RECOVERY=true

# Uncomment this option to enable os-prober execution in the grub-mkconfig command
#GRUB_DISABLE_OS_PROBER=false

# Uncomment and set to the desired menu colors.  Used by normal and wallpaper 
# modes only.  Entries specified as foreground/background.
GRUB_COLOR_NORMAL="light-gray/black"
GRUB_COLOR_HIGHLIGHT="green/black"

# Uncomment one of them for the gfx desired, a image background or a gfxtheme
GRUB_BACKGROUND="/usr/share/grub/background.png"
#GRUB_THEME="/path/to/gfxtheme"

# Uncomment to get a beep at GRUB start
#GRUB_INIT_TUNE="480 440 1"

# Uncomment to ensure that the root filesystem is mounted read-only so that
# systemd-fsck can run the check automatically. We use 'fsck' by default, which
# needs 'rw' as boot parameter, to avoid delay in boot-time. 'fsck' needs to be
# removed from 'mkinitcpio.conf' to make 'systemd-fsck' work.
# See also Arch-Wiki: https://wiki.archlinux.org/index.php/Fsck#Boot_time_checking
#GRUB_ROOT_FS_RO=true

This line is present so it should be also good: GRUB_CMDLINE_LINUX="quiet resume=UUID=9bb57f6c-3448-4344-b74a-4bf0077ff48a resume_offset=2916352"

I have not checked that the UUID number is the right one, but since it works currently with my 5.4 kernel it should be the right one, shouldn’t it?

My /etc/mkinitcpio.conf is the following:
# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run.  Advanced users may wish to specify all system modules
# in this array.  For instance:
#     MODULES=(piix ide_disk reiserfs)
MODULES=()

# BINARIES
# This setting includes any additional binaries a given user may
# wish into the CPIO image.  This is run last, so it may be used to
# override the actual binaries included by a given hook
# BINARIES are dependency parsed, so you may safely ignore libraries
BINARIES=()

# FILES
# This setting is similar to BINARIES above, however, files are added
# as-is and are not parsed in any way.  This is useful for config files.
FILES=()

# HOOKS
# This is the most important setting in this file.  The HOOKS control the
# modules and scripts added to the image, and what happens at boot time.
# Order is important, and it is recommended that you do not change the
# order in which HOOKS are added.  Run 'mkinitcpio -H <hook name>' for
# help on a given hook.
# 'base' is _required_ unless you know precisely what you are doing.
# 'udev' is _required_ in order to automatically load modules
# 'filesystems' is _required_ unless you specify your fs modules in MODULES
# Examples:
##   This setup specifies all modules in the MODULES setting above.
##   No raid, lvm2, or encrypted root is needed.
#    HOOKS=(base)
#
##   This setup will autodetect all modules for your system and should
##   work as a sane default
#    HOOKS=(base udev autodetect block filesystems)
#
##   This setup will generate a 'full' image which supports most systems.
##   No autodetection is done.
#    HOOKS=(base udev block filesystems)
#
##   This setup assembles a pata mdadm array with an encrypted root FS.
##   Note: See 'mkinitcpio -H mdadm' for more information on raid devices.
#    HOOKS=(base udev block mdadm encrypt filesystems)
#
##   This setup loads an lvm2 volume group on a usb device.
#    HOOKS=(base udev block lvm2 filesystems)
#
##   NOTE: If you have /usr on a separate partition, you MUST include the
#    usr, fsck and shutdown hooks.
HOOKS=(base udev autodetect modconf block filesystems keyboard fsck)

# COMPRESSION
# Use this to compress the initramfs image. By default, gzip compression
# is used. Use 'cat' to create an uncompressed image.
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"
#COMPRESSION="zstd"

# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=()

# MODULES_DECOMPRESS
# Decompress kernel modules during initramfs creation.
# Enable to speedup boot process, disable to save RAM
# during early userspace. Switch (yes/no).
#MODULES_DECOMPRESS="yes"

In my /etc/mkinitcpio.conf I can see that the resume hook is not set at the end of the end of the parenthesis. According to this @Wollie post, the problem could be here but I cannot still understand why it works with the 5.4 kernel and not with the 5.10 nor with the 5.15 ones.

Wanting to have more information on this resume function before adding it at the end of the hooks list in my /etc/mkinitcpio.conf, I can just see the following information running

$ mkinitcpio -H resume
==> Help for hook 'resume':
This hook initializes support for resuming from Disk.  Supports swsusp and
suspend2.

==> This hook has runtime scripts:
  -> pre-mount hook

Finally, it gives me not so much more information… Is there a risk to try to add resume at the end of the hooks list?

Thanks a lot for your attention!

It is a bit strange that resume did work/does work with the previous kernel
even though
/etc/mkinitcpio.conf
(the HOOKS line)
does not contain the keyword “resume”.

I was under the impression that this was needed - so add it, as that is what enables that functionality.

update-grub afterwards …

it is - it is the UUID of the root partition, where the swap file resides
from /etc/fstab:

No.
Worst case is it still doesn’t work - which it already does :grinning:
and you can easily edit it out again

Did you by chance replace /etc/mkinitcpio.conf with a .pacnew file?

suspend may work without - resume HOOK is for waking up from hibernation

1 Like

Thanks a lot for your answer @Nachlese !
I will now try to add resume function at the the end of the hooks list in my /etc/mkinitcpio.conf.

I have checked in Timeshift the last /etc/mkinitcpio.conf.pacnew that I have found and in this pacnew file the resume function is absent. I have also checked in Timeshift and before merging this pacnew file the resume function was also absent from /etc/mkinitcpio.conf .

I have now added the resume function at the the end of the hooks list in my /etc/mkinitcpio.conf.

After that I have launched sudo mkinitcpio -P and sudo update-grub as @Wollie recommended in this post.

Lauching sudo mkinitcpio -P, I can see the following warning message for each kernel:

  -> Running build hook: [block]
==> WARNING: Possibly missing firmware for module: qed
==> WARNING: Possibly missing firmware for module: bfa
==> WARNING: Possibly missing firmware for module: qla2xxx
==> WARNING: Possibly missing firmware for module: qla1280

What does it exactly mean? Is there now a risk to restart or hibernate the computer?

No, that’s normal.

If you would have any of these devices, you would know.

1 Like

Thanks @mithrial for your answer!

I have now rebooted and I can hibernate with both 5.10 and 5.15 kernels! The solution is then the following:

Thanks @Nachlese and @Jim.B for your help!

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