Forum Discussion
I've been looking at this and the first Datasource to get the switch status is pretty straightforward. The second, not so much.
The issue is that there are two different items that need to be indexed -- the switch and the port on the switch. For example, an snmpwalk on 1.3.6.1.4.1.12356.101.24.2.1.1.5 returns:
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001334.1 = STRING: "port1"
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001334.2 = STRING: "port2"
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001334.3 = STRING: "port3"
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001334.4 = STRING: "port4"
...
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001431.1 = STRING: "port1"
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001431.2 = STRING: "port2"
.1.3.6.1.4.1.12356.101.24.2.1.1.5.1.14.18001431.3 = STRING: "port3"
So it looks like 18001334 and 18001431 are the indexes for different switches while the trailing .1, .2 etc. are the port indexes.
If we do the same for 1.3.6.1.4.1.12356.101.24.2.1.1.4 it shows the switch serial number for each port so you can see it looks like this is the case:
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001334.1 = STRING: "S248DNTF18001334"
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001334.2 = STRING: "S248DNTF18001334"
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001334.3 = STRING: "S248DNTF18001334"
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001334.4 = STRING: "S248DNTF18001334"
...
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001431.1 = STRING: "S248DNTF18001431"
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001431.2 = STRING: "S248DNTF18001431"
.1.3.6.1.4.1.12356.101.24.2.1.1.4.1.14.18001431.3 = STRING: "S248DNTF18001431"
So for the instance names you'd probably want to combine the two of those into the display name or you'll end up with multiple instances with the same name. Is that something that can be done in an SNMP datasource or would we need to use Groovy for that?
Related Content
- 27 days ago
- 2 years ago