I have a handful of Debian 12 systems that I want to configure such that they reboot automatically in case of a problem. I have set them up with userspace scripts (executed through cron) to reboot if something goes wrong there; that appears to work as expected if I induce an issue that those scripts check for. That leaves kernel-level issues.
To try to configure this, I have created a file /etc/sysctl.d/local.conf (owned by root:root, mode 0644). # cat /etc/sysctl.d/local.conf kernel.panic = 120 kernel.panic_on_oops = 1 kernel.panic_on_stackoverflow = 1 kernel.panic_on_io_nmi = 1 # With the exception of panic_on_stackoverflow, as far as I can tell these are in effect after a reboot: # sysctl kernel.panic kernel.panic_on_oops kernel.panic_on_stackoverflow kernel.panic_on_io_nmi kernel.panic = 120 kernel.panic_on_oops = 1 sysctl: cannot stat /proc/sys/kernel/panic_on_stackoverflow: No such file or directory kernel.panic_on_io_nmi = 1 # However, this morning I woke up to one of those systems showing a kernel crash dump and being frozen. Unfortunately the first part of the crash dump had scrolled past so I couldn't tell what class of problem caused the crash. Do I need to set some more settings to ensure that the system will automatically reboot on a panic? If so, what? I know that best is to not crash; this is _in case of_. -- Michael Kjörling 🔗 https://michael.kjorling.se “Remember when, on the Internet, nobody cared that you were a dog?”