Page 1 of 1

can check_bind.sh plugin handle multiple zones?

Posted: Mon Sep 28, 2015 8:17 am
by linuser
As some of you know, I have been working on the check_bind.sh plugin on a lab DNS server. Had a few issues and now seems all is good. However - my last problem revolved around the plugin returning zero values when it came across stats for multiple zones in the named.stats.tmp file. Like this:

Zone "1"

Code: Select all

[localhost.localdomain]
[155.168.192.in-addr.arpa]
                  16 queries resulted in NXDOMAIN
                  16 queries resulted in nxrrset
                  66 queries resulted in authoritative answer
                  34 queries resulted in successful answer
Zone "2"

Code: Select all

[testdns.net]
++ Zone Maintenance Statistics ++
                2167 queries caused recursion
               25707 queries resulted in NXDOMAIN
                   2 queries resulted in SERVFAIL
                 204 queries resulted in nxrrset
               52725 queries resulted in non authoritative answer
                  66 queries resulted in authoritative answer
               26880 queries resulted in successful answer
               51384 responses with EDNS(0) sent
               52793 responses sent
               51384 requests with EDNS(0) received
               52793 IPv4 requests received
I was able to modify the script to ignore the stats from "localhost.localdomain", but if having more than one zone on the DNS server breaks the plugin, what happens when you have hundreds of zones on your DNS server? This is how we have it in production and I can't move forward on this until I can find a solution that works.

Question 1:
Should the script be able to handle multiple zones and still parse out the correct info?

Question 2:
If so, what needs to happen to make this work?

Re: can check_bind.sh plugin handle multiple zones?

Posted: Mon Sep 28, 2015 3:44 pm
by tmcdonald
To be perfectly honest, I'm not 100% what the intended functionality is in this case - the original author (not us) hasn't released an upgrade since 2009 and this isn't one of the "standard" plugins we ship with XI. Grepping through the description and looking over the source I don't immediately see how multiple zones would be supported, so I don't really know what to say for what would need to be done to support it. I'll leave this thread open for further comment, but if it comes down to needing us to modify the script beyond a few simple tweaks, we would need to get the devs involved.

Re: can check_bind.sh plugin handle multiple zones?

Posted: Tue Sep 29, 2015 8:02 am
by linuser
Thanks, It would not be difficult to sum up the totals with simple command line editing of the file however scripting is not my strong-suit and having the ability to look at stats on a per zone basis, then graph those, would be a use case by many I'm sure.

Re: can check_bind.sh plugin handle multiple zones?

Posted: Wed Sep 30, 2015 9:14 am
by lgroschen
Not sure if this would be custom development or something that someone would take on. Might just have to open an internal task to see what kind of traction it gets.

Re: can check_bind.sh plugin handle multiple zones?

Posted: Thu Oct 01, 2015 8:21 am
by linuser
That would be great if we could take that approach or if someone would be willing to take this on. I have emailed the original author and have never received a reply.

Re: can check_bind.sh plugin handle multiple zones?

Posted: Thu Oct 01, 2015 1:42 pm
by lmiltchev
I created an internal feature request (TASK ID 6522).