IPMI trick: Set the boot device

I’ve long known that you can use IPMI (on compatible systems) for some nice lights-out management, like power control or reading system information that you’d see in the BIOS. But one thing that has always annoyed me is having to get a remote console on the box and wait for just the right second to press the right key to bring up the screen where I can change boot order.

Lo and behold, this is an IPMI feature! It’s implemented at least on some IBM servers I’m working with:

mawagner ~ $ ipmitool -H -U USERID chassis bootdev
bootdev <device> [clear-cmos=yes|no]
bootdev <device> [options=help,...]
none : Do not change boot device order
pxe : Force PXE boot
disk : Force boot from default Hard-drive
safe : Force boot from default Hard-drive, request Safe Mode
diag : Force boot from Diagnostic Partition
cdrom : Force boot from CD/DVD
bios : Force boot into BIOS Setup
floppy: Force boot from Floppy/primary removable media
mawagner ~ $ ipmitool -H -U USERID chassis bootdev cdrom
Set Boot Device to cdrom

It appears that this will override settings on the next boot, but not make a persistent change. (You can, however, set the ‘persistent’ option.) Using bootdev none options=help lists out the available options, some of which are pretty interesting.

8 thoughts on “IPMI trick: Set the boot device

  1. Is there any way to determine what the default boot disk is? I have a system running with multiple OS images, and I’d like to select a particular image for the next reboot. If so, it possible to alter the default via ipmitool?

    • ipmitool -H Server1 -U -P chassis bootparam get 5
      will give you the
      Boot Device Selector : Force Boot from Floppy/primary removable media
      which tells you the default boot devices is been set to

  2. Hi,

    I’ve been trying to use the commands you’ve given here but they don’t seem to be working for me :/

    I keep getting this every time i run an ipmitool command:

    Error: Unable to establish LAN session
    Error: Unable to establish IPMI v1.5 / RMCP session

    if you know why I’d appreciate the help :)

    • Hello Josh,
      For error you mentioned
      Error: Unable to establish IPMI v1.5 / RMCP session
      -if you are Admin, then you it is easy fix, you should be able to login to the mgmnt using your admin creds and reimage the system.
      – If you have local access to the system, hook up your crash cart and update BMC and that should fix the issue for you.

  3. Pingback: Sustanon for Sale USA

  4. Pingback: Rabin – Rabin.IO

Leave a Reply

Your email address will not be published. Required fields are marked *

To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax