From 07183520f3f4d2f89e526055db418046d0d2450f Mon Sep 17 00:00:00 2001 From: An-Cheng Huang Date: Fri, 19 Oct 2007 11:26:15 -0700 Subject: move "system" configuration templates/scripts from vyatta-cfg. --- templates/system/options/reboot-on-panic/node.def | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 templates/system/options/reboot-on-panic/node.def (limited to 'templates/system/options/reboot-on-panic/node.def') diff --git a/templates/system/options/reboot-on-panic/node.def b/templates/system/options/reboot-on-panic/node.def new file mode 100644 index 00000000..d84abc74 --- /dev/null +++ b/templates/system/options/reboot-on-panic/node.def @@ -0,0 +1,16 @@ +type: bool +help: "Configure if kernel panic causes reboot" +default: true +create: "sh -c \"if [ x$(@) == xfalse ]; \ +then \ + echo 0 > /proc/sys/kernel/panic; \ +else \ + echo 60 > /proc/sys/kernel/panic; \ +fi\" " +update: "sh -c \"if [ x$(@) == xfalse ]; \ +then \ + echo 0 > /proc/sys/kernel/panic; \ +else \ + echo 60 > /proc/sys/kernel/panic; \ +fi\" " +delete: "sh -c \"echo 60 > /proc/sys/kernel/panic\" " -- cgit v1.2.3