Transclusion: Debian: Watchdog

From Compulab Mediawiki
Revision as of 13:30, 6 July 2022 by Igor (talk | contribs) (Created page with "CL-SOM-iMX7 watchdog function is implemented with iMX7 SoC built-in Watchdog Timer (WDOG1). By default watchdog is not configured in this Debian rootfs. <pre> root@cl-debian:~...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

CL-SOM-iMX7 watchdog function is implemented with iMX7 SoC built-in Watchdog Timer (WDOG1). By default watchdog is not configured in this Debian rootfs.

root@cl-debian:~# systemctl show | grep -i watchdog
RuntimeWatchdogUSec=0
ShutdownWatchdogUSec=10min
ServiceWatchdogs=yes

The value RuntimeWatchdogUSec=0 means watchdog logic is disabled: no watchdog device is opened, configured, or pinged.
Any non-zero value enables it. Please refer to systemd-system.conf manual for more details.

Watchdog configuration

Edit /etc/systemd/system.conf file to configure watchdog related parameters, in particular RuntimeWatchdogSec and ShutdownWatchdogSec.

Watchdog testing

Run the following command to simulate kernel panic:

root@cl-debian:~# echo "c" > /proc/sysrq-trigger

As a result, the watchdog is not fed and the system reboots after per-configured timeout.