nationals 发表于 2014-4-15 16:55:56

raspberry pi看门狗

本帖最后由 nationals 于 2014-4-16 14:09 编辑

#!/bin/sh
# watchdog for raspberry pi

sudo apt-get install watchdog -y || exit
sudo modprobe bcm2708_wdog
echo bcm2708_wdog | sudo tee -a /etc/modules

sudo sed -i 's/^#watchdog-device/watchdog-device/g' /etc/watchdog.conf
sudo sed -i 's/^#max-load-1 /max-load-1 /g' /etc/watchdog.conf

sudo sed -i '/^#temperature-device/a\temperature-device = /sys/class/thermal/thermal_zone0/temp' /etc/watchdog.conf
sudo sed -i '/^#max-temperature/a\max-temperature = 75000' /etc/watchdog.conf

sudo /etc/init.d/watchdog start

nationals 发表于 2014-4-16 14:09:41

sudo update-rc.d watchdog defaults
页: [1]
查看完整版本: raspberry pi看门狗