From 6d2c5b23122dc7ffc4be5981cb5ceaa95561836d Mon Sep 17 00:00:00 2001 From: Dan Schaper Date: Thu, 17 Nov 2016 10:58:58 -0800 Subject: [PATCH] Add debug timeoute --- advanced/Scripts/piholeDebug.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/advanced/Scripts/piholeDebug.sh b/advanced/Scripts/piholeDebug.sh index 375fb927..b39d038c 100755 --- a/advanced/Scripts/piholeDebug.sh +++ b/advanced/Scripts/piholeDebug.sh @@ -27,7 +27,7 @@ PIHOLELOG="/var/log/pihole.log" WHITELISTMATCHES="/tmp/whitelistmatches.list" IPV6_READY=false -TIMEOUT=60 +TIMEOUT=15 # Header info and introduction cat << EOM ::: Beginning Pi-hole debug at $(date)! @@ -358,9 +358,7 @@ dumpPiHoleLog() { if [ -e "${PIHOLELOG}" ]; then # Dummy process to use for flagging down tail to terminate sleep ${TIMEOUT} & - while true; do - tail -n0 -f --pid=$! "${PIHOLELOG}" >> ${DEBUG_LOG} - done + tail -n0 -f --pid=$! "${PIHOLELOG}" >> ${DEBUG_LOG} else log_write "No pihole.log file found!" printf ":::\tNo pihole.log file found!\n"