remove dora: We are exclusively using systemd and its watchdog handling
This commit is contained in:
parent
f7a9058239
commit
e5372b0e1d
|
@ -1,81 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
#/etc/init.d/watchdog: start watchdog daemon.
|
|
||||||
#based on debian/init of watchdog
|
|
||||||
|
|
||||||
### BEGIN INIT INFO
|
|
||||||
# Provides: watchdog
|
|
||||||
# Short-Description: Start software watchdog daemon
|
|
||||||
# Required-Start: $local_fs
|
|
||||||
# Required-Stop:
|
|
||||||
# Should-Start:
|
|
||||||
# Should-Stop:
|
|
||||||
# Default-Start: S
|
|
||||||
# Default-Stop:
|
|
||||||
### END INIT INFO
|
|
||||||
|
|
||||||
PATH=/bin:/usr/bin:/sbin:/usr/sbin
|
|
||||||
|
|
||||||
test -x /usr/sbin/watchdog || exit 0
|
|
||||||
|
|
||||||
# For configuration of the init script use the file
|
|
||||||
# /etc/default/watchdog, do not edit this init script.
|
|
||||||
|
|
||||||
# Set run_watchdog to 1 to start watchdog or 0 to disable it.
|
|
||||||
|
|
||||||
# Specify additional watchdog options here (see manpage).
|
|
||||||
watchdog_options=""
|
|
||||||
|
|
||||||
# Specify module to load
|
|
||||||
watchdog_module="none"
|
|
||||||
|
|
||||||
run_watchdog=1
|
|
||||||
|
|
||||||
[ -e /etc/default/watchdog ] && . /etc/default/watchdog
|
|
||||||
|
|
||||||
NAME=watchdog
|
|
||||||
|
|
||||||
DAEMON=/usr/sbin/watchdog
|
|
||||||
|
|
||||||
case "$1" in
|
|
||||||
start)
|
|
||||||
if [ $run_watchdog = 1 ]
|
|
||||||
then
|
|
||||||
# do we have to load a module?
|
|
||||||
[ ${watchdog_module:-none} != "none" ] && /sbin/modprobe $watchdog_module
|
|
||||||
|
|
||||||
# Unconditionally start watchdog daemon because we want to run it even
|
|
||||||
# if wd_keepalive wasn't running
|
|
||||||
echo "Starting watchdog daemon..."
|
|
||||||
start-stop-daemon --start --quiet --pidfile /var/run/$NAME.pid \
|
|
||||||
--exec $DAEMON -- $watchdog_options
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
|
|
||||||
stop)
|
|
||||||
if [ $run_watchdog = 1 ]
|
|
||||||
then
|
|
||||||
echo "Stopping watchdog daemon..."
|
|
||||||
start-stop-daemon --stop -s 9 --quiet \
|
|
||||||
--pidfile /var/run/$NAME.pid
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
|
|
||||||
restart)
|
|
||||||
$0 force-reload
|
|
||||||
;;
|
|
||||||
|
|
||||||
force-reload)
|
|
||||||
if [ $run_watchdog = 0 ]; then exit 0; fi
|
|
||||||
echo "Restarting ${NAME}"
|
|
||||||
$0 stop
|
|
||||||
$0 start
|
|
||||||
;;
|
|
||||||
|
|
||||||
*)
|
|
||||||
echo "Usage: /etc/init.d/watchdog {start|stop|restart|force-reload}"
|
|
||||||
exit 1
|
|
||||||
|
|
||||||
esac
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
|
|
|
@ -1,41 +0,0 @@
|
||||||
#ping = 172.31.14.1
|
|
||||||
#ping = 172.26.1.255
|
|
||||||
#interface = eth0
|
|
||||||
#file = /var/log/messages
|
|
||||||
#change = 1407
|
|
||||||
|
|
||||||
# Uncomment to enable test. Setting one of these values to '0' disables it.
|
|
||||||
# These values will hopefully never reboot your machine during normal use
|
|
||||||
# (if your machine is really hung, the loadavg will go much higher than 25)
|
|
||||||
#max-load-1 = 24
|
|
||||||
#max-load-5 = 18
|
|
||||||
#max-load-15 = 12
|
|
||||||
|
|
||||||
# Note that this is the number of pages!
|
|
||||||
# To get the real size, check how large the pagesize is on your machine.
|
|
||||||
#min-memory = 1
|
|
||||||
|
|
||||||
#repair-binary = /usr/sbin/repair
|
|
||||||
#repair-timeout =
|
|
||||||
#test-binary =
|
|
||||||
#test-timeout =
|
|
||||||
|
|
||||||
watchdog-device = /dev/watchdog
|
|
||||||
|
|
||||||
# Defaults compiled into the binary
|
|
||||||
#temperature-device =
|
|
||||||
#max-temperature = 120
|
|
||||||
|
|
||||||
# Defaults compiled into the binary
|
|
||||||
#admin = root
|
|
||||||
#interval = 1
|
|
||||||
#logtick = 1
|
|
||||||
#log-dir = /var/log/watchdog
|
|
||||||
|
|
||||||
# This greatly decreases the chance that watchdog won't be scheduled before
|
|
||||||
# your machine is really loaded
|
|
||||||
realtime = yes
|
|
||||||
priority = 1
|
|
||||||
|
|
||||||
# Check if syslogd is still running by enabling the following line
|
|
||||||
#pidfile
|
|
|
@ -1,24 +0,0 @@
|
||||||
SYSMOCOM := "${@os.path.dirname(d.getVar('FILE', True))}"
|
|
||||||
FILESEXTRAPATHS_prepend := "${SYSMOCOM}/${PN}-${PV}:${SYSMOCOM}/${PN}:"
|
|
||||||
PRINC = "9"
|
|
||||||
|
|
||||||
inherit update-rc.d
|
|
||||||
|
|
||||||
SRC_URI_append_sysmobts-v2 = " file://watchdog.conf file://init"
|
|
||||||
|
|
||||||
do_install_append() {
|
|
||||||
|
|
||||||
if [ -e ${WORKDIR}/watchdog.conf ]; then
|
|
||||||
install -D -m 0644 ${WORKDIR}/watchdog.conf ${D}/${sysconfdir}/
|
|
||||||
fi
|
|
||||||
|
|
||||||
install -D -m 0755 ${WORKDIR}/init ${D}/${sysconfdir}/init.d/watchdog
|
|
||||||
}
|
|
||||||
|
|
||||||
CONFFILES_${PN} = "${sysconfdir}/watchdog.conf"
|
|
||||||
INITSCRIPT_PACKAGES = "${PN}"
|
|
||||||
INITSCRIPT_NAME_${PN} = "watchdog"
|
|
||||||
INITSCRIPT_PARAMS_${PN} = "start 06 S ."
|
|
||||||
|
|
||||||
# bug in poky meta/classes/base.bbclass?
|
|
||||||
PACKAGE_ARCH = "${MACHINE_ARCH}"
|
|
Loading…
Reference in New Issue