Thinkpad: Upgrade Bios using Linux
So I was trying to upgrade the BIOS the other day and I thought it’d be good to document it for future - since I plan on getting a Thinkpad X220 and patching the BIOS (maybe even going the coreboot route). Anyways, here’s the steps.
TL;DR
- Grab the iso from support site
- Convert iso to usb and write it to disk
- Restart and boot into USB drive (Make sure legacy boot is enabled BIOS).
- Run through instructions and update the BIOS.
- Download the latest BIOS update from support.lenovo.com or just search “bios update lenovo
”. Here’s the BIOS download link for Thinkpad T420s - Check your current version with
dmidecode
and validate that you’re not already up to date.❯ sudo dmidecode -s bios-version 8CET66WW (1.39 )
To create a bootable USB - convert ISO to IMG file. I recommend using geteltorito which is available for arch or for debian as genisoimage package. Install it using your package manager and then run.
❯ geteltorito.pl -o bios.img /path/to/your-downloaded-file.iso Booting catalog starts at sector: 20 Manufacturer of CD: NERO BURNING ROM Image architecture: x86 Boot media type is: harddisk El Torito image starts at sector 27 and has 63488 sector(s) of 512 Bytes Image has been written to file "bios.img".
Now that you’ve written to
bios.img
, attach your USB and usefdisk
to see the letter assigned to the drive.❯ lsblk -p NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT /dev/sda 8:0 0 149.1G 0 disk ├─/dev/sda1 8:1 0 300M 0 part /boot/efi └─/dev/sda2 8:2 0 148.8G 0 part / /dev/sdb 8:16 1 14.7G 0 disk └─/dev/sdb1 8:17 1 31M 0 part
In our scenario, the drive is
/dev/sdb
. Validate that none of the partitions contain a mount underMOUNTPOINT
column. If they do, unmount each of them withumount /dev/sdbX
where X is the partition number ex:umount /dev/sdb1
Write the img file to USB with
dd
. Provide theif
argument your/path/to/bios.img
file andof
argument your USB drive name - ex:/dev/sdb
. You can provide optionalstatus=progress
argument to get progress output.❯ sudo dd if=bios.img of=/dev/sdb bs=1M 31+0 records in 31+0 records out 32505856 bytes (33 MB, 31 MiB) copied, 4.72535 s, 6.9 MB/s
Restart your computer and load up BIOS settings to validate that Legacy boot is enabled. Now boot into your USB drive and follow the instructions on screen. Validate that your battery has significant charge and is plugged into AC power. Choose
Update system program
to update the BIOS.Wait till the update is complete.
BIOS updates may continue to happen even after reboot. Respect that and keep AC power plugged in and continue to follow on-screen instructions!
Validate the BIOS has been upgraded by booting back into and running
dmidecode
.❯ sudo dmidecode -s bios-version 8CET66WW (1.46 )