Hi!
I'm using Zabbix 6.0 with template Net Cisco IOS SNMP for monitoring Cisco Catalyst 4500 platform.
I need remove of unnecessary items, for example:

Because I have too much vlan interfaces on this switch:

I need monitoring interfaces, such as TenGigabitEthernet, GigabitEthernet, Port-channel.
I created regex for filtering Vlan interfaces and I used several ways to set it:
1. Template Net Cisco IOS SNMP -> Macros
{$NET.IF.IFNAME.NOT_MATCHES} add ^*Interface VLAN*$
(^Software Loopback Interface|^NULL[0-9.]*$|^[Ll]o[0-9.]*$|^[Ss]ystem$|^Nu[0-9.]*$|^veth[0-9a-z]+$|docker[0-9]+|br-[a-z0-9]{12}|^*Interface VLAN*$)
2. Template Net Cisco IOS SNMP -> Macros
{$NET.IF.IFNAME.MATCHES} I changed the value of ^.*$ to (^TenGigabitEthernet1/[1-8]$|^GigabitEthernet2/[1-9]$|^GigabitEthernet2/[1-2][0-9]$|^Port-channel*$)
3. Host -> Discovery -> Template Module Interfaces SNMP: Network interfaces discovery -> Filters
{#SNMPVALUE} matches (^TenGigabitEthernet1/[1-8]$|^GigabitEthernet2/[1-9]$|^GigabitEthernet2/[1-2][0-9]$|^Port-channel1$)
But that didn't solve the problem - LLD mechanism even stopped finding interfaces.
Tell me please, where I made a mistake - in the regex or in the logic of actions?
P.S. Sorry, my English isn't very good
I'm using Zabbix 6.0 with template Net Cisco IOS SNMP for monitoring Cisco Catalyst 4500 platform.
I need remove of unnecessary items, for example:
Because I have too much vlan interfaces on this switch:
I need monitoring interfaces, such as TenGigabitEthernet, GigabitEthernet, Port-channel.
I created regex for filtering Vlan interfaces and I used several ways to set it:
1. Template Net Cisco IOS SNMP -> Macros
{$NET.IF.IFNAME.NOT_MATCHES} add ^*Interface VLAN*$
(^Software Loopback Interface|^NULL[0-9.]*$|^[Ll]o[0-9.]*$|^[Ss]ystem$|^Nu[0-9.]*$|^veth[0-9a-z]+$|docker[0-9]+|br-[a-z0-9]{12}|^*Interface VLAN*$)
2. Template Net Cisco IOS SNMP -> Macros
{$NET.IF.IFNAME.MATCHES} I changed the value of ^.*$ to (^TenGigabitEthernet1/[1-8]$|^GigabitEthernet2/[1-9]$|^GigabitEthernet2/[1-2][0-9]$|^Port-channel*$)
3. Host -> Discovery -> Template Module Interfaces SNMP: Network interfaces discovery -> Filters
{#SNMPVALUE} matches (^TenGigabitEthernet1/[1-8]$|^GigabitEthernet2/[1-9]$|^GigabitEthernet2/[1-2][0-9]$|^Port-channel1$)
But that didn't solve the problem - LLD mechanism even stopped finding interfaces.
Tell me please, where I made a mistake - in the regex or in the logic of actions?
P.S. Sorry, my English isn't very good
Comment