Suggestion: Perform kexec for rebooting from update mode into the updated system

Hello, this is my first time posting a suggestion. Edit: Merry Christmas!

Summery

Perform kexec for rebooting from update mode into the updated system instead of full system reboot.

Description:
The current procedure of offline update is slow and requires two full reboots, which can be inconvenient

Download updates ----> Full reboot ----> Install updates ----> Full reboot ----> Boot updated system.

The proposed procedure is to use kexec to execute the latest kernel image without rebooting. This way, the system can be updated faster.

Download updates ----> Full reboot ----> Install updates ----> kexec updated system/kernel.

Ideally, if the user is rebooting explicitly to install updates (e.g. clicking “Restart & Update” from the dialog in GNOME Software or KDE Discover), performkexec twice instead of reboot:

Download updates ----> kexec into system update mode ----> Install updates ----> kexec updated system/kernel.

Hi Mazin,

kexec is great, but has one significant shortcoming: some hardware and/or drivers do not handle kexec properly. In particular, various graphics drivers had this issue that after a kexec apparently some state was carried over and the display was garbled. Because of such shortcomings, kexec was never the default. But if you test it and it works properly on your machine, then great, by all means use it. It is also possible that the quality of hardware, firmware, and drivers has improved, and we could recommend it more widely, but we would need to back that up by widespread testing.

I see. Thank you for explaining. I will look for a method to use kexec on my machine.

1 Like

We could probably expose an easy way to toggle it on and off?

kexec works mostly fine in a server fleet but of course those tend not to have GPUs (and the hardware is much less heterogeneous so can be better tested)

I think we could expose this as an option in /etc/systemd/sleep.conf. We configure various aspects of how suspend and hiberation works there, so also controlling details of reboot would be a natural fit.

1 Like