Repository navigation
Expand shared Compact sensor records into one sensor per instance (#100) - #197
Merged
Merged
Conversation
A Compact record with a share count of N describes N sensors with
consecutive numbers (IPMI 2.0 section 43.2); sensors() read the first
one only. Every Dell iDRAC in the lab shares records: drive slots
("Drive 0" x 15 and "Drive 15" x 9 on iDRAC 8, "Drive" x 6 on an
R-series iDRAC 6) and DIMM slots ("A " x 12, "B " x 12), so an R630
lost 44 sensors.
readSensors() now reads each instance with its own Get Sensor Reading,
and Sensor carries its index: number() adds it, entityInstance() adds
it when the record says the entity instance increments, name() appends
the instance modifier (offset + index for a numeric modifier, base-26
letters for an alpha one). An ID string that already ends with a number,
as Dell writes it, has that number incremented instead, so the slots are
named Drive 0 to Drive 23 rather than Drive 0 0. The names() globs match
the expanded names, and a refused instance (an empty slot answering CBh)
costs that instance only.
Live: idrac-hegel lists Drive 0-5 (two present), idrac-ecs1 goes from
171 to 215 sensors (Drive 0-23, A 1-12, B 1-12). No other vendor in the
lab shares records, and their output is unchanged.
Closes #100
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #100.
What
A Compact sensor record with a share count of N describes N sensors with consecutive sensor numbers (IPMI 2.0 section 43.2, table 43-2 bytes 24-25). The fields were parsed, but
sensors()read only the first sensor of the record.IpmiClient.readSensors()reads each instance of a shared record with its own Get Sensor Reading; a share count that would run past sensor number 255 is cut there.Sensorcarries its index among the sensors sharing the record:number()adds it,entityInstance()adds it when the record says the entity instance increments,name()appends the instance modifier (offset + index for a numeric modifier, base-26 letters for an alpha one: A..Z, AA...). When the ID string already ends with a number, that number is taken as the first instance's and incremented, so Dell'sDrive 0(15 sensors) andDrive 15(9 sensors) becomeDrive 0toDrive 23rather thanDrive 0 0.names()globs match the expanded names; a refused instance (an empty slot answeringCBh) costs that instance only, as before for a single sensor.TODOinCompactSensorRecordis gone.Why it matters
The issue said mainstream rack BMCs rarely share records. A survey of the 40 lab BMCs on 2026-10-19 shows the opposite for Dell: every iDRAC (6, 8, F200) shares records, for drive slots and DIMM slots, and no other vendor does (Lenovo IMM/XCC, HPE iLO 5, Cisco IMC, Supermicro, Fujitsu iRMC, GIGABYTE: none). ipmitool parses the share fields and never uses them; ipmiutil lists one
Driveline; FreeIPMI expands behind--shared-sensors.Live results
Drivesensor (128)Drive 0toDrive 5(128-133), drives 0 and 1 presentDrive 0,Drive 15,A,BDrive 0toDrive 23(slots 8-23 "scanning disabled"),A 1toA 12(present),B 1toB 12Tests
aSharedRecordYieldsOneSensorPerInstance: numeric modifier from 0 (Drive 0..2), Dell-style ID string (Drive 15,Drive 16), alpha modifier from 25 with the entity instance incrementing (Temp Z,Temp AA), a refused instance, name globs on the expanded names, one Get Sensor Reading per instance.mvn clean verify sitepasses (checkstyle 0, SpotBugs 0, CPD 0).🤖 Generated with Claude Code