Ad Widget

Collapse

Trigger does not fire when using the "Value mapping" mapped value

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Kapslok
    Junior Member
    • Jun 2025
    • 2

    #1

    Trigger does not fire when using the "Value mapping" mapped value

    Hi All.

    Appreciate if you could advise on the following:

    I am using the [net.tcp.port] key with a value mapping.

    This item key returns raw values: 0 - cannot connect; 1 - can connect.

    My value mapping is the following:
    *************************************
    1->Port available (OK)
    0->Port unavailable (Error)

    When I define the trigger problem as following:
    Problem expression: last(/myhost16/net.tcp.port[{$IP},{$PORT}])="Port unavailable (Error)"
    Then the trigger does not fire.

    When I check the item for latest values, my Zabbix shows the mapped value along with the raw one in round brackets:
    2025-06-27 08:16:56 PM Port unavailable (Error) (0)
    2025-06-27 08:15:56 PM Port unavailable (Error) (0)
    2025-06-27 08:14:56 PM Port unavailable (Error) (0)
    2025-06-27 08:13:56 PM Port unavailable (Error) (0)
    When I define the trigger problem statement with the mapped value concatenated with the raw:
    Problem expression: last(/myhost16/net.tcp.port[{$IP},{$PORT}])="Port unavailable (Error) (0)"
    ​Then the trigger does not fire too.

    So my question is - How should I define problem expression - by using the mapped key value, or by using the concatenation of the mapped key value with the raw one.

  • LenR
    Senior Member
    • Sep 2009
    • 1005

    #2
    You have to test for the 0, think of value mapping for human viewing only.

    Comment

    Working...