dsa-check-timedatectl: Accept "Network time on" string also instead of just "NTP...
authorPeter Palfrader <peter@palfrader.org>
Mon, 23 Jan 2017 12:41:57 +0000 (13:41 +0100)
committerPeter Palfrader <peter@palfrader.org>
Mon, 23 Jan 2017 12:41:57 +0000 (13:41 +0100)
dsa-nagios-checks/checks/dsa-check-timedatectl

index b3bc554..13956d2 100755 (executable)
@@ -46,7 +46,7 @@ if [ "$d" -lt "-$MAX" ] ||
 fi
 
 
-bool=$(sed '/NTP enabled:/ { s/^[^:]*: *//; p}; d' "$temp")
+bool=$(sed '/\(NTP enabled\|Network time on\):/ { s/^[^:]*: *//; p}; d' "$temp")
 if [ "$bool" != "yes" ]; then
        echo "Warning: NTP not enabled!"
        exit 1