Bind 9.6 - DNS statistics
Moderators: Developers, Moderators
Re: Bind 9.6 - DNS statistics
hi niobe,
if my cacti and bind in same the server/machine.
can i run the scripts without ssh ? how ?
if my cacti and bind in same the server/machine.
can i run the scripts without ssh ? how ?
Re: Bind 9.6 - DNS statistics
Well you can modify the script to skip the ssh part (comment the GET FILE section)
But there's no reason your box can't ssh to itself.
But there's no reason your box can't ssh to itself.
Aruba MC: http://forums.cacti.net/viewtopic.php?f=12&t=42282
Bind 9.6 stats: http://forums.cacti.net/viewtopic.php?f ... 18&start=0
Cisco VLAN Stats: forums.cacti.net/viewtopic.php?t=26800
DHCPD stats: http://forums.cacti.net/viewtopic.php?f ... 5&p=208792
Enterasys CPU: http://forums.cacti.net/viewtopic.php?f=12&t=42279
F5 BigIP v10: http://forums.cacti.net/viewtopic.php?f=12&t=47429
Re: Bind 9.6 - DNS statistics
I intalled all packages and scripts.
The Graphs are works well but numerical value are different between graph and result of command "tclsh bind96-stats.tcl -h <name_server_ip> -u <remote_ssh_user> -r in"
graphs are indicated : "27"
result of command : "TOTAL_QUERIES:354306"
how can i fix it?
thanks regards.
The Graphs are works well but numerical value are different between graph and result of command "tclsh bind96-stats.tcl -h <name_server_ip> -u <remote_ssh_user> -r in"
graphs are indicated : "27"
result of command : "TOTAL_QUERIES:354306"
how can i fix it?
thanks regards.
Re: Bind 9.6 - DNS statistics
in case of bind 9.8 or higher, graphs are looks like stack.
Every setting is same as bind 9.6 system.
Is it not working at bind 9.8? or how can i fix it?
PLZ help~
Every setting is same as bind 9.6 system.
Is it not working at bind 9.8? or how can i fix it?
PLZ help~
Re: Bind 9.6 - DNS statistics
Do this script work with Bind9.2 ?
Re: Bind 9.6 - DNS statistics
Is there a possibility to use this plugin with SNMP?
Re: Bind 9.6 - DNS statistics
Having issues getting the graphs to work on this, running BIND 9.6.2-P2, graphs are all just NaN for all 3.
No errors in cacti log (anymore, was empty result then they disappeared), running the script manually gives proper responses.
tclsh bind96-stats.tcl -u poller -h ddns -r in
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 QUERIES_IN_A:13581768 QUERIES_IN_PTR:1370 QUERIES_IN_MX:6062994 QUERIES_IN_AAAA:6066960
tclsh bind96-stats.tcl -u poller -h ddns -r out
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 QUERIES_OUT_A:5492 QUERIES_OUT_PTR:347 QUERIES_OUT_MX:92 QUERIES_OUT_AAAA:1895
tclsh bind96-stats.tcl -u poller -h ddns -r misc
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 REQUESTS_RCVD_IPV4:25717157 RESPONSES_SENT:25717153 ANSWERED_SUCCESS:13329833 ANSWERED_AUTH:20941979 ANSWERED_NONAUTH:4771073 ANSWERED_NXRRSET:12127885 ANSWERED_SERVFAIL:19 ANSWERED_NXDOMAIN:255334 CAUSED_RECURSION:4856 DUPLICATE_QUERIES:4 OTHER_FAILURES:17 QUERIES_OUT_IPV4:7479 QUERIES_OUT_IPV6:361 RESPONSES_IN_IPV4:7380 CONNS_EST_IPV4:7479
No errors in cacti log (anymore, was empty result then they disappeared), running the script manually gives proper responses.
tclsh bind96-stats.tcl -u poller -h ddns -r in
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 QUERIES_IN_A:13581768 QUERIES_IN_PTR:1370 QUERIES_IN_MX:6062994 QUERIES_IN_AAAA:6066960
tclsh bind96-stats.tcl -u poller -h ddns -r out
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 QUERIES_OUT_A:5492 QUERIES_OUT_PTR:347 QUERIES_OUT_MX:92 QUERIES_OUT_AAAA:1895
tclsh bind96-stats.tcl -u poller -h ddns -r misc
TOTAL_QUERIES:25713092 TOTAL_NOTIFIES:4065 REQUESTS_RCVD_IPV4:25717157 RESPONSES_SENT:25717153 ANSWERED_SUCCESS:13329833 ANSWERED_AUTH:20941979 ANSWERED_NONAUTH:4771073 ANSWERED_NXRRSET:12127885 ANSWERED_SERVFAIL:19 ANSWERED_NXDOMAIN:255334 CAUSED_RECURSION:4856 DUPLICATE_QUERIES:4 OTHER_FAILURES:17 QUERIES_OUT_IPV4:7479 QUERIES_OUT_IPV6:361 RESPONSES_IN_IPV4:7380 CONNS_EST_IPV4:7479
Re: Bind 9.6 - DNS statistics
Dear all,
i have same problem. my bind version is 9.8-p1.
i have same problem. my bind version is 9.8-p1.
Thanks and Regards,
Rito
Rito
Re: Bind 9.6 - DNS statistics
Hey Guys,
This is an awesome script, however...
My graphs show nan
My cmd.php shows the results, Which is good....
Not sure what else I need to do? :/
I've had to edit the .tcl script slightly to get the file across, however, I doubt that would cause this problem?
If you need any more info... Let me know
Regards,
Matt
This is an awesome script, however...
My graphs show nan
Code: Select all
01/07/2012 02:48:59 AM - CMDPHP: Poller[0] Host[4] DS[68] CMD: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h fr-01.get-sourced.net -u root -r misc, output: TOTAL_QUERIES:249418 REQUESTS_RCVD_IPV4:249418 RESPONSES_SENT:249418 ANSWERED_SUCCESS:165850 ANSWERED_AUTH:128298 ANSWERED_NONAUTH:105028 ANSWERED_NXRRSET:46836 ANSWERED_SERVFAIL:865 ANSWERED_NXDOMAIN:20640 CAUSED_RECURSION:25027 OTHER_FAILURES:15226 QUERIES_OUT_IPV4:123095 QUERIES_OUT_IPV6:21490 RESPONSES_IN_IPV4:119332 CONNS_EST_IPV4:122890 CONNS_EST_IPV6:21490
01/07/2012 02:49:00 AM - CMDPHP: Poller[0] Host[4] DS[69] CMD: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h fr-01.get-sourced.net -u root -r in, output: TOTAL_QUERIES:249418 QUERIES_IN_A:138031 QUERIES_IN_NS:1422 QUERIES_IN_CNAME:14 QUERIES_IN_SOA:43 QUERIES_IN_PTR:40273 QUERIES_IN_MX:2035 QUERIES_IN_TXT:1730 QUERIES_IN_AAAA:49379 QUERIES_IN_SRV:33 QUERIES_IN_A6:346 QUERIES_IN_AXFR:1 QUERIES_IN_ANY:15583
01/07/2012 02:49:00 AM - CMDPHP: Poller[0] Host[4] DS[70] CMD: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h fr-01.get-sourced.net -u root -r out, output: TOTAL_QUERIES:249418 QUERIES_OUT_A:63926 QUERIES_OUT_PTR:22385 QUERIES_OUT_MX:1226 QUERIES_OUT_TXT:1500 QUERIES_OUT_AAAA:54634 QUERIES_OUT_SPF:368
Not sure what else I need to do? :/
I've had to edit the .tcl script slightly to get the file across, however, I doubt that would cause this problem?
If you need any more info... Let me know
Regards,
Matt
-
- Posts: 9
- Joined: Mon Jul 16, 2012 1:58 pm
Re: Bind 9.6 - DNS statistics
edit: read the last edit at the bottom - nothing to see here/move along. I'd delete this post but there doesn't seem to be a way (and who knows, this might be useful to some other coffee-deprived individual in the future.
----
Hi niobe,
I have your script set up and working fine -- but only when I run it manually as our cacti user (www-data):
www-data@allops:~$ tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h reston-commell.[redacted].com -u cacti -r misc
/usr/bin/scp -p cacti@reston-commell.[redacted].com:/var/named/var/stats/named.stats /var/lib/cacti/bind96/named.stats.reston-commell.[redacted].com
TOTAL_QUERIES:9321781 TOTAL_NOTIFIES:95 REQUESTS_RCVD_IPV4:8859082 RESPONSES_SENT:9319170 ANSWERED_SUCCESS:7387794 ANSWERED_AUTH:6749622 ANSWERED_NONAUTH:1716250 ANSWERED_REFERRAL:36 ANSWERED_NXRRSET:205872 ANSWERED_SERVFAIL:6304 ANSWERED_NXDOMAIN:872170 CAUSED_RECURSION:525033 DUPLICATE_QUERIES:2688 DROPPED_QUERIES:13 OTHER_FAILURES:846871 QUERIES_OUT_IPV4:860137 QUERIES_OUT_IPV6:164551 RESPONSES_IN_IPV4:833011 RESPONSES_IN_IPV6:160381 CONNS_EST_IPV4:859992 CONNS_EST_IPV6:164331
www-data@allops:~$
But you can see that when the cacti poller runs (as www-data, 0.8.7i), it says the output is just U:
09/11/2012 01:25:07 PM - SPINE: Poller[0] Host[13] TH[1] DS[673] SCRIPT: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h reston-commell.[redacted].com -u cacti -r misc, output: U
Can you provide any input on why this may be happening? It clearly is not a permissions, format or similar issue since running it manually as the same user works exactly as expected
edit:
just to make sure it wasn't a $PATH issue, I replcaed tclsh with /usr/bin/tclsh (which I now see it shouldn't have been, since I see the logins to the remote server). What is interesting is that cacti reports the output as U if there is one of a few types of issues, such as if I specify /usr/bin/tclah or some other junk interpreter. So I suspect the U in this case means undefined in the sense that there is a non-zero exit code from the shell and/or interpreter, and no usable output. Next I'll tinker with the TCL (which I am otherwise not familiar with) and see about getting it to spit out some more debug info to a file as it executes.
I see the file being copied locally just fine.
edit again:
nope, it's executing 100% fine. I added a snippet to the end of the tcl to write some information out to another file, and sure enough I see this just fine:
puts $f "here are the results:"
puts $f [string trim [concat $resultsGeneral $resultsIn $resultsOut $resultsMisc]]
puts [string trim [concat $resultsGeneral $resultsIn $resultsOut $resultsMisc]]
yields this in the file:
here are the results:
TOTAL_QUERIES:9389625 TOTAL_NOTIFIES:95 REQUESTS_RCVD_IPV4:8924559 RESPONSES_SENT:9387001 ANSWERED_SUCCESS:7444275 ANSWERED_AUTH:6801039 ANSWERED_NONAUTH:1729709 ANSWERED_REFERRAL:36 ANSWERED_NXRRSET:207178 ANSWERED_SERVFAIL:6352 ANSWERED_NXDOMAIN:879259 CAUSED_RECURSION:530312 DUPLICATE_QUERIES:2702 DROPPED_QUERIES:13 OTHER_FAILURES:849778 QUERIES_OUT_IPV4:867684 QUERIES_OUT_IPV6:165919 RESPONSES_IN_IPV4:840422 RESPONSES_IN_IPV6:161685 CONNS_EST_IPV4:867539 CONNS_EST_IPV6:165699
Now I'm out of ideas, since it appears to be running and exiting normally.
edit: well that was a colossal waste of time. As you can see, I had previously edited the tcl script to print out the scp command being used (because, like the previous poster, I had separate problems with it that I needed to hack around). I completely forgot to take that out, so of course cacti exploded. Good thing I didn't waste anyone's time with this thread!
----
Hi niobe,
I have your script set up and working fine -- but only when I run it manually as our cacti user (www-data):
www-data@allops:~$ tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h reston-commell.[redacted].com -u cacti -r misc
/usr/bin/scp -p cacti@reston-commell.[redacted].com:/var/named/var/stats/named.stats /var/lib/cacti/bind96/named.stats.reston-commell.[redacted].com
TOTAL_QUERIES:9321781 TOTAL_NOTIFIES:95 REQUESTS_RCVD_IPV4:8859082 RESPONSES_SENT:9319170 ANSWERED_SUCCESS:7387794 ANSWERED_AUTH:6749622 ANSWERED_NONAUTH:1716250 ANSWERED_REFERRAL:36 ANSWERED_NXRRSET:205872 ANSWERED_SERVFAIL:6304 ANSWERED_NXDOMAIN:872170 CAUSED_RECURSION:525033 DUPLICATE_QUERIES:2688 DROPPED_QUERIES:13 OTHER_FAILURES:846871 QUERIES_OUT_IPV4:860137 QUERIES_OUT_IPV6:164551 RESPONSES_IN_IPV4:833011 RESPONSES_IN_IPV6:160381 CONNS_EST_IPV4:859992 CONNS_EST_IPV6:164331
www-data@allops:~$
But you can see that when the cacti poller runs (as www-data, 0.8.7i), it says the output is just U:
09/11/2012 01:25:07 PM - SPINE: Poller[0] Host[13] TH[1] DS[673] SCRIPT: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h reston-commell.[redacted].com -u cacti -r misc, output: U
Can you provide any input on why this may be happening? It clearly is not a permissions, format or similar issue since running it manually as the same user works exactly as expected
edit:
just to make sure it wasn't a $PATH issue, I replcaed tclsh with /usr/bin/tclsh (which I now see it shouldn't have been, since I see the logins to the remote server). What is interesting is that cacti reports the output as U if there is one of a few types of issues, such as if I specify /usr/bin/tclah or some other junk interpreter. So I suspect the U in this case means undefined in the sense that there is a non-zero exit code from the shell and/or interpreter, and no usable output. Next I'll tinker with the TCL (which I am otherwise not familiar with) and see about getting it to spit out some more debug info to a file as it executes.
I see the file being copied locally just fine.
edit again:
nope, it's executing 100% fine. I added a snippet to the end of the tcl to write some information out to another file, and sure enough I see this just fine:
puts $f "here are the results:"
puts $f [string trim [concat $resultsGeneral $resultsIn $resultsOut $resultsMisc]]
puts [string trim [concat $resultsGeneral $resultsIn $resultsOut $resultsMisc]]
yields this in the file:
here are the results:
TOTAL_QUERIES:9389625 TOTAL_NOTIFIES:95 REQUESTS_RCVD_IPV4:8924559 RESPONSES_SENT:9387001 ANSWERED_SUCCESS:7444275 ANSWERED_AUTH:6801039 ANSWERED_NONAUTH:1729709 ANSWERED_REFERRAL:36 ANSWERED_NXRRSET:207178 ANSWERED_SERVFAIL:6352 ANSWERED_NXDOMAIN:879259 CAUSED_RECURSION:530312 DUPLICATE_QUERIES:2702 DROPPED_QUERIES:13 OTHER_FAILURES:849778 QUERIES_OUT_IPV4:867684 QUERIES_OUT_IPV6:165919 RESPONSES_IN_IPV4:840422 RESPONSES_IN_IPV6:161685 CONNS_EST_IPV4:867539 CONNS_EST_IPV6:165699
Now I'm out of ideas, since it appears to be running and exiting normally.
edit: well that was a colossal waste of time. As you can see, I had previously edited the tcl script to print out the scp command being used (because, like the previous poster, I had separate problems with it that I needed to hack around). I completely forgot to take that out, so of course cacti exploded. Good thing I didn't waste anyone's time with this thread!
-
- Posts: 13
- Joined: Wed Mar 13, 2013 10:57 am
- Location: Nicaragua
Re: Bind 9.6 - DNS statistics
Hello, any update for this problem with BIND 9.6...??
My version of BIND is: bind-9.8.2-0.17.rc1.el6_4.6.x86_64
[root@cns01]# tclsh bind96-stats.tcl -h 192.168.8.37 -u root -r misc
TOTAL_QUERIES:316 RESPONSES_SENT:313 ANSWERED_SUCCESS:220 ANSWERED_NONAUTH:313 ANSWERED_NXRRSET:59 ANSWERED_NXDOMAIN:34 CAUSED_RECURSION:283 DUPLICATE_QUERIES:3 QUERIES_OUT_IPV4:459 RESPONSES_IN_IPV4:458 CONNS_EST_IPV4:459
but cacti log show:
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[18] Graphs['CentOS - Bind 9.6 Stats - Incoming Queries'] CMD: tclsh /var/www/html/cacti-0.8.8b/scripts/bind96-stats.tcl -h 127.0.0.1 -u root -r in, output: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[18] Graphs['CentOS - Bind 9.6 Stats - Incoming Queries'] WARNING: Result from CMD not valid. Partial Result: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[17] Graphs['CentOS - Bind 9.6 Stats - Answered Queries'] CMD: tclsh /var/www/html/cacti-0.8.8b/scripts/bind96-stats.tcl -h 127.0.0.1 -u root -r misc, output: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[17] Graphs['CentOS - Bind 9.6 Stats - Answered Queries'] WARNING: Result from CMD not valid. Partial Result: U
thankyou!!:.
My version of BIND is: bind-9.8.2-0.17.rc1.el6_4.6.x86_64
[root@cns01]# tclsh bind96-stats.tcl -h 192.168.8.37 -u root -r misc
TOTAL_QUERIES:316 RESPONSES_SENT:313 ANSWERED_SUCCESS:220 ANSWERED_NONAUTH:313 ANSWERED_NXRRSET:59 ANSWERED_NXDOMAIN:34 CAUSED_RECURSION:283 DUPLICATE_QUERIES:3 QUERIES_OUT_IPV4:459 RESPONSES_IN_IPV4:458 CONNS_EST_IPV4:459
but cacti log show:
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[18] Graphs['CentOS - Bind 9.6 Stats - Incoming Queries'] CMD: tclsh /var/www/html/cacti-0.8.8b/scripts/bind96-stats.tcl -h 127.0.0.1 -u root -r in, output: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[18] Graphs['CentOS - Bind 9.6 Stats - Incoming Queries'] WARNING: Result from CMD not valid. Partial Result: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[17] Graphs['CentOS - Bind 9.6 Stats - Answered Queries'] CMD: tclsh /var/www/html/cacti-0.8.8b/scripts/bind96-stats.tcl -h 127.0.0.1 -u root -r misc, output: U
11/06/2013 09:19:02 PM - CMDPHP: Poller[0] Host[3] Description[CentOS] DS[17] Graphs['CentOS - Bind 9.6 Stats - Answered Queries'] WARNING: Result from CMD not valid. Partial Result: U
thankyou!!:.
Kevin Morales
-
- Posts: 13
- Joined: Wed Mar 13, 2013 10:57 am
- Location: Nicaragua
Re: Bind 9.6 - DNS statistics
Hello
I already solved the problem. was by permission. but now I have the following problem. The values are not updated!..
I already solved the problem. was by permission. but now I have the following problem. The values are not updated!..
- Attachments
-
- Captura.PNG (49.1 KiB) Viewed 4572 times
Kevin Morales
Re: Bind 9.6 - DNS statistics
Hello niobe,
I have problem when deploying your dns template in cacti. I try deploy your template in ubuntu.
I already follow your step, until step 4 (test script manually) my machine works fine, and result same like step 5
but, in my cacti log, all graph show NAN and when open from console log, there's some error
can you help me to solve this problem ? I already restart server (bind & cacti), make public ssh key, do manual test, restart poller cache, restart bind server, make sure "rndc stats" file was there, but none of above make some progress
Thank you in advanced
I have problem when deploying your dns template in cacti. I try deploy your template in ubuntu.
I already follow your step, until step 4 (test script manually) my machine works fine, and result same like step 5
Code: Select all
QUERIES_OUT_IPV4:65 QUERIES_OUT_IPV6:9 RESPONSES_IN_IPV4:55 CONNS_EST_IPV4:65
Code: Select all
04/21/2015 01:55:16 PM - SPINE: Poller[0] Host[48] ERROR: Empty result [172.16.0.52]: 'tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r misc'
04/21/2015 01:55:16 PM - SPINE: Poller[0] Host[48] TH[1] DS[819] SCRIPT: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r misc, output: U
04/21/2015 01:55:17 PM - SPINE: Poller[0] Host[48] ERROR: Empty result [172.16.0.52]: 'tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r in'
04/21/2015 01:55:17 PM - SPINE: Poller[0] Host[48] TH[1] DS[820] SCRIPT: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r in, output: U
04/21/2015 01:55:17 PM - SPINE: Poller[0] Host[48] ERROR: Empty result [172.16.0.52]: 'tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r out'
04/21/2015 01:55:17 PM - SPINE: Poller[0] Host[48] TH[1] DS[821] SCRIPT: tclsh /usr/share/cacti/site/scripts/bind96-stats.tcl -h 172.16.0.52 -u root -r out, output: U
Thank you in advanced
Who is online
Users browsing this forum: No registered users and 0 guests