Difference between revisions of "IPMI"

From SOWNWiki
Jump to: navigation, search
(Making use of IPMI)
(In person)
 
Line 56: Line 56:
 
* Console Redirection -> Console Redirection -> Serial Port 1
 
* Console Redirection -> Console Redirection -> Serial Port 1
 
* Console Redirection -> Failsafe Baud Rate -> 19200
 
* Console Redirection -> Failsafe Baud Rate -> 19200
* Console Redirection -> Redirection After Boot -> Enabled (I suspect we don't actually need this one)
+
* Console Redirection -> Redirection After Boot -> Disabled
  
 
== OS configuration ==
 
== OS configuration ==

Latest revision as of 16:39, 9 October 2019

IPMI (Intelligent Platform Management Interface) is used on physical SOWN servers for out of band access. This allows access to a console when the OS is not running, eg to diagnose boot/network issues.

Making use of IPMI

To get a console

IPMI 1.5 (older R200 servers)

ipmitool -I lan -H hostname-ipmi -U sown isol activate

IPMI 2 (newer servers)

ipmitool -I lanplus -H hostname-ipmi -U sown sol activate

Powercycling

ipmitool ... power off|on|cycle|reset|diag|soft

Getting into the BIOS (R200)

<Esc><!> is the serial equivalent of <F11> and will get you a boot menu, then select system setup.

Recovering / reinstalling servers

See PXE

Configuration

IPMI configuration

This can be easily configured on a running server through ipmitool:

# to list existing users
ipmitool user list 1

# to set up a sown user, renaming from an existing "root" user
ipmitool user set name 2 sown
ipmitool user set password 2

# to print network config
ipmitool lan print 1

# to set up network
# allocate a new IP within 10.5.0.160/27
ipmitool lan set 1 ipaddr NEWIP
ipmitool lan set 1 netmask 255.255.255.0
ipmitool lan set 1 defgw ipaddr 10.5.0.254
ipmitool lan set 1 access on

Otherwise, you should be able to configure this by hand as the server is booting - on the older Dell servers at least, press Ctrl+E when prompted to.

Console redirection

To make IPMI actually useful, the server's serial port needs to be configured to talk the IPMI chip, and console redirection enabled so the BIOS uses the serial port.

From linux

To start, install the syscfg package following instructions from https://linux.dell.com/repo/community/openmanage/

Then run the following to set everything:

/opt/dell/toolkit/bin/syscfg --conboot=enable
/opt/dell/toolkit/bin/syscfg --conred=serial1
/opt/dell/toolkit/bin/syscfg --serial1=bmclan
/opt/dell/toolkit/bin/syscfg --fsbr=19200

Dell also has some useful syscfg documentation at https://www.dell.com/support/manuals/us/en/04/dell-opnmang-dplymnt-toolkit-v4.3/dtk_cli-v2/syscfg-options-on-poweredge-systems-prior-to-poweredge-12g-systems?guid=guid-89294b0f-b646-45ef-86dd-450035e6d519&lang=en-us

(adapted from https://jslf.app/projects/ipmi/isol-setup.txt )

In person

Set the following in the BIOS:

  • Integrated Devices -> Serial Port 1 -> BMC NIC
  • Console Redirection -> Console Redirection -> Serial Port 1
  • Console Redirection -> Failsafe Baud Rate -> 19200
  • Console Redirection -> Redirection After Boot -> Disabled

OS configuration

To configure both grub and the kernel to use the serial port, put something like the following in /etc/default/grub:

GRUB_CMDLINE_LINUX="console=tty0 console=ttyS0,19200n8"
GRUB_TERMINAL="console serial"
GRUB_SERIAL_COMMAND="serial --speed=19200 --unit=0 --word=8 --parity=no --stop=1"

Adjust the rest of the config to taste, probably removing any use of "quiet" on the kernel cmdline to have both the kernel and systemd be more verbose in what they print. Assuming the server is running systemd, this configuration will also cause systemd to start a getty automatically on the serial port once the server is running. SOL also isn't particularly responsive, so a higher GRUB_TIMEOUT (eg 10s) is sensible.

Once done, to rebuild the grub configuration:

update-grub