Ad Widget

Collapse

Compare key between two hosts

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • BigSmooth
    Member
    • Jun 2023
    • 46

    #1

    Compare key between two hosts

    Hello,

    Is there a way to compare a key between two hosts?

    I am trying to create a trigger when a new release of WildFly is out. I am able to create an HTTP agent and parse the download page to find latest release, but I don't want to run that for all WildFly servers in my environment. I would rather run it once, so I create a simple template associate to the Zabbix server, but then I can't compare.

    The trigger expression:
    last(/Software Version Check/wildfly.version.latest)<>last(/WildFly Server by JMX/jmx["jboss.as:management-root=server","productVersion"])

    Trigger "Not latest software installed" belongs to templates with different linkages.

    If I associate the template to all servers, it will get the info from WildFly website as many time as there are hosts.

    Any idea?

    Regards,
    Olivier
  • tim.mooney
    Senior Member
    • Dec 2012
    • 1427

    #2
    I think you're asking about "Aggregate calculations": https://www.zabbix.com/documentation...ated/aggregate

    Comment

    • BigSmooth
      Member
      • Jun 2023
      • 46

      #3
      I saw that option, but unfortunately, it does not fit:
      Only unsigned integer and float values (type of information) are supported for aggregate calculation items.

      Comment

      • Semiadmin
        Senior Member
        • Oct 2014
        • 1625

        #4
        As a crutch, you may create in the template "WildFly Server by JMX" the text calculated item with a formula
        Code:
        last(/Zabbix server/wildfly.version.latest)
        and use it in a trigger.

        Comment

        • BigSmooth
          Member
          • Jun 2023
          • 46

          #5
          I confirm it works by creating an item in the template which is actually copying data, or we can say "importing" into "WildFly Server by JMX" template scope.

          Next, expression of trigger is something like that:
          Code:
          last(/WildFly Server by JMX/wildfly.version.latest)<>last(/WildFly Server by JMX/jmx["jboss.as:management-root=server","productVersion"])

          Comment

          Working...