diff options
author | Erich Eckner <git@eckner.net> | 2020-01-09 15:12:16 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2020-01-09 15:12:16 +0100 |
commit | 30852e80bcf2dd59471922b2c431553d72045736 (patch) | |
tree | 49267bace8a2870cc7c53728cea996d4d7d0e261 /crypt-expiry-check.in | |
parent | fe54d4827cc0ebfa106a85ce061be71dfbe89da2 (diff) | |
download | crypt-expiry-check-30852e80bcf2dd59471922b2c431553d72045736.tar.xz |
crypt-expiry-check: recognize "Network is unreachable" error
Diffstat (limited to 'crypt-expiry-check.in')
-rwxr-xr-x | crypt-expiry-check.in | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/crypt-expiry-check.in b/crypt-expiry-check.in index 100ff0c..419222e 100755 --- a/crypt-expiry-check.in +++ b/crypt-expiry-check.in @@ -268,6 +268,11 @@ check_server_status() { prints ${1} ${2} "Connection refused" "Unknown" | ${TEE} -a ${MAILOUT_TMP} >> ${STDOUT_TMP} set_retcode 3 + elif ${GREP} -iq "Network is unreachable" ${ERROR_TMP} + then + prints ${1} ${2} "Network is unreachable" "Unknown" | ${TEE} -a ${MAILOUT_TMP} >> ${STDOUT_TMP} + set_retcode 3 + elif ${GREP} -iq "No route to host" ${ERROR_TMP} then prints ${1} ${2} "No route to host" "Unknown" | ${TEE} -a ${MAILOUT_TMP} >> ${STDOUT_TMP} |