I am trying to work around the very high latency that I get when trying to execute some ipmitool commands on the OppenPower machine that I am connected to via ssh and on which the OpenIPMI tool is installed and configured.
When I execute a command like the following:
ipmitool sdr type 0x03
to get the current average power consumption, I have a latency of ~20 seconds.
But when I use
ipmitool shell
and then run these kinds of commands, then I get very nice and fast response times because the internal ipmi session is kept alive I think.
My goal is to write a little script that issues the "get-power-consumption-command" every seconds for example (or every 100ms) to measure the energy efficiency of an algorithm that I implemented in C.
I tried python-ipmi but that library only offers connection via LAN or serial-terminal. But I just want to use it directly to read from /dev/ipmi0.
Does anyone know a decent solution to this problem?