Ad Widget

Collapse

Assp

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • frater
    Senior Member
    • Oct 2010
    • 340

    #1

    Assp

    I wasn't able to get the perl script to work that was posted on this forum, so I tried to find out what was going on. I read the perl-script to see what it was doing and I decided to write the whole thing from scratch in bash.

    I took a lot of ideas from the original script, but there are many new ones in my implementation.
    Thanks bmcclure for all the ideas...



    some major differences:
    • all bash
    • can take a file with several assp's to test
    • can create the XML-file using the data it gets from ASSP
    • only needs the 'KEYS' that need special handling (CPU average)
    • works for old and for new zabbix_sender syntax (senderver18=1)

    needs:
    • curl
    • host


    The reason why I couldn't get the original script working was probably not the fault of his script but was due to my setup....

    Usage:
    Create a cronjob where you call the script and give it the zabbix-server
    Code:
    #!/bin/bash
    /usr/local/sbin/assp2zabbix $* 83.130.131.231 10051
    Create a file /etc/assp2zabbix.conf where you put all the ASSP's you want to check.
    Code:
    assp1 83.130.131.240 55553
    assp2 83.130.131.241 55553
    assp3 83.130.131.242 55553
    assp4 83.130.131.243 55553
    assp5 83.130.131.244 55553
    assp2zabbix -x <assp>
    will create a file assp_stat.xml in your home directory
    Attached Files
    Last edited by frater; 14-10-2010, 17:08.
    Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP
  • frater
    Senior Member
    • Oct 2010
    • 340

    #2
    By default ASSP only allows a connection from 127.0.0.1.
    If you use curl http://192.168.1.100:55553 for instance, it will come up empty even if you call it from the same machine.

    In the previous version this was already been handled, but I forgot to do the same when creating the XML. This has now been changed.

    If you ask ASSP from the same machine it will use localhost as its source interface.

    I just did a fresh install of zabbix at home and could get it to work with this script. I did bump into this bug, so use this version.....
    Attached Files
    Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

    Comment

    • frater
      Senior Member
      • Oct 2010
      • 340

      #3
      Another update...

      I would like to get some feedback and am also very interested in graphs/triggers you may make...
      Attached Files
      Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

      Comment

      • deadmhz
        Junior Member
        • Nov 2008
        • 2

        #4
        Looks Good

        Found your script over 2 years later.

        Seems to work good on Zabbix 2.0.4.

        It has only been running for about 30 minutes. I'll try out some graphs and stuff after I get some more data collected.

        Thank you very much!

        Comment

        • zerocool
          Member
          Zabbix Certified Specialist
          • Jul 2007
          • 33

          #5
          Proxy Mode

          Hello,

          is there a way to get the same info in proxy mode?
          Thanks for support..

          Comment

          • deadmhz
            Junior Member
            • Nov 2008
            • 2

            #6
            It should

            Since it is giving Zabbix Agent the data, it should just pass it through to the proxy and on to the Zabbix server.

            Comment

            • zerocool
              Member
              Zabbix Certified Specialist
              • Jul 2007
              • 33

              #7
              but should it is not

              was what I thought as well, but once imported the template generated with the "-x" parameter and executed the script does not receive the proxy and therefore does not send anything to the zabbix server and various items must be immediately "not supported"

              Comment

              Working...