How to filter on IP range with the snmpcollector probe

book

Article ID: 15247

calendar_today

Updated On:

Products

DX Infrastructure Management NIMSOFT PROBES

Issue/Introduction



How can I filter on a range of IPs with an snmpcollector probe template?

Environment

Release: CNMSPP99000-8.51-Unified Infrastructure Mgmt-Server Pack-- On Prem
Component:

Resolution

The way to do this would be by using regex:

As an example I want a range of IPs from .200 to .235

1.1.1.200 

1.1.1.235 

The resulting regex would look like this: 

^1\.1\.1\.(2([0-2][0-9]|3[0-5]))$ 

To combine multiple ranges you would separate them by a | 

example: 

I want to combine 1.1.1.200 - 1.1.1.235 and 2.2.2.2 - 2.2.2.8

or

^1\.1\.1\.(2([0-2][0-9]|3[0-5]))$ and ^2\.2\.2\.([2-8])$ 

it should look like this: 

^1\.1\.1\.(2([0-2][0-9]|3[0-5]))$|^2\.2\.2\.([2-8])$