nagios/glue_records: small corr.
This commit is contained in:
parent
8e37cb2478
commit
554bebfe59
1 changed files with 2 additions and 3 deletions
|
@ -102,8 +102,7 @@ while [ "$#" -gt 0 ]; do
|
|||
fi
|
||||
for IPADDR in $LIST_IP_NS_SERVERS; do
|
||||
# Query our server
|
||||
OUTPUT=$( dig @"$IPADDR" $DOMAIN SOA +short 2>&1 )
|
||||
if [ "$?" -eq 0 ]; then
|
||||
if OUTPUT=$( dig @"$IPADDR" $DOMAIN SOA +short 2>&1 ); then
|
||||
# The server responded, store the SOA for later analyze
|
||||
LIST_SOA="$( printf "%s\n%s" "$LIST_SOA" "$OUTPUT" | grep -v "^$" )"
|
||||
else
|
||||
|
@ -112,7 +111,7 @@ while [ "$#" -gt 0 ]; do
|
|||
OUTPUT_DETAIL_CRITICAL="Problematic server behind IP"
|
||||
OUTPUT_EXIT_STATUS=$STATE_CRITICAL
|
||||
fi
|
||||
OUTPUT_DETAIL_CRITICAL="$OUTPUT_DETAIL_CRITICAL $IPADDRESS"
|
||||
OUTPUT_DETAIL_CRITICAL="$OUTPUT_DETAIL_CRITICAL $IPADDR"
|
||||
fi
|
||||
done
|
||||
|
||||
|
|
Loading…
Reference in a new issue