I am looking for the best way to organise devices on NetMRi using Device Grouping. Our standard ensure that the snmp-server location (SNMP Object sysLocation) uses the format: "Site / Floor"
When I create Device Groups I label them like this:
Name (of Device Group) = Bracknell Routers 3rd Floor
$sysLocation like /["Bracknell"] and ["3rd"] and ["Floor"]*./ and $Type like /.*Router.*/
Once the group has been created I click the "Generate Groups" button. At which point I hope to have only the device of type "Router" containing the snmp-server location of "Bracknell 3rd Floor"
This is not working very well and I suspect it may have something to do with the regex in the Membership Criteria.
If anyone could assist me I would be very grateful.
Thanks in advance,
05-20-2013 12:27 PM
$sysLocation like /Bracknell 3rd/ and $Type in ["Router"]
That will create a group for Bracknell 3rd Floow
Now for Bracknell 2nd floor use the following:
$sysLocation like /Bracknell 2nd/ and $Type in ["Router"]
Now for Bracknell 2nd floor with Routers and Switches use the following:
$sysLocation like /Bracknell 2nd/ and $Type in ["Router","Switch-Router","Switch"]
05-22-2013 03:53 AM
Thank you for the help- but I tried this regex for device grouping and it still did not work:
$sysLocation like /Bracknell 4th/ and $Type in ["Switch"]
And for information, the interface description is set as follows on the Cisco device:
snmp-server location Bracknell - 4th Floor
However NetMRI has yet to place it and others on that floor in the group.
I tried amending the script to this:
$sysLocation like /Bracknell 4th/ and $sysLocation like / 4th/ and $Type in ["Switch"]
But still no luck - nothing appears in the device group.
is this a bug or is the expression wrong I wonder?
05-28-2013 02:17 AM
I understood (but of course can be corrected) that the "like" looks for pattern matches but is not an exact match, so "snmp-server location Bracknell - 5th Floor" and also "snmp-server location Bracknell 5th Floor" - neither of these work.
I am stumped really because a Device grouping for switches on the 3rd floor worked the first time.
I tried Sif Baksh 's recommendation but again - nothing was placed into any groups.
I am running a very old version of software and so I am wondering if this has any bearing on it
Okay this problem seems to be resolved. As soon as I upgraded the software to 126.96.36.199 the device grouping using the same syntax started to work as expected. Thanks to everyone who helped.
2 weeks ago
Hello, Could someone please help me here. I want to create a device group where config credential status and snmp credential status for a device are "Ok"