Ad Widget

Collapse

Cisco Switch monitor - add Alias to Title / Dashboard

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • shlomia
    Member
    • Jul 2020
    • 38

    #1

    Cisco Switch monitor - add Alias to Title / Dashboard

    Hello, I'm monitoring my Cisco Switch and I'm trying to show the alias of the interface when a problem occures.
    For example, I monitor Operational Status of interface 1/0/20 and the trigger is:

    Title: Operational Status - {#SNMPVALUE}
    Expression: last(/Template SNMP Cisco WS3750 - Custom 2/ifOperStatus[{#SNMPVALUE}])=2
    When a problem occur, I will only see the interface name in the title and not the alias.

    So, I added the following item to my template:
    Title: Alias of interface $1
    SNMP OID: .1.3.6.1.2.1.31.1.1.1.18.{#SNMPINDEX} - Returns the alias of the interface

    So now I can see the interface alias but, I don't know how to trigger the alias item when operational status triggers.. or for example, how to add the alias item to the operational status trigger title to see it on the dashboard or notification..

    I'm pretty lost on this one.. hopefully someone can give me a hint on this.
    Thanks
  • Answer selected by shlomia at 04-02-2022, 20:42.
    tikkami
    Member
    • May 2018
    • 71

    Yes, it's possible to edit LLD commands in templates.

    Actually there is suitable command in official Interfaces SNMP-template
    discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFALIAS},1.3.6.1.2.1.31.1.1.1.18,{#IFNAME},1.3.6.1.2.1.31.1.1.1.1,{#IFDESCR},1.3.6 .1.2.1.2.2.1.2,{#IFTYPE},1.3.6.1.2.1.2.2.1.3]

    I guess you are using Interfaces Simple SNMP -template.
    discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFNAME},1.3.6.1.2.1.2.2.1 .2,{#IFDESCR},1.3.6.1.2.1.2.2.1.2,{#IFTYPE},1.3.6. 1.2.1.2.2.1.3]

    Comment

    • tikkami
      Member
      • May 2018
      • 71

      #2
      You'll need to tune LLD command to assign correct oid to LLD-marco (like {#IFALIAS})

      Then {#IFALIAS} could be used in trigger prototype.

      Comment

      • shlomia
        Member
        • Jul 2020
        • 38

        #3
        Originally posted by tikkami
        You'll need to tune LLD command to assign correct oid to LLD-marco (like {#IFALIAS})

        Then {#IFALIAS} could be used in trigger prototype.
        Is it possible to edit / add LLD macros on existing template discovery rule?

        Comment

        • tikkami
          Member
          • May 2018
          • 71

          #4
          Yes, it's possible to edit LLD commands in templates.

          Actually there is suitable command in official Interfaces SNMP-template
          discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFALIAS},1.3.6.1.2.1.31.1.1.1.18,{#IFNAME},1.3.6.1.2.1.31.1.1.1.1,{#IFDESCR},1.3.6 .1.2.1.2.2.1.2,{#IFTYPE},1.3.6.1.2.1.2.2.1.3]

          I guess you are using Interfaces Simple SNMP -template.
          discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFNAME},1.3.6.1.2.1.2.2.1 .2,{#IFDESCR},1.3.6.1.2.1.2.2.1.2,{#IFTYPE},1.3.6. 1.2.1.2.2.1.3]

          Comment

          • shlomia
            Member
            • Jul 2020
            • 38

            #5
            Originally posted by tikkami
            Yes, it's possible to edit LLD commands in templates.

            Actually there is suitable command in official Interfaces SNMP-template
            discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFALIAS},1.3.6.1.2.1.31.1.1.1.18,{#IFNAME},1.3.6.1.2.1.31.1.1.1.1,{#IFDESCR},1.3.6 .1.2.1.2.2.1.2,{#IFTYPE},1.3.6.1.2.1.2.2.1.3]

            I guess you are using Interfaces Simple SNMP -template.
            discovery[{#IFOPERSTATUS},1.3.6.1.2.1.2.2.1.8,{#IFADMINSTATU S},1.3.6.1.2.1.2.2.1.7,{#IFNAME},1.3.6.1.2.1.2.2.1 .2,{#IFDESCR},1.3.6.1.2.1.2.2.1.2,{#IFTYPE},1.3.6. 1.2.1.2.2.1.3]
            Thank you so much.
            I actually used the simple one, my bad

            Comment

            Working...