TIL: If you have full-disk encryption with a key embedded in initrd (https://en.opensuse.org/SDB:Encrypted_root_file_system#Avoiding_to_type_the_passphrase_twice) you can easily use kexec (https://doc.opensuse.org/documentation/leap/tuning/html/book.sle.tuning/cha-tuning-kexec.html#cha-tuning-kexec-basic-usage) for fast and passwordless reboots.
@lebel It works on 2 of my machines with TW, but I got the same error on one running Leap 15.1. So yeah, it seems there are some bugs here to squash.
@lebel Turns out my error message was not the same. I had "Unable to get default section of bootloader configuration". I found that command `grub2-editenv list` returns `saved_entry=openSUSE Leap 15.1` with a space at the end. I used `grub2-editenv - set "saved_entry=openSUSE Leap 15.1"` and it works now.
@etam the wierd thing is that I have to do manually a systemctl start kexec-load, THEN, it'll pick up the kernel and "reboot" with systemctl kexec.
@lebel Do you? kexec-load.service has
So if you enable this service, it should be automatically started when doing `systemctl kexec`.
@etam I did enable kexec-load. Did you also enable kexec.target?
@lebel Oops. My bad. Indeed that's what happening. Looks like "systemctl kexec" is checking if there's a new kernel loaded before doing anything.
On the other hand, I just checked, that if you replace reboot.target with kexec.target (second link in my first post), then while rebooting with normal "reboot", it's loading kernel with kexec-load.service and doing kexec.
@etam Indeed! It does work with reboot. With kexec I still doesn't work complaining with
“No boot loader entry suitable as default, refusing to guess.”
But with reboot it does the whole thing correctly and reboot the laptop. It'll be handy when I want to reboot my laptop while I'm at work (I usually leave it on all the time).
Fosstodon is an English speaking Mastodon instance that is open to anyone who is interested in technology; particularly free & open source software.