You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was receiving an empty result when using bind-stats.py with discoverzones parameter (stats version 2). I used 'wget -O - http://localhost:8654 | xml2' to debug and realized that it was needed to comment line 79 of the code to achieve the proper result.
77 if version == 2: 78 for view in root.iterfind('./bind/statistics/views/view'): 79 # if view.findtext('./name') in ('_default',): 80 for zone in view.iterfind('./zones/zone'): 81 if zone.find('./counters') is not None: 82 counters = {} 83 for counter in zone.iterfind('./counters/*'): 84 counters[counter.tag] = counter.text 85 j['zones'][zone.findtext('./name')] = counters
Now I'm wondering in which case this line was needed.
Version and build parameters:
named -V
BIND 9.8.4-rpz2+rl005.12-P1 built with '--prefix=/usr' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--sysconfdir=/etc/bind' '--localstatedir=/var' '--enable-threads' '--enable-largefile' '--with-libtool' '--enable-shared' '--enable-static' '--with-openssl=/usr' '--with-gssapi=/usr' '--with-gnu-ld' '--with-geoip=/usr' '--enable-ipv6' 'CFLAGS=-fno-strict-aliasing -DDIG_SIGCHASE -O2'
using OpenSSL version: OpenSSL 1.0.1e 11 Feb 2013
using libxml2 version: 2.8.0
The text was updated successfully, but these errors were encountered:
I was receiving an empty result when using bind-stats.py with discoverzones parameter (stats version 2). I used 'wget -O - http://localhost:8654 | xml2' to debug and realized that it was needed to comment line 79 of the code to achieve the proper result.
77 if version == 2:
78 for view in root.iterfind('./bind/statistics/views/view'):
79 # if view.findtext('./name') in ('_default',):
80 for zone in view.iterfind('./zones/zone'):
81 if zone.find('./counters') is not None:
82 counters = {}
83 for counter in zone.iterfind('./counters/*'):
84 counters[counter.tag] = counter.text
85 j['zones'][zone.findtext('./name')] = counters
Now I'm wondering in which case this line was needed.
Version and build parameters:
The text was updated successfully, but these errors were encountered: