From a1b3a9a05cbf707d347a9cc69df209e7b4a1b8cf Mon Sep 17 00:00:00 2001 From: James Bunton Date: Wed, 17 Jun 2020 23:00:51 +1000 Subject: [PATCH 1/1] healthcheck: zpool-health --- healthcheck/zpool-health | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 healthcheck/zpool-health diff --git a/healthcheck/zpool-health b/healthcheck/zpool-health new file mode 100755 index 0000000..0864b80 --- /dev/null +++ b/healthcheck/zpool-health @@ -0,0 +1,9 @@ +#!/bin/bash + +if ! command -v zpool > /dev/null; then + exit 0 +fi + +if zpool list -H -o health,name | grep -qv ONLINE; then + zpool status -v +fi -- 2.39.2