From 2c3fdd15b26e2f53e28049a46befc63dfe190f77 Mon Sep 17 00:00:00 2001 From: Mark Sheppard Date: Tue, 26 Mar 2024 19:45:05 +0000 Subject: [PATCH] fix the systemd-resolved service check in Pi-hole's pre-install hook (#984) Co-authored-by: Mark Sheppard <> --- pi-hole/hooks/pre-install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pi-hole/hooks/pre-install b/pi-hole/hooks/pre-install index 5e0da11b..a65b0036 100755 --- a/pi-hole/hooks/pre-install +++ b/pi-hole/hooks/pre-install @@ -5,7 +5,7 @@ RESOLVED_SERVICE_NAME="systemd-resolved" RESOLVED_CONF_FILE="/etc/systemd/resolved.conf" # Check if the 'systemd-resolved' service is running -if ! systemctl is-active --quiet service "${RESOLVED_SERVICE_NAME}"; then +if ! systemctl is-active --quiet "${RESOLVED_SERVICE_NAME}.service"; then echo "Service '${RESOLVED_SERVICE_NAME}' is not running" exit fi