3.4. Remote Control with IPMI

The Intelligent Platform Management Interface (IPMI) can be used to control remote machines via a simple set of commands. Install it via the package manager.

[root@master ~]# dnf install ipmitool

The syntax for remote IPMI commands has the following scheme:

# -I lanplus is used for IPMI 2.0
# -I lan is used for IPMI 1.5
[root@master ~]# ipmitool -I lanplus -U USERNAME -P PASSWORD -H HOST COMMAND [ARGUMENTS]

By default, ipmitool will run with administrator privileges. Depending on your cluster, you will need to use the following credentials.

username

password

orca

orca2026

We can also add -L operator to your ipmitool call to change your privilege level to operator.

[root@master ~]# ipmitool -I lanplus -U orca -P orca2026 -L operator -H c01.mgmt power status

However, it is not a good idea to leave traces of your passwords as raw text in your command history. Instead, we recommend that you create a file (e.g. /etc/ipmi_password) with restrictive file permissions (600) to store the password on disk and use the ipmitool’s -f option. Note, restrictive file permissions can be set using chmod 600 /etc/ipmi_password.

[root@master ~]# ipmitool -I lanplus -U orca -f /etc/ipmi_password -L operator -H c01.mgmt power status
Chassis Power is on

To reduce the amount of typing, it is useful to create a small utility script. Typically, we usually call this /usr/bin/ipmiwrap. Create this utility script with the contents below:

#!/bin/bash
HOSTNAME=$1
shift
ipmitool -I lanplus -U orca -f /etc/ipmi_password -L operator -H $HOSTNAME.mgmt $@

Make sure the permissions of the script are set to 775 using the chmod command. Using this script allows us to type much shorter ipmi commands:

# USAGE: ipmiwrap HOST COMMAND [ARGUMENTS]
[root@master ~]# ipmiwrap c01 power status
Chassis Power is on

3.4.1. Basic IPMI Commands

Warning

The virtual machine’s BMC will not behave quite the same as the physical node’s BMC and will not have all of the same features.

ipmitool offers a whole range of different commands that simplify remote management. You can learn more about the tool by using the help command.

[root@master ~]# ipmitool help
Commands:
 raw           Send a RAW IPMI request and print response
 i2c           Send an I2C Master Write-Read command and print response
 spd           Print SPD info from remote I2C device
 lan           Configure LAN Channels
 chassis       Get chassis status and set power state
 power         Shortcut to chassis power commands
 event         Send pre-defined events to MC
 mc            Management Controller status and global enables
 sdr           Print Sensor Data Repository entries and readings
 sensor        Print detailed sensor information
 fru           Print built-in FRU and scan SDR for FRU locators
 gendev        Read/Write Device associated with Generic Device locators sdr
 sel           Print System Event Log (SEL)
 pef           Configure Platform Event Filtering (PEF)
 sol           Configure and connect IPMIv2.0 Serial-over-LAN
 tsol          Configure and connect with Tyan IPMIv1.5 Serial-over-LAN
 isol          Configure IPMIv1.5 Serial-over-LAN
 user          Configure Management Controller users
 channel       Configure Management Controller channels
 session       Print session information
 dcmi          Data Center Management Interface
 nm            Node Manager Interface
 sunoem        OEM Commands for Sun servers
 kontronoem    OEM Commands for Kontron devices
 picmg         Run a PICMG/ATCA extended cmd
 fwum          Update IPMC using Kontron OEM Firmware Update Manager
 firewall      Configure Firmware Firewall
 delloem       OEM Commands for Dell systems
 shell         Launch interactive IPMI shell
 exec          Run list of commands from file
 set           Set runtime variable for shell and exec
 hpm           Update HPM components using PICMG HPM.1 file
 ekanalyzer    run FRU-Ekeying analyzer using FRU files
 ime           Update Intel Manageability Engine Firmware
 vita          Run a VITA 46.11 extended cmd
 lan6          Configure IPv6 LAN Channels

3.4.1.1. Controlling power

You can query the current state of your system with the power status command.

[root@master ~]# ipmiwrap c01 power status
Chassis Power is off

To turn a machine on or off, use one use the power on and power off commands.

[root@master ~]# ipmiwrap c01 power on
Chassis Power Control: Up/On
[root@master ~]# ipmiwrap c01 power off
Chassis Power Control: Down/Off

To reboot a machine, you can either do a power reset, which does a warm boot (power is never turned off), or power cycle which performs a cold boot (power is turned off and on again).

# warm reboot
[root@master ~]# ipmiwrap c01 power reset
Chassis Power Control: Reset

# cold reboot
[root@master ~]# ipmiwrap c01 power cycle
Chassis Power Control: Cycle

Finally, power soft initiates a soft-shutdown via ACPI.

# tell OS to shutdown gracefully
[root@master ~]# ipmiwrap c01 power soft
Chassis Power Control: Soft

3.4.1.2. Getting sensor data

Your BMC can collect a range of useful information to determine the health of your system. An exhaustive list of all sensors can be printed out with the sensor command.

[root@master ~]# ipmiwrap c01 sensor
CPU Temp         | na         |            | na    | 0.000     | 0.000     | 0.000     | 99.000    | 104.000   | 104.000
System Temp      | na         |            | na    | -10.000   | -5.000    | 0.000     | 80.000    | 85.000    | 90.000
Peripheral Temp  | na         |            | na    | -10.000   | -5.000    | 0.000     | 80.000    | 85.000    | 90.000
MB_10G Temp      | na         |            | na    | -5.000    | 0.000     | 5.000     | 95.000    | 100.000   | 105.000
...

For a more targeted search, you can use the sdr command and specify the type of information you are looking for.

[root@master ~]# ipmiwrap c01 sdr type list
Sensor Types:
     Temperature               (0x01)   Voltage                   (0x02)
     Current                   (0x03)   Fan                       (0x04)
     Physical Security         (0x05)   Platform Security         (0x06)
    ...

[root@master ~]# ipmiwrap c01 sdr type Temperature
CPU Temp         | 01h | ok  |  3.1 | 49 degrees C
System Temp      | 0Bh | ok  |  7.1 | 32 degrees C
Peripheral Temp  | 0Ch | ok  |  7.2 | 45 degrees C
MB_10G Temp      | 0Dh | ok  |  7.4 | 60 degrees C
DIMMA1 Temp      | B0h | ns  | 32.64 | No Reading
DIMMA2 Temp      | B1h | ns  | 32.65 | No Reading
DIMMB1 Temp      | B4h | ns  | 32.68 | No Reading
DIMMB2 Temp      | B5h | ns  | 32.69 | No Reading

3.4.1.3. Chassis commands

  1. Identifying a specific system

    Most BMCs come with status lights that indicate their state and location. You can make these lights blink to help identify a system using the chassis identify command.

    # blink chassis LED for 120 seconds
    [root@master ~]# ipmiwrap c01 chassis identify 120
    Chassis identify interval: 120 seconds
    
  2. Setting boot device for next boot

    You can temporarily set the next boot device using the chassis bootdev command.

    # boot via network boot
    [root@master ~]# ipmiwrap c01 chassis bootdev pxe
    Set Boot Device to pxe
    
    # boot into BIOS setup
    [root@master ~]# ipmiwrap c01 chassis bootdev bios
    Set Boot Device to bios
    

3.4.1.4. Vendor specific extensions

Some vendors have extra capabilities which can be accessed via IPMI. Note, your system may not support this command.

[root@master ~]# ipmiwrap c01 delloem powermonitor
Power Tracking Statistics
Statistic      : Cumulative Energy Consumption
Start Time     : Thu Dec 16 14:09:09 2010
Finish Time    : Wed Feb  6 14:19:09 2019
Reading        : 859.4 kWh

Statistic      : System Peak Power
Start Time     : Wed Nov  3 22:21:33 2010
Peak Time      : Wed Jul 15 08:36:22 2015
Peak Reading   : 319 W

Statistic      : System Peak Amperage
Start Time     : Wed Nov  3 22:21:33 2010
Peak Time      : Wed Jul 15 08:35:39 2015
Peak Reading   : 1.5 A

3.4.1.5. Reviving a hanging BMC

Sometimes BMCs can get stuck. If you can still reach it via network, but commands don’t work, you can try power cycling the BMC itself with the following command.

[root@master ~]# ipmiwrap c01 bmc reset cold
Sent cold reset command to MC

3.4.1.6. System Event Log (SEL)

A BMC keeps track of events on your system such as hardware failures. In many cases, a critical error will result in an SEL entry as well as your system indicating a failure using a amber warning light.

To learn more about the error, you can query the current SEL with the sel list command.

[root@master ~]# ipmiwrap c01 sel list
1 | 01/25/2026 | 09:01:07 PM EST | OS Critical Stop | OS graceful shutdown () | Asserted
2 | 04/03/2026 | 11:23:59 PM EDT | Unknown #0xff |  | Asserted
3 | 04/03/2026 | 11:11:26 AM EDT | Unknown #0xff |  | Asserted
4 | 04/03/2026 | 11:59:18 AM EDT | Unknown #0xff |  | Asserted
5 | 04/03/2026 | 12:01:26 PM EDT | OS Boot | C: boot completed () | Asserted
6 | 04/06/2026 | 05:49:46 AM EDT | Unknown #0xff |  | Asserted
7 | 05/11/2026 | 09:19:19 AM EDT | Unknown #0xff |  | Asserted
8 | 05/13/2026 | 01:26:42 AM EDT | Unknown #0xff |  | Asserted
9 | 05/13/2026 | 01:45:29 AM EDT | Session Audit #0xff |  | Asserted

Once you have determined the cause and fixed it, you will want to clear the SEL to remove the warning light.

[root@master ~]# ipmiwrap c01 sel clear
Clearing SEL.  Please allow a few seconds to erase.

3.4.1.7. Managing IPMI Users / Changing the IPMI password

To get the current list of configured users, use the user list command.

[root@master ~]# ipmiwrap c01 user list
ID  Name             Callin  Link Auth  IPMI Msg   Channel Priv Limit
1                    true    false      false      Unknown (0x00)
2   ADMIN            false   false      true       ADMINISTRATOR
3   orca             true    true       true       OPERATOR
4                    true    false      false      Unknown (0x00)
5                    true    true       true       NO ACCESS
6                    true    false      false      Unknown (0x00)
7                    true    false      false      Unknown (0x00)
8                    true    false      false      Unknown (0x00)
9                    true    false      false      Unknown (0x00)
10                   true    false      false      Unknown (0x00)

As you can see, by default, user 2 is set to be ADMIN with ADMINISTRATOR privileges. The orca user was set to OPERATOR and has user id 3. Assuming you have ADMINISTRATOR rights, you can change the default password for a user with the following command:

# 3 is the USER ID of orca
[root@master ~]# ipmiwrap c01 user set password 3

3.4.2. Serial Console

IPMI supports a feature called Serial-Over-LAN (SOL). If enabled, you can connect to a serial port of you BMC that will change your current terminal into a text console matching the screen of your remote system.

This will allow you to configure BIOS settings and even login into the system as if you were connected to it directly with a screen and keyboard.

To launch a SOL session use the sol activate command.

[root@master ~]# ipmiwrap c01 sol activate

Once in the SOL session, the following scape sequences are supported:

~.

terminate connection (and any multiplexed sessions)

~B

send a BREAK to the remote system

~C

open a command line

~R

request rekey

~V/v

decrease/increase verbosity (LogLevel)

~^Z

suspend ssh

~#

list forwarded connections

~&

background ssh (when waiting for connections to terminate)

~?

help

~~

send the escape character by typing it twice

The sequence ~. will disconnect both SOL and any SSH session if typed at the beginning of a line; ~. will terminate the SSH session to the bastion host. To avoid closing the SSH connection, it is needed to scape the sequence ~. with ~ for each inner SSH session. Since you are connected from your workstation to the bastion and then to the masters, you will need to scape two SSH sessions. The complete sequence to terminate the SOL session whitout clossing your SSH connection is ~~~.

If for some reason your session gets stuck in on terminal, you can deactivate it from another terminal as follows:

[root@master ~]# ipmiwrap c01 sol deactivate

Terminating SOL can leave the terminal in a weird state (e.g. reverse colors or unreadable font or bad size). The commands reset and clear can be used to clean it up and get back to sane terminal settings.

3.4.2.1. Keybindings

Key

Shortcut

F1

ESC + 1

F2

ESC + 2

F3

ESC + 3

F4

ESC + 4

F5

ESC + 5

F6

ESC + 6

F7

ESC + 7

F8

ESC + 8

F9

ESC + 9

F10

ESC + 0

ESC

ESC + ESC