Ad Widget

Collapse

template_bind_stat: does it work for you?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • troffasky
    Senior Member
    • Jul 2008
    • 567

    #1

    template_bind_stat: does it work for you?


    bind 9.18

    Agent configured per:



    But none of the statistics work. Every parameter is returned as "null".

    # zabbix_get -k bind.queries.jq[cache,A,http://127.0.0.1:8053/json] -s dnsserver
    null

    No error in agent log.

    If we break down an item...

    UserParameter=bind.queries.jq[*],curl $3 2>/dev/null | jq ".$1.$2"

    Test on server:

    # curl http://127.0.0.1:8053/json 2>/dev/null | jq ".cache.A"
    null

    So agent returns exactly what command outputs. Fine.
    So command must be wrong. What is the correct command?
  • troffasky
    Senior Member
    • Jul 2008
    • 567

    #2
    Don't know where I got cache,A from, that is not an item in this template. QryAuthAns is one of them, and it doesn't even exist in the JSON stats output! So no change to how this is queried will make that appear.

    Comment

    • troffasky
      Senior Member
      • Jul 2008
      • 567

      #3
      I guess I might have misunderstood how this worked. The JSON output was massive so there were loads of parameters available to monitor.
      But the parameters in the Zabbix template seem to have started working the moment I pointed some live traffic at this DNS server! So looks like some fields are not even present until the values are non-zero. Not what I was expecting.

      This appeared after server is serving live requests:
      # curl http://127.0.0.1:8053/json 2>/dev/null | grep QryAuthAns -i
      "QryAuthAns":1,


      And yet there are still hundreds of parameters with 0 values, which do appear. Go figure!

      # curl http://127.0.0.1:8053/json 2>/dev/null | egrep ':0$|:0,$' | wc -l
      359

      Comment

      Working...