fix bsd and package name
This commit is contained in:
parent
8975ca2736
commit
2e6a0b9bc1
|
@ -27,7 +27,7 @@ if [[ -z $query_domain && ${query_domain+x} ]]; then
|
|||
fi
|
||||
|
||||
# Perform DNS resolution check and measure the time
|
||||
start_time=$(date +%s%N)
|
||||
start_time=$(date +%s)
|
||||
|
||||
if [[ -z "$dns_server" ]]; then
|
||||
# The DNS server was not provided.
|
||||
|
@ -37,8 +37,8 @@ else
|
|||
result=$(dig @$dns_server "$query_domain" +short)
|
||||
fi
|
||||
|
||||
end_time=$(date +%s%N)
|
||||
response_time=$(((end_time - start_time) / 1000000))
|
||||
end_time=$(date +%s)
|
||||
response_time=$((end_time - start_time))
|
||||
perfdata="response_time=${response_time}ms;${warning_time};${critical_time};0;"
|
||||
|
||||
# Check response time against warning and critical levels
|
||||
|
|
|
@ -6,4 +6,4 @@ smartmontools
|
|||
curl
|
||||
recode
|
||||
python3-pip
|
||||
dig
|
||||
dnsutils
|
||||
|
|
Loading…
Reference in New Issue