Ad Widget

Collapse

net.tcp.service.perf problem with SSH

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • kustodian
    Member
    • Oct 2012
    • 33

    #1

    net.tcp.service.perf problem with SSH

    Hi everyone! I'm a new user to Zabbix and I'm currently transitioning my Nagios checks to Zabbix. So far it's going great

    I stumbled upon one problem and that is with net.tcp.service.perf[service,<ip>,<port>]

    I set Zabbix Agent item to check performance of SSH like this:

    net.tcp.service.perf[ssh,,1022]

    The problem is that this item should return 0 if the service is down and number of seconds if it's up. But what happens if it takes 0 seconds to reach the SSH server, since it is accessed localy? How would Zabbix know if the service is up or down then? I made a trigger which looks like this:

    {Template OS Linux:net.tcp.service.perf[ssh,,1022].last(0)}=0

    And this trigger is always telling me that SSH is down and I know it is up. Wouldn't it be better if this item returned -1 if there is a problem with the service, or is there a better way to write this trigger?

    I also noticed that this item only works on the Zabbix Server which is running a Zabbix agent, it doesn't want to work on other servers with a Zabbix agent.

    Thanks in advance.
  • kustodian
    Member
    • Oct 2012
    • 33

    #2
    No one can help me out with this problem?

    Comment

    • mbsit
      Senior Member
      • Sep 2012
      • 130

      #3
      Hi
      First, if you are new, read the doc, please. Documentation of Zabbix is really great!

      So, the item: net.tcp.service.perf is not AGENT TYPE ! Is "Simple check". Read the doc what it mean.

      In your case, you should use different item, with key: net.tcp.service[service,<ip>,<port>] this item is checking if the service is up.

      0- means down
      1 - up

      If you would like to check SSH on another host, you should create that host and assign the key:

      net.tcp.service[ssh,{HOST.HOST}]

      Bests,
      Grzegorz

      --
      Wdrożenia Zabbix - Warszawa
      Pozdrawiam
      Grzegorz Grabowski
      ____
      WdroĊĵenia, szkolenia, umowy serwisowe
      Warszawa - Polska

      Comment

      • kustodian
        Member
        • Oct 2012
        • 33

        #4
        Originally posted by mbsit
        Hi
        First, if you are new, read the doc, please. Documentation of Zabbix is really great!

        So, the item: net.tcp.service.perf is not AGENT TYPE ! Is "Simple check". Read the doc what it mean.

        In your case, you should use different item, with key: net.tcp.service[service,<ip>,<port>] this item is checking if the service is up.

        0- means down
        1 - up

        If you would like to check SSH on another host, you should create that host and assign the key:

        net.tcp.service[ssh,{HOST.HOST}]

        Bests,
        Grzegorz

        --
        Wdrożenia Zabbix - Warszawa
        www.mbs-it.pl
        Thanks for you help, but I did read the documentation and I know the difference between simple checks and agent checks, but in the Zabbix Agent Item Type there is also net.tcp.service.perf defined, so I wanted to use that.

        Comment

        • cesarsj
          Senior Member
          • Dec 2018
          • 154

          #5

          Why net.tcp.service [ssh ,, 1022], net.tcp.service [ssh,{HOST}.{IP}, 1022], net.tcp.service [ssh, {HOST}.{HOST}, 1022] do not work, while net. does tcp.service [ssh, 192.168.100.99,1022] work?
          Last edited by cesarsj; 14-11-2019, 22:44.

          Comment

          • gofree
            Senior Member
            Zabbix Certified SpecialistZabbix Certified Professional
            • Dec 2017
            • 400

            #6
            its beacuse youre not reading documentation macros are in {} - so it should be {HOST.HOST} {HOST.IP}, to tired to look in to your first example - check with docu

            Comment


            • cesarsj
              cesarsj commented
              Editing a comment
              I had actually put {}, just as I edited the comment above. now that fix the detail worked. thanks.
          Working...