Excluding interfaces on network discovery/switch ports

Dear Community,

I have configured to discover network interface on our switches using the description as appearance of the interface. Since we automate the discovery (adding/removing interfaces), our network guy place a tag in the alias of the interface which they don’t want to be monitored: “xADIx”. Because of this I set up a matching criteria in “Match interface alias (regex)” like this:

(?!(xADIx))

I double checked with python regex checker, if this would match (or in this this case, it should not match).

But the interfaces with the tag “xADIx” still appear on discovery and they don’t use the description in the service name, but the index, which is strange as well.

interfaces

Did I misconfigure something here?

BR
Benjamin

Usually that’s the interface alias and not the description. Try to filter to the alias instead of description.

Can you try with this “^(?!(xADIx))”?
Your regex is not working on my test

I tried this as well, with the same result. I figured, since the help says “match from beginning”, I could do it without the “^”. Either way the regex does not work, but it should, or am I completely on the wrong track?

The filter is set on the alias, the description is used for the naming of the service.

We had a similar requirement lately. At our end, we wanted to not match any interface that had “access”, “client” or “phone” in its alias. We ended up with the following regex: (?!.*(access|client|phone))^.*

This is not exactly the same requirement as you have, though. Our regex matches on an interface that has one of the keywords anywhere in its alias. Nonetheless, maybe it helps :slight_smile:

1 Like

Thanks for the hint. This doesn’t work either in my installation. What CMK Version are you using this?
Starting to think this might be a bug.

This is in use on CME 1.6.0, I think patches p6 to p17 (we have around 70 sites, so I’m not entirely sure :wink: ).

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact @fayepal if you think this should be re-opened.