ipmi reports "Unknown state 8 for reading type 111..."
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pyghmi |
New
|
Undecided
|
Unassigned |
Bug Description
For devices of type "Power Supply" (8) or "Battery" (41) pyghmi.ipmi.sdr reports health warnings due to unknown states. The output of
$ python -m pyghmi.ipmi.sdr <ip> <user>
is
{'states': ['Present', 'Unknown state 8 for reading type 111/sensor type 8', 'Unknown state 9 for reading type 111/sensor type 8', 'Unknown state 10 for reading type 111/sensor type 8', 'Unknown state 11 for reading type 111/sensor type 8', 'Unknown state 12 for reading type 111/sensor type 8', 'Unknown state 13 for reading type 111/sensor type 8', 'Unknown state 14 for reading type 111/sensor type 8'], 'health': 1, 'name': 'PS Status', 'imprecision': None, 'units': '', 'state_ids': [552704, 552712, 552713, 552714, 552715, 552716, 552717, 552718], 'type': 'Power Supply', 'value': None, 'unavailable': 0}"
It seems to me either the criteria to look up states above 0x07 ("if len(reading) > 3:", ipmi/sdr.py:469) is not appropriate, or the handling of lookup errors needs to be changed.