sonic-buildimage/files/image_config/watchdog-control/watchdog-control.sh
Sujin Kang aea18165a8
Add watchdog-control service to disable watchdog during bootup (#3877)
* Add watchdog-control service to disable watchdog during bootup

Disable only if it's applicable and the watchdog is enabled.

* Address the review comment

* Correct the watchdog start script name

* Change to call common watchdog api instead of platform specific

* Start watchdog control service after swss starts

* advance sonic-utility submodule
2019-12-13 12:44:11 -08:00

23 lines
334 B
Bash

#! /bin/bash
VERBOSE=no
function debug()
{
/usr/bin/logger "$0 : $1"
if [[ x"${VERBOSE}" == x"yes" ]]; then
echo "$(date) $0: $1"
fi
}
function disable_watchdog()
{
if [[ -x /usr/bin/watchdog ]]; then
debug "Disabling Watchdog during bootup"
/usr/bin/watchdog -d
fi
}
disable_watchdog