Activity log for bug #1978511

Date Who What changed Old value New value Message
2022-06-14 01:35:29 Paul Collins bug added bug
2022-06-14 01:35:46 Paul Collins bug added subscriber The Canonical Sysadmins
2022-06-14 21:29:27 Paul Collins description Running monitoring-plugins-standard 2.2-6ubuntu1.2 from Ubuntu 20.04 LTS (focal). check_dns was failing as follows: $ /usr/lib/nagios/plugins/check_dns -H localhost -a 127.0.0.1 -s 127.0.0.1 Connection to DNS 127.0.0.1 was refused $ _ However, the nameserver is clearly working: $ dig +short localhost 127.0.0.1 127.0.0.1 $ _ I straced check_dns and discovered that it was forking nslookup. Running nslookup directly reveals: $ /usr/bin/nslookup -sil localhost 127.0.0.1 Server: 127.0.0.1 Address: 127.0.0.1#53 ** server can't find localhost.openstack.lan: REFUSED $ _ So it's not that the connection to the DNS server was refused, but the query itself was refused by the DNS server. These are very different cases, and check_dns really muddied the water here. I fixed it by changing check_dns to query "localhost.", but better diagnostics from check_dns would have helped a lot. Running monitoring-plugins-standard 2.2-6ubuntu1.2 from Ubuntu 20.04 LTS (focal). check_dns was failing as follows: $ /usr/lib/nagios/plugins/check_dns -H localhost -a 127.0.0.1 -s 127.0.0.1 Connection to DNS 127.0.0.1 was refused $ _ However, the nameserver is clearly working: $ dig +short localhost 127.0.0.1 127.0.0.1 $ _ I straced check_dns and discovered that it was forking nslookup. Running nslookup directly reveals: $ /usr/bin/nslookup -sil localhost 127.0.0.1 Server: 127.0.0.1 Address: 127.0.0.1#53 ** server can't find localhost.openstack.lan: REFUSED $ _ So it's not that the connection to the DNS server was refused, but the query itself was refused by the DNS server. These are very different cases. A workaround is to change my nrpe check_dns command to query "localhost.".
2022-07-02 21:03:17 Patrick Olson bug added subscriber Patrick Olson