Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/pi-hole/pi-hole.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/pihole
diff options
context:
space:
mode:
authorChristian König <ckoenig@posteo.de>2022-05-29 10:51:33 +0300
committerChristian König <ckoenig@posteo.de>2022-07-11 00:32:47 +0300
commitb486786041cd235151e189e17f4c869751150e78 (patch)
treeac42d56393235421598a244bc3a15b3e244deb6d /pihole
parente0baf4c7ecd8f3273c84fd8df4e461f50afd6374 (diff)
Add database healthy checks to debug script
Fix health check output comparison in gravity script as well Add note about waiting time Signed-off-by: Christian König <ckoenig@posteo.de>
Diffstat (limited to 'pihole')
-rwxr-xr-xpihole28
1 files changed, 15 insertions, 13 deletions
diff --git a/pihole b/pihole
index c54a3192..35f6c07b 100755
--- a/pihole
+++ b/pihole
@@ -36,19 +36,20 @@ listFunc() {
}
debugFunc() {
- local automated
- local web
-
- # Pull off the `debug` leaving passed call augmentation flags in $1
- shift
- if [[ "$@" == *"-a"* ]]; then
- automated="true"
- fi
- if [[ "$@" == *"-w"* ]]; then
- web="true"
- fi
-
- AUTOMATED=${automated:-} WEBCALL=${web:-} "${PI_HOLE_SCRIPT_DIR}"/piholeDebug.sh
+ local automated
+ local web
+ local check_database_integrity
+ # Pull off the `debug` leaving passed call augmentation flags in $1
+ shift
+
+ for value in "$@"; do
+ [[ "$value" == *"-a"* ]] && automated="true"
+ [[ "$value" == *"-w"* ]] && web="true"
+ [[ "$value" == *"-c"* ]] && check_database_integrity="true"
+ [[ "$value" == *"--check_database"* ]] && check_database_integrity="true"
+ done
+
+ AUTOMATED=${automated:-} WEBCALL=${web:-} CHECK_DATABASE=${check_database_integrity:-} "${PI_HOLE_SCRIPT_DIR}"/piholeDebug.sh
exit 0
}
@@ -455,6 +456,7 @@ Whitelist/Blacklist Options:
Debugging Options:
-d, debug Start a debugging session
+ Add '-c' or '--check-database' to include a Pi-hole database integrity check
Add '-a' to automatically upload the log to tricorder.pi-hole.net
-f, flush Flush the Pi-hole log
-r, reconfigure Reconfigure or Repair Pi-hole subsystems