How to monitor CWDM SFPs metrics using SNMP?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-26-2010 03:36 AM
Hi all,
We are currently monitoring approximately 50 locations each having one or more cisco devices, Catalyst 3750 and 3560.
Locations are connected via CWDM.
We would like to monitor interface errors, signal loss and power on CWDM SFP transceivers on Catalyst 3560 and Catalyst 3750 switches.
We tried to get these values (as shown using „sh interface transceiver“ command) using SNMP (through cisco-entity-sensor-mib) but we didn't get any SNMP result.
What would be the best approach to monitor these values?
What MIB or other functions/modules/features need to be used/activated on switch?
Do we need any additional piece of hardware?
Regards,
Marko
- Labels:
-
Network Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-26-2010 11:13 AM
What are the images you are running on these switches? CISCO-ENTITY-SENSOR-MIB support is fairly new to these platforms (12.2(50)SE and higher). I do not yet know if that MIB will give you what you want, but I don't see another MIB which could provide it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-26-2010 11:51 PM
Hi,
thanks for the reply.
We tried to browse this MIB on Cat3560 (already under management) IOS: 12.2(25)SEE2. We found out this IOS doesn't support CISCO-ENTITY-SENSOR MIB and that we must to upgrade to at least 12.2(50)SE.
So we took one of our test switches, Cat3560 (WS-C3650-24TS) and upgraded IOS to 12.2(53)SE1.
We enabled SNMP using this command only (no other snmp-like commands were used):
snmp-server community
Even though we were connected directly to the switch with a laptop, we got no SNMP reply, not even a sysDescr (OID=1.3.6.1.2.1.1.1.0) which works fine on a laptop itself.
So we are unable to test basic SNMP, and of course ENTITY-SENSOR-MIB as well.
A few questions:
1. what steps/prereqs need to be performed to enable SNMP on a switch? is the above command the only required thing to do?
2. if we have no SNMP reply from a directly connected switch (configured for SNMP access using above command), what could be the cause? in what direction to look for root cause?
3. once we get this working, is the ENTITY-SENSOR-MIB the only way to monitor SFPs metrics or is there another way? Are there any other prerequisites or aspects we should take care of? What about DOM?
Basically, we would like to monitor these CWDM-SFPs parameters with using as much as SNMP if that's possible. We hope to get this monitoring without doing any kind of heavy configuration change on a switch. We hoped to get this working by upgrading IOS, and using SNMP to get the data through an appropriate MIB (so far we think CISCO-ENTITY-SENSOR-MIB is the MIB to provide this info).
Marko

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010 12:09 AM
Without seeing the full running config, I cannot say for certain why things are not working. However, all that is required for SNMPv1 or v2c to work is a read-only community string as you have done. Make sure the string does not contain an '@'. If you're using net-snmp, make sure you explicitly specify the version as either v1 or v2c:
snmpwalk -c public -v 2c 10.1.1.1 sysDescr
As far as I can tell, this would be the only likely candidate MIB. I do not have a 3560 with SFP or GBIC ports with which to confirm.
Provided the MIB works, you shouldn't need to configure anything more than you already have to get what you want.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010 12:22 AM
Hi,
we didn't use any '@' in our community string.
We didn't use net-snmp, we use some kind of command line SNMP utility "ssnmpq" : Simple SNMP Command Line Query Tool
But that's not really important, the tool works fine in other cases....
I'll try with net-snmp (snmpwalk) and post my progress....
What kind of config output (running config) would you like to see? This is really bugging me. Instad of testing the CISCO-ENTITY-SENSOR MIB, i'm still stuck at making my switch to respond to a basic SNMP request.....
Marko

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010 09:02 AM
A full show run as well as the output from "debug snmp packet" when polling the device would be helpful. I assume that you have tested connectivity otherwise from your management station (i.e. you can ping/telnet/SSH to the switch)?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2010 08:57 AM
You'll need to configure the following in IOS for DOM monitoring, which also populates the results in CISCO-ENTITY-SENSOR-MIB, so it's a moot point until you can get the basic snmpwalk/snmpget working.
transceiver type all
monitoring
Other than SNMP, you could have a script (in Expert or Perl with Expect.pm) grab the outputs from IOS CLI:
show interface transceiver detail
show hw-module subslot [module number]/[slot number] transceiver [transreceiver number] status
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2010 01:26 AM
Hi guys, thanks for your answers...
To Joe: SNMP access is OK now, we had a connectivity issue....no problem there anymore, i can get the sysDescr OID.
To yjdabear: I'm testing on 3560, i don't think "transceiver type all" is a supported command.
To everybody: OK, let's summ up. I have managed to get the basic SNMP access to my test 3560 switch. The IOS is upgraded to support the CISCO-ENTITY-SENSOR MIB.
After running these commands, this is the otput:
SW4#show interfaces Gi0/1 transceiver properties
Diagnostic Monitoring is not implemented.
Name : Gi0/1
Administrative Speed: auto
Administrative Duplex: auto
Administrative Auto-MDIX: on
Administrative Power Inline: N/A
Operational Speed: 1000
Operational Duplex: full
Operational Auto-MDIX: on
Media Type: 1000BaseSX SFP
SW4#show interfaces Gi0/1 transceiver detail
Diagnostic Monitoring is not implemented.
So, "Diagnostic Monitoring is not implemented." tells me that i have 1000BaseSX SFP without DOM support i guess.
As per Cisco notes, these SFP SX product number exists:
GLC-SX-MM - without DOM support
GLC-SX-MM-RGD - without DOM support
SFP-GE-S - DOM supported
So i guess i have one of first two SFPs?
Is there a way to check this via CLI or SNMP or this info can only be found on a SFP label (sticker)?
Marko

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2010 01:00 PM
It looks like the transceiver command is only for 7600 devices. The part number may be listed on the SFP itself, but I cannot see where you would see this in the CLI. The "show inventory" command does not get that kind of detail. You might try doing an SNMP Walk of the entPhysicalTable, and see if entPhysicalModelName provides it to you.
That said, the "show interface trasceiver properties" command seems to reinforce the fact that DOM will not be possible.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2010 03:03 PM
Bummer. So I suppose the CWDM SFP turns out to be SX SFP that doesn't have DOM support.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2010 11:13 PM
Hi guys...
To Joe:
my Cisco engeneers colleagues tryed to get SFP product number on CLI, but no luck. I guess it's not so important, of course it is available on the SFP itself, on the stricker.
To Yjbabear:
Actually we have SX, LX, ZX and CWDM SFPs in our infrastructure... :-)
Whether one supports DOM, obviously depends on the Product Model.
That's why i want to get a broader picture, a generic way of monitoring optic parameters.I'm learning on the fly here....
But in the end, CWDM interfaces will be in the focus...
Okay, today we're gonna replace this SX SFP on a test switch with a CWDM one, and hopefully i'll be able to test CISCO-ENTITY-SENSOR MIB.
I'll post my results...
Regards, Marko
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-30-2010 06:33 AM
OK,we have tested the CWDM SFP and we're getting the data via CISCO-ENTITY-SENSOR-MIB.
Here are the results.
Via CLI:
W4#sh interfaces Gi0/1 transceiver properties
ITU Channel not available (Wavelength not available),
Transceiver is externally calibrated.
Name : Gi0/1
Administrative Speed: auto
Administrative Duplex: auto
Administrative Auto-MDIX: on
Administrative Power Inline: N/A
Operational Speed: 1000
Operational Duplex: full
Operational Auto-MDIX: on
Media Type: CWDM-1550 SFP
SW4#sh interfaces gi0/1 transceiver
ITU Channel not available (Wavelength not available),
Transceiver is externally calibrated.
If device is externally calibrated, only calibrated values are printed.
++ : high alarm, + : high warning, - : low warning, -- : low alarm.
NA or N/A: not applicable, Tx: transmit, Rx: receive.
mA: milliamperes, dBm: decibels (milliwatts).
Optical Optical
Temperature Voltage Tx Power Rx Power
Port (Celsius) (Volts) (dBm) (dBm)
--------- ----------- ------- -------- --------
Gi0/1 49.0 3.24 3.2 -12.9
Via MIB:
ENTITY-MIB:
Index Value | entPhysicalDescr | entPhysicalVendorType | entPhysicalContainedIn | entPhysicalClass | entPhysicalParentRelPos | entPhysicalName | entPhysicalAlias | entPhysicalIsFRU |
1056 | CWDM-1550 SFP | .1.3.6.1.4.1.9.12.3.1.10.290 | 1005 | port | 1 | GigabitEthernet0/1 | 10101 | 1 |
1057 | GigabitEthernet0/1 Module Temperature Sensor | .1.3.6.1.4.1.9.12.3.1.8.50 | 1056 | sensor | 1 | Gi0/1 Module Temperature Sensor | 2 | |
1058 | GigabitEthernet0/1 Supply Voltage Sensor | .1.3.6.1.4.1.9.12.3.1.8.49 | 1056 | sensor | 2 | Gi0/1 Supply Voltage Sensor | 2 | |
1059 | GigabitEthernet0/1 Bias Current Sensor | .1.3.6.1.4.1.9.12.3.1.8.48 | 1056 | sensor | 3 | Gi0/1 Bias Current Sensor | 2 | |
1060 | GigabitEthernet0/1 Transmit Power Sensor | .1.3.6.1.4.1.9.12.3.1.8.47 | 1056 | sensor | 4 | Gi0/1 Transmit Power Sensor | 2 | |
1061 | GigabitEthernet0/1 Receive Power Sensor | .1.3.6.1.4.1.9.12.3.1.8.46 | 1056 | sensor | 5 | Gi0/1 Receive Power Sensor | 2 |
CISOC-ENTITY-SENSOR-MIB:
Index Value | entSensorType | entSensorScale | entSensorPrecision | entSensorValue | entSensorStatus | entSensorValueTimeStamp | entSensorValueUpdateRate |
1057 | celsius | units | 1 | 490 | ok | 96 hours 16 minutes 4 seconds | 600 |
1058 | voltsDC | units | 2 | 324 | ok | 96 hours 16 minutes 4 seconds | 600 |
1059 | amperes | milli | 1 | 336 | ok | 96 hours 16 minutes 4 seconds | 600 |
1060 | 14 | units | 1 | 32 | ok | 96 hours 16 minutes 4 seconds | 600 |
1061 | 14 | units | 1 | -129 | ok | 96 hours 16 minutes 4 seconds | 600 |
OK, so what we see here is:
- indexes 1057-1061 are sensors on 1056 (this is CWDM SFP)
- their Types are presented in entSensorType
- why 1060 and 1061 (Transmit Power and Receive Power) have Type=14? The CISCO-ENTITY-SENSOR-MIB recognizes types from 1-13 and has string names for them, but 1060 and 1061 types are obviously returned by the IOS as "14" (no Type equivalent for 14 in MIB), is that correct? Does this depend on MIB used in MIBBrowser or MIB compiled in IOS on switch? How to make SNMP GET to return "decibels", "dBm" or "milliwatts" instead of "14"?
- Sensor Scale and Sensor Precision for 1060 an 1061 are "units" with precision "1". That would mean that:
- a value of 32 for 1060 would lead to 3,2 dBm (as in CLI output) having 32*10^0=32, and it is a number with 1(=Precision) decimal place. Am i getting this right? This is "explained" in the MIB but i didn't quite understand it...
- also, a value of -129 for 1061 would lead to -12,9 dBm (as in CLI output) having -129*10^0=-129, and it is a number with 1(=Precision) decimal place.
- a value of 32 for 1060 would lead to 3,2 dBm (as in CLI output) having 32*10^0=32, and it is a number with 1(=Precision) decimal place. Am i getting this right? This is "explained" in the MIB but i didn't quite understand it...
- 1059 (Bias Current) is not returned in CLI, but 336 with Type=amperes, Scale=milli (10^-3) and Precision=1 would lead to: 33,6 * 10^-3 amperes or 33,6 milliamperes?
- 1058 (Supply Voltage) is 324 with Type=voltsDC, Scale=units and Precision=2 would lead to: 3,24 voltsDC (as in CLI output)
Am i getting this right? As this is the only CWDM i can test, i want to make sure my understanding is correct and my math will be universal for all other devices/interfaces with SFPs.
If i want to get these values from many different nodes and interfaces, what would be variable, and what would be constant?
I guess Supply Voltage will not allways be "1058", or would it?
The problem is, how will i know what OID to target if i want to get the entSensorValue of Supply Voltage Sensor?
.1.3.6.1.4.1.9.9.91.1.1.1.1.4 - this is the OID for enSensorValue
but how do I target the value for a particular sensor on a particular interface?
It should look something like
.1.3.6.1.4.1.9.9.91.1.1.1.1.4.X.Y where X is the interface index (maybe entPhysicalAlias form ENTITY-MIB?) and Y is the sensor index?
So in my test case this would be:
.1.3.6.1.4.1.9.9.91.1.1.1.1.4.10101.1058 ???
I need help to get through this....
thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-30-2010 11:31 AM
1. Correct.
2. You have an older version of the MIB. Type 14 corresponds to dBm. I have posted the latest copy here.
3a. Absolutely correct. A precision value of 1 means that there is one decimal point, so the number is displayed in tenths. A value of 32 would be 32 tenths or 3.2.
3b. Precisely
4. You said it right. The 336 value is actually 336 tenths of a milliamp. So, the actual value as written would be 33.6 mA.
5. Exactly.
Your approach is correct, and would be the same for all sensors supporting the CISCO-ENTITY-SENSOR-MIB.
The entPhysicalIDs (i.e. the numbers 1058, 1056, etc. in your example) are dynamic, and will change from platform to platform, and possibly even boot to boot. The way you need to determine which sensor corresponds to whch interface module is to walk the entPhysicalTable, and tie an entPhysicalID with an entPhysicalName (e.g. the entPhysicalName will be something like Gi0/1).
The entSensorTable is indexed by entPhysicalID only. So, you will need to know the entPhysicalID for your interface, then find the sensors which are children of that interface/port entity.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2010 02:16 AM
Thanks Joe.
Thanks for the new MIB, but please clarify this: you said I have an older version of the MIB (where? in my MIB browsing tool or on a switch IOS?) and you sent me a new version that introduces entSensorType="14" as "dBm". But what to do with this new MIB?
The Cisco IOS will still return entSensorType="14" instead of entSensorType="dBm" regardless of if I use this new mib in my mib browser or not?
Can i compile this new version of CISCO-ENTITY-SENSOR-MIB to IOS somehow or what?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2010 08:20 AM
IOS actually has knowledge of a newer version of the MIB, but IOS will ALWAYS send 14. The MIB files are there just to give context and meaning to the values returned by the agent. The agent still only sends the integer value of the enumeration on the wire.
You need to load the new version of the MIB into your NMS so that it can properly translate the 14 to the textual representation of dBm.
No, you can not add new MIBs or new MIB versions to IOS.
