Ad Widget

Collapse

User Macro substitution at Web Scenario

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • markfree
    Senior Member
    • Apr 2019
    • 868

    #1

    User Macro substitution at Web Scenario

    Zabbix 6.2

    In a template, I have a user macro for Web scenarios that I monitor.
    Code:
    {$WEB_SERVICE} = HTTP or HTTPS
    I've added this macro to the scenario name, step name and step URL.
    Click image for larger version  Name:	image.png Views:	0 Size:	5.4 KB ID:	459701

    Click image for larger version  Name:	image.png Views:	0 Size:	8.1 KB ID:	459700

    Now, Zabbix is collecting data correctly with this macro.

    However, at host level, Latest Data shows the Web Scenario items with the macro name instead of its value. The same for the step name.
    Only the web item keys are showing the actual macro value.
    Click image for larger version  Name:	image.png Views:	0 Size:	24.1 KB ID:	459698

    Click image for larger version  Name:	image.png Views:	0 Size:	33.3 KB ID:	459699

    I was under the impression that this macro would be substituted at the host level, but it was not.
    Any tips on that?​
    Last edited by markfree; 17-02-2023, 22:42.
  • Hamardaban
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • May 2019
    • 2713

    #2
    Custom macros are no longer supported in the naming of items.
    You can use lld to create items titles with the desired text.

    Comment

    • markfree
      Senior Member
      • Apr 2019
      • 868

      #3
      Thanks, Hamardaban .
      Unfortunately, there are no Web Scenario prototypes.

      Comment

      Working...