Ad Widget

Collapse

Smokeping replacement?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • abjornson
    Member
    • Oct 2013
    • 34

    #46
    One other question - default behavior of the "real" smokeping sends 20 pings in 5 minutes.

    It seems like since timeout is limited to 30 seconds in the zabbix server config, it wouldn't be possible to replicate this...correct?

    Comment

    • adg
      Junior Member
      • Sep 2012
      • 17

      #47
      Moved server

      I've moved to a new server, and update Zabbix to 2.4.5 on Ubuntu LTS 14

      The config has been moved, however, the script doesn't work on the new server.

      I get a timeout issue, however, the timeout value in zabbix_server.conf matches the working one, at 30 seconds.

      user@monitoring:/usr/lib/zabbix/externalscripts$ ./zbxsmokepingprimary 127.0.0.1 6 1000 68 127.0.0.1
      fping -b 68 -c 6 -q -p 1000 127.0.0.1
      zabbix_sender [9665]: Warning: timeout while executing operation
      zabbix_sender [9917]: Warning: timeout while executing operation
      zabbix_sender [10082]: Warning: timeout while executing operation

      Anyone had a similar issue?

      Comment

      • ApolloDS
        Junior Member
        • Dec 2010
        • 11

        #48
        Hi adg,
        It seems that the zabbix_sender cannot send the data to the zabbix server.
        I have everything running with 2.4.5 on LTS 14.04.

        Maybe you see more when you enable debugging in the script?

        Comment

        • mbsit
          Senior Member
          • Sep 2012
          • 130

          #49
          I don't know you have my version or modified one but in the script you have to set IP of new zabbix server:

          ...
          #!/bin/bash
          # Where is your zabbix server
          ZBXSERVER=127.0.0.1 <-
          ...
          Pozdrawiam
          Grzegorz Grabowski
          ____
          WdroĊĵenia, szkolenia, umowy serwisowe
          Warszawa - Polska

          Comment

          • ursal
            Junior Member
            • Jul 2015
            • 1

            #50
            Hi!
            Made some changes is script on my Ubuntu 14.04, zabbix 2.2.2
            Quotes on Hostname variable for hostnames with spaces and grep "failed: 1" instead of "Failed 1", because of different zabbix output format

            $ZBXSENDER -z $ZBXSERVER -p 10051 -s "$HOSTNAME" -k SmokePingLoss -o ${tab[0]} -v | grep "failed: 1"



            You can also use
            #!/bin/bash
            # show all command before execution
            #set -x #echo on
            for command execution debugging

            Comment

            • midnight_man
              Junior Member
              • Mar 2016
              • 11

              #51
              Hi guys,

              I still cant make this template working. I have both templates and scripts which are here in this thread.

              I changed timeout in server config to 12ms
              Edit IP in script
              edit fping path to usr/bin/fping

              maybe need edit path for zabbix sender? ( I have zabbix 3.2)

              still NO DATA in graph

              thanks

              Comment

              • sles
                Member
                • Oct 2005
                • 80

                #52
                Hello!

                Just found this thread.
                I don't think script and template here is smokeping replacement-
                smokeping shows you not only min/average/max delay , it really shows each ping, main advantage of smokeping is how it graphically displays data.
                Could you tell me is it really possible to replace smokeping ?

                Thank you!

                Comment

                • pkowal
                  Junior Member
                  • May 2018
                  • 1

                  #53
                  Just in case anyone needs to use fping to gather information longer than 30 seconds in zabbix 3.x (which is the max value for zabbix external script timeout).

                  Create bash script as a wrapper to spawn a child process:

                  exec zbxsmokeping "$@" &

                  Don't forget to close stdout and stderr in zbxsmokeping before launching fping:

                  exec 1>&-
                  exec 2>&-

                  This should make the wrapper exit instantly, and trapper collect the data.

                  Comment

                  • cserf
                    Junior Member
                    • Mar 2014
                    • 2

                    #54
                    Zabbix 4.0.0

                    What variable is to be used in Primary Smoke Indicator to properly indicate the name of monitored host in zabbix:
                    When using host.host:
                    zbxsmokepingprimary[{$PRIMARYIP},6,1000,68,{HOST.HOST}]
                    zabbix shows the items
                    PrimaryLatencyAvg, PrimaryLatencyMaxPrimaryLatencyMin,PrimaryLoss
                    as unsupported and comment is ' Value "-v" of type "string" is not suitable for value type "Numeric (float)" '

                    When I put HOST.NAME or something different it shows all items supported but no data on graph

                    using shell command
                    ./zbxsmokepingprimary 192.168.1.10 6 1000 68 NameOfHostInZabbix
                    works perfectly - puts data to the graph

                    Rafal

                    Comment

                    Working...