Hibernation no longer works

You and arvidjaar should read and learn from this links, that the official SUSE kernel (6.4 → openSUSE Leap 15.6) supports hibernation in UEFI Secure boot mode. There is a patch from SUSE for the linux kernel 6.4 which allow the usage of hibernation in UEFI Secure boot mode. Other linux kernel versions for openSUSE Leap 15.6 doesn’t support hibernation in UEFI Secure boot mode.

This patch works with a secret key. The storage place of this secret key is the NVRAM of the UEFI Firmware (BIOS).

The source of the numbers in the secret key is a hardware random number generator (hwrng). Linux kernel needs access to this hardware random number generator over the UEFI Firmware (BIOS) to create the secret key for hibernation in UEFI Secure boot mode.

Check your linux kernel version and keep an eye on dmesg output. Here an example from a machine (SLED15 SP6) which doesn’t support hibernation in UEFI Secure boot:

# uname -rsm
Linux 6.4.0-150600.23.38-default x86_64

# mokutil --sb-state
SecureBoot enabled

# systemctl hibernate 
Call to Hibernate failed: Sleep verb "hibernate" not supported

# dmesg |grep -i hiber
[ 1845.711525] Lockdown: systemd-logind: hibernation is restricted; see man kernel_lockdown.7
[ 1845.711530] PM: hibernation: the secret key is invalid

# echo 1 > /sys/firmware/efi/secret-key/regen
# reboot

# dmesg |grep -i hiber
[    3.356348] EFI_RNG_PROTOCOL unavailable, hibernation will be lock-down.
[    3.358724] Lockdown: swapper/0: hibernation is restricted; see man kernel_lockdown.7
[    3.358726] PM: hibernation: the secret key is invalid

Dmesg output “EFI_RNG_PROTOCOL unavailable” informs me about a UEFI firmware (BIOS) which do not provide access to any hardware random number generator.