about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorBenedikt Peetz <benedikt.peetz@b-peetz.de>2026-03-22 18:03:01 +0100
committerBenedikt Peetz <benedikt.peetz@b-peetz.de>2026-03-22 18:03:01 +0100
commit2274f84754d990907ea517a883e5e1a15a9763e9 (patch)
tree9c662f653602914fc7bb4e84defdc7505f57923a
parentscripts/update_hosts: Init (diff)
downloadnixos-server-2274f84754d990907ea517a883e5e1a15a9763e9.zip
scripts/ping_hosts: Init
That is a basic status checking script. It works good enough until
monitoring is set-up.
Diffstat (limited to '')
-rwxr-xr-xscripts/ping_hosts.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/ping_hosts.sh b/scripts/ping_hosts.sh
new file mode 100755
index 0000000..fba2490
--- /dev/null
+++ b/scripts/ping_hosts.sh
@@ -0,0 +1,12 @@
+#! /usr/bin/env sh
+
+user="${1-$USER}"
+hosts="${2-server2 server3}"
+
+for host in $hosts; do
+    echo "Checking status of '$user@$host.vhack.eu' ..."
+
+    ssh "$user@$host.vhack.eu" "set -x; systemctl --failed"
+done
+
+# vim: ft=sh