Hello,
I'm currently facing a problem regarding the name of an item prototype.
I use Regex to make the name more meaningful.
I want to monitor the chassis temperature of a switch-stack with the following OID: 1.3.6.1.4.1.11.2.14.11.1.2.8.1.1.3 (hpSystemAirCurrentTemp)
If i execute an SNMP Walk on a device with the mentioned OID I get the following output:
- HP-ICF-CHASSIS::hpSystemAirCurrentTemp.0 = STRING: "36C"
- HP-ICF-CHASSIS::hpSystemAirCurrentTemp.1 = STRING: "37C"
- HP-ICF-CHASSIS::hpSystemAirCurrentTemp.2 = STRING: "36C"
The three values stand for each slot/unit.
Now I want to use the .0, .1, .2 as indicators of the slot/unit in the item name
The problem is, that ".0" is actually unit 1 and ".1" is unit 2 and so on.
Is there a possible way to display it correctly?
I would need to add 1 to every number but with Regex calculations are not possible (as far as I know).
It should look something like this:
- Unit 1 = 36C
- Unit 2 = 37C
- Unit 3 = 36C
Thanks in advance for any assistance!
Comment