From 35f98ffb379b021592ce0c2065c2e60d398f77f8 Mon Sep 17 00:00:00 2001 From: st33v Date: Sun, 19 Nov 2017 20:06:45 +1100 Subject: logging everything --- wlanWDprowl.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wlanWDprowl.sh b/wlanWDprowl.sh index 341b932..8bc2c70 100755 --- a/wlanWDprowl.sh +++ b/wlanWDprowl.sh @@ -21,11 +21,12 @@ wirelessLink=$(networkctl | awk '/wlan/ {print $2}') # Prowl: # Detect the state of the wireless network adaptor wlanStatus=$(networkctl status ${wirelessLink} | awk '/State:/ {print $2}') -# echo ${wlanStatus} +logline="$(date) ${wlanStatus}" +# write all to log for now. This will show if I'm still alive. +echo ${logline} if [ ${wlanStatus} != "routable" ]; then # we have lost wireless, so log the occurrence and restart the service - logline="$(date) ${wlanStatus}" echo ${logline} >> ${logdir}/wlanStatus.log sudo systemctl restart systemd-networkd.service fi -- cgit v1.3