Today at work, I had to upgrade the BIOS on some new Dell servers that had just arrived. (Dell, conveniently, shipped them with firmware six months’ out of date.)
Dell’s Linux-based BIOS updater, not entirely shockingly, didn’t work. After I had installed its prerequisites and let it run (repeatedly), it churned for a while and then gave up, offering only this:
The update failed to complete.
So, I decided to fall back to the tried-and-true option: the simple, DOS-based BIOS updater that Dell provides. The trick is that the updater does not contain DOS: You have to figure out how to get your servers to boot from a DOS floppy and then run the BIOS updater.
Did I mention that the servers lack floppy and CD-ROM drives?
Having been down this road before, I knew to get a FreeDOS disk image and then add the BIOS updater to it:
- Download the DOS-based firmware updater.
- Download a 2.88-MB FreeDOS floppy image with enough free space for the updater. (I used the dosdisk288.img image from the biosdisk project; see below.)
- Mount the image, copy the updater to it, and then unmount it. (See these instructions for more.)
Now I had a bootable floppy-disk image dosdisk288.img that contained the BIOS updater. Next, I needed some way to boot the system using that image. Since the servers had no floppy or CD-ROM drives, the next trick was making the image network-bootable.
For this, I used PXE and cobbler, an install server. We already run cobbler on provisioning servers sprinkled throughout our server farms, so it was easy to put the image on the network:
mv /tmp/dosdisk288.img /srv/dell-PER415-firmware/PER415-010203.img cobbler distro add \ --name=Dell-PER415-fw-010203 \ --kernel=/usr/lib/syslinux/memdisk \ --initrd=/srv/dell-PER415-firmware/PER415-010203.img cobbler profile add \ --name=Dell-PER415-fw-010203-installer \ --distro=Dell-PER415-fw-010203 cobbler sync
The “distro add” command was where the magic happened. It told cobbler to create a fake Linux distribution whose kernel is memdisk and whose initrd is my floppy image. Memdisk is a special boot kernel designed to boot from a floppy image supplied as the initial ramdisk (initrd).
After the cobbler sync completed, I was able to boot the servers from the network by selecting the “Dell-PER415-fw-010203-installer” item from the PXE boot menu. A few moments later, I was at a DOS prompt. From there, I just ran the BIOS updater, and I was done!
For reference, here are the tools and documentation I used to accomplish my mission:
- Ubuntu Dell BIOS – a handy page on the Ubuntu wiki discussing schemes for updating the BIOS on Dell systems
- Dell biosdisk – an unofficial project at Dell for building bootable floppies and images for installing BIOS updates
- MEMDISK module, part of SYSLINUX – it allows you to boot floppy and disk images from Linux bootloaders; it pretends to be a Linux kernel and boots the image given as its initrd kernel argument