Friday, April 26, 2024
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 803  / 1 Year ago, wed, may 10, 2023, 12:10:18

I'm using unattended upgrades and I want to reboot automatically when kernel is upgraded.


Is that possible?


More From » unattended-upgrades

 Answers
0

You can set up automatic reboot after Unattended Upgrades has upgraded/installed something that requires reboot. That includes installing new kernels.


Related configuration variables:


// Automatically reboot *WITHOUT CONFIRMATION* if
// the file /var/run/reboot-required is found after the upgrade
//Unattended-Upgrade::Automatic-Reboot "false";

// Automatically reboot even if there are users currently logged in
// when Unattended-Upgrade::Automatic-Reboot is set to true
//Unattended-Upgrade::Automatic-Reboot-WithUsers "true";

// If automatic reboot is enabled and needed, reboot at the specific
// time instead of immediately
// Default: "now"
//Unattended-Upgrade::Automatic-Reboot-Time "02:00";

Save your preferred settings in file /etc/apt/apt.conf.d/52unattended-upgrades-local (so that you do not have to modify 50unattended-upgrades provided by the package).


You can see explicitly set configuration values by
apt-config dump unattended-upgrade


Unfortunately, you can not list all current values.
https://github.com/mvo5/unattended-upgrades/issues/245


You could see more documentation (of the latest version) at https://github.com/mvo5/unattended-upgrades


Unfortunately not all supported options are explained there, though:
https://github.com/mvo5/unattended-upgrades/issues/246
https://github.com/mvo5/unattended-upgrades/issues/318


[#681] Wednesday, May 10, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ainbby

Total Points: 184
Total Questions: 115
Total Answers: 112

Location: Colombia
Member since Thu, Sep 29, 2022
2 Years ago
ainbby questions
;