From 527fc3c5cf6372bc52de4a94064a23c7d88bdd9d Mon Sep 17 00:00:00 2001 From: DL6ER Date: Tue, 21 Jul 2020 21:39:59 +0200 Subject: [PATCH] Also pidof -> pgrep in gravity.sh Signed-off-by: DL6ER --- gravity.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/gravity.sh b/gravity.sh index 9d4c7bee..636c9872 100755 --- a/gravity.sh +++ b/gravity.sh @@ -43,8 +43,6 @@ optimize_database=false domainsExtension="domains" -resolver="pihole-FTL" - # Source setupVars from install script setupVars="${piholeDir}/setupVars.conf" if [[ -f "${setupVars}" ]];then @@ -284,7 +282,7 @@ gravity_CheckDNSResolutionAvailable() { fi # Determine error output message - if pidof ${resolver} &> /dev/null; then + if pgrep pihole-FTL &> /dev/null; then echo -e " ${CROSS} DNS resolution is currently unavailable" else echo -e " ${CROSS} DNS service is not running" @@ -746,7 +744,7 @@ gravity_Cleanup() { fi # Only restart DNS service if offline - if ! pidof ${resolver} &> /dev/null; then + if ! pgrep pihole-FTL &> /dev/null; then "${PIHOLE_COMMAND}" restartdns dnsWasOffline=true fi