IPMI Raw Commands

Vernon Mauery vernon.mauery at linux.intel.com
Tue Mar 10 07:29:30 AEDT 2020

On 06-Mar-2020 04:54 PM, Anony Mous wrote:
>To whom it may concern,


Interesting name choice for interacting with an opensource project.

>1. Does openbmc ipmitool support any of the ipmi raw commands? Most of them
>(such as the one below) returns "invalid command".
>ipmitool raw <netfn> <command>
>netfn = storage = 0x0a
>command = enter sdr respository update mode = 0x2a

ipmitool supports raw commands in part because it the full array of 
commands supported by the IPMI spec is too vast to have them all 
implemented as named commands. In addition, IPMI offers the ability for 
OEMs to define OEM-specific IPMI commands that may have one meaning on 
one BMC and another meaning on a system from a different OEM.

>The above command was executed on the BMC and the following error returned:
>"Unable to send RAW command (channel=0x0 netfn=0xa lun=0x0 cmd=0x2a
>rsp=0xc1): Invalid command"

The SDR commands for OpenBMC are defined in the phosphor-host-ipmid repo 
(https://github.com/openbmc/phosphor-host-ipmid) in the 
storagehandler.cpp file. It appears that the enter sdr update mode 
command is not implemented.

>2.  Can the ipmi raw commands be executed on the BMC itself or does it need
>to be executed from an external source (such as a processor connected to
>the BMC)?

As explained above, raw commands are not so much a kind of command as a 
mechanism to send specific bytes to the IPMI execution machinery. From 
the BMC console, it is possible to run raw commands, the same as if you 
are executing them over any other channel (SI, IPMB, RMCP+, etc.)

>3. Do any kind of privilege settings need to be modified in order to
>execute any ipmi raw commands?

It is not that raw commands don't work on OpenBMC, it is that some 
commands are not implemented.

root at intel-obmc:~# ipmitool raw 6 1
 23 00 80 40 02 bf 57 01 00 7b 00 0c 42 ff 21

>From the BMC serial console, running ipmitool will execute commands in a 
session-less manner, much like executing commands over the system 
interface from the host or over an IPMB channel. So no privilege check 
is done; the commands run as admin by default.


More information about the openbmc mailing list