Ad Widget

Collapse

Show "Host Group Elements" and Macro in label

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • alledm
    Member
    • May 2012
    • 84

    #1

    Show "Host Group Elements" and Macro in label

    Hello,

    I found the "Show Host group elements" very useful, and I am using it in a map I am creating.

    In the "Label" which will be next to each item in the group, I tend to put "{HOST.HOST}" or equivalent. This is fine, but includes the domain name as well, which is rather annoying.

    Basically I would prefer server1 to server1.domainname.com, which is just a repetition for me.

    I could not find anything helpful in the macro, so I decided to create an item that gets the output of "hostname -s"

    This is giving me an item with the correct value, but now I cannot have it visualised on the map.

    The "simple macro" "{host:key.func(param)}" would be awesome IF it wasn't for the fact that I cannot seem to have it working from a generic "Host Group Element" Label, which does not reference a host in particular

    Is ther something like {{HOST.NAME}:key.func(param)} available? Something like a double expansion?

    Regards
    Alessandro
  • richlv
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Oct 2005
    • 3112

    #2
    try {{HOST.HOST}:key.func(param)}
    Zabbix 3.0 Network Monitoring book

    Comment

    • alledm
      Member
      • May 2012
      • 84

      #3
      Thank you it works.

      Comment

      Working...