From 0282edc89d36b2795cb6cde6084ef39727b8c5a6 Mon Sep 17 00:00:00 2001 From: Leo Krueger Date: Fri, 21 Feb 2014 22:22:09 +0100 Subject: [PATCH] added check if dnsmasq is running --- updateDnsmasq.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/updateDnsmasq.sh b/updateDnsmasq.sh index 46e0f3c..f22a215 100755 --- a/updateDnsmasq.sh +++ b/updateDnsmasq.sh @@ -19,3 +19,7 @@ then /usr/sbin/service dnsmasq restart fi +ps -C "dnsmasq" 2>&1>/dev/null +if [[ $? -ne 0 ]] + /usr/sbin/service dnsmasq restart +fi