How to upgrade your system BIOS using FreeDOS

Upgrading your BIOS can seem tricky for free software users, but it doesn't have to be.
623 readers like this.
System statistics with sar and the /proc filesystem

ajmexico. Modified by Jason Baker. CC BY-SA 2.0.

It is not often that most of us need to update the BIOS in our host computers.

In fact, most motherboard manufacturers, including Intel, recommend against upgrading BIOS unless there is a specific problem that an upgrade to a specific BIOS level will fix. Most sysadmins also would agree that "if it is not broken, don't fix it." Upgrading BIOS just to get to the latest level is counter-productive in terms of the time it takes, but also can cause problems that did not previously exist.

But sometimes it does become necessary. And that can be a problem for those of us who don't use Windows in any form, like me. There is a Windows application that can install BIOS upgrades on modern computers while Windows is running but that is obviously not an option for me. So I need to approach BIOS upgrades a bit differently.

The objective

This all started one day recently when I decided to upgrade two of my older Linux systems.

I have been running BOINC for several years to participate in various distributed computing environments and have been using those two computers almost exclusively as compute platforms for that purpose. I decided that I wanted to add more computing power to those tasks so decided to update some of my older computers rather than purchasing new ones. After all, these are perfectly good computers with yet untapped capabilities. And—being the geek that I am—I also just wanted another hardware project with at least some little bit of justification. You all know what I mean, right?

I originally used these two identical systems in a classroom environment where raw performance was not an issue. I purchased them several years ago from the local Intrex computer store with Intel DH61BE motherboard that supports third-generation Core i3, i5, and i7 processors in the LGA1155 package at up to 3.5GHz. At the time these were pretty close to state of the art but not top of the line. I installed Core i3 G620 CPUs with 2 cores and no hyperthreading at 2.6GHz. They worked perfectly for my classroom.

These days both of these systems run BOINC. In addition, I use one for testing Fedora upgrades and other new software, and I use the other as a firewall and router for my network.

To upgrade, I purchased a pair of unlocked Intel 17-3770K at 3.5GHz processors to replace the existing ones. These are the fastest ones available for those motherboards and my research on the Intel website revealed that these processors would work. I also purchased non-standard CPU coolers with a higher cooling capacity than the ones that come packaged with the CPUs.

The problem

After receiving the replacement processors I installed one in the test system because it does not perform any tasks critical to my network. Upon attempting to power up the system, I received nothing but a repeating pattern of three one second beeps from the motherboard speaker. The motherboard documentation—yes, I download and keep it—translated that as meaning the system had a memory error. Of course, it was perfectly good memory right in the middle of the spec for the new processor.

At this point, I could not get to the BIOS to do any configuration so I removed the new CPU and put the old one back in. This at least allowed the system to boot and let me get to BIOS to check the BIOS version level and, using the Intel support website, found that to be many levels behind the most current.

There is another way to locate the BIOS level from the Linux command line and I rebooted into Fedora 25 and used the dmidecode command to locate the current BIOS. The -t option specifies the type information to be displayed, in this case, type 0 is for BIOS information.


# dmidecode -t 0 
# dmidecode 3.0 
Getting SMBIOS data from sysfs. 
SMBIOS 2.6 present. 

Handle 0x0000, DMI type 0, 24 bytes 
BIOS Information 
       Vendor: Intel Corp. 
       Version: BEH6110H.86A.0048.2012.1105.1520 
       Release Date: 11/05/2012 
       Address: 0xF0000 
       Runtime Size: 64 kB 
       ROM Size: 1024 kB 
       Characteristics: 
               PCI is supported 
               BIOS is upgradeable 
               BIOS shadowing is allowed 
               Boot from CD is supported 
               Selectable boot is supported 
               BIOS ROM is socketed 
               EDD is supported 
               5.25"/1.2 MB floppy services are supported (int 13h)
               3.5"/720 kB floppy services are supported (int 13h) 
               3.5"/2.88 MB floppy services are supported (int 13h)
               Print screen service is supported (int 5h) 
               8042 keyboard services are supported (int 9h) 
               Serial services are supported (int 14h) 
               Printer services are supported (int 17h) 
               ACPI is supported 
               USB legacy is supported 
               BIOS boot specification is supported 
               Targeted content distribution is supported

Listing 1: Using the dmidecode command to locate BIOS information.

The output of the dmidecode command shown above shows the BIOS version of BEH6110H.86A.0048.2012.1105.1520. This information is from one of the hosts I upgraded after doing the BIOS upgrade. Well, I wasn't thinking about writing about this at that point in my travails.

We can decode most of the fields in this version number by assuming that the dots are field separators. The first field is the board model number and the second is probably an engineering release level. The third field, 0048, is the actual BIOS version level, and is what appears in the Intel web pages; if someone says you need to be at BIOS version 48, that is the number to look at. Field number four is the year and field five is the month and day in MMDD format in which the BIOS was released. I don't know for certain what the last field is, but I think it might be a time in 24-hour format so that the last three fields represent the date and time the BIOS was compiled.

My original BIOS was version 23 and, according to the Intel website, the most current version is 120. Note that not all of the intervening BIOS version numbers were released to the public, but there were still 20 versions posted and 17 were more recent than mine.

So I downloaded the most recent and tried to use the F7 option at boot time to upgrade the BIOS. What this means is that the initial BIOS display at boot time includes an F7 option in addition to F2 to enter BIOS configuration and F10 to enter the Boot options menu. I pressed F7 and selected the BIOS file that I had placed on a FAT formatted USB stick. That failed and the system just locked up when I tried that. Some additional searching with Google and in particular on the Intel website provided me with a bit more information.

First, my BIOS version did not actually support F7 at boot time despite the fact that the option did appear on the BIOS screen. Second, a very obscure response to another user indicated that not all BIOS versions would install directly, and it would be necessary to install multiple BIOS revisions in sequence.

If I had a copy of DOS I could use one of Intel's other programs for updating BIOS, iFlash.exe. In order to overcome that problem without spending any money, I performed a fruitless search and discovered that I did not have a copy of DOS.

FreeDOS

At this point, I remembered that Opensource.com's own Jason Baker had written an interview with FreeDOS developer, Jim Hall, Keeping DOS alive and kicking with open source. After rereading that article, I went to the FreeDOS website and checked it out. FreeDOS is open source software and is licensed under the GPL.

With a little more googling I also discovered a website titled, Creating a FreeDOS bootable USB stick to upgrade BIOS, which sounded like exactly what I needed. The instructions there are quite clear and include all of the necessary commands required to create the bootable FreeDOS USB stick. I copied the *.BIO files to the USB device.

The FreeDOS that is downloaded using these instructions is version 1 which is a bit old. But is works and that is all that is necessary. The current version is 1.2.

Doing the update

After I created my FreeDOS bootable USB stick, I copied the BIOS files to the USB stick, used the boot menu to boot from the USB device, and ran the iflash.exe program according to the instructions on the Intel website. The only thing you really need to know from that page is to use the command IFLASH2.EXE /PF XXX.BIO where XXX is the name of the BIOS file.

My first attempt did not work because I still skipped too many BIOS versions for it to work. So I went back even further, to the revision immediately after the one on my system and that one worked just fine. It only took a couple minutes and the computer rebooted itself before starting the actual upgrade and then again after. I then upgraded to the minimum version I needed to support my CPU which, according to the Intel website, was BIOS version 48. I installed the new CPU and rebooted successfully. BIOS rev 48 is also the version required to enable further BIOS upgrades using the F7 option.

I did not upgrade any further even though there are still several newer versions available. The Intel website, as well as most sysadmins I know, always recommend only upgrading the BIOS if absolutely necessary. Intel also recommends only upgrading to the minimum version required to resolve the extant problem. So that is what I did.

Final thoughts

My Chrome browser automatically renamed the *.BIO files to *.BIN and I have no idea why. Just be sure to rename them to *.BIO or the iflash program will not recognize them.

Research in advance the compatibility of any hardware you want to use to upgrade your system. Be certain that you understand the problems you might face while hacking your hardware. It is not possible to always discover all the pitfalls, especially if you are not sure what to look for but you should always be able to determine whether the manufacturer supports a particular motherboard, memory, and CPU combination. If you run into problems, more Internet searches can usually lead to one or more clues about how to proceed or where to look further.

I have never used unlocked processors before but I found no real difference in getting them installed and configured. Mine work very well and I really like the performance improvement. I monitor the CPU temperatures but so far the temperatures are remaining in the mid-70s (Celcius), which is well within the normal operating range.

I do enjoy hardware hacking and in this case, it was definitely cheaper than purchasing a new motherboard, CPU, and memory combination for two computers. It was also more fun and a very enlightening learning experience. It was particularly enlightening because I learned that I can use open source software to upgrade BIOS on Intel motherboards and that was one of my main objectives.

Oh, by the way—does anyone need a couple used Intel i3 G620 CPUs?

David Both
David Both is an Open Source Software and GNU/Linux advocate, trainer, writer, and speaker. He has been working with Linux and Open Source Software since 1996 and with computers since 1969. He is a strong proponent of and evangelist for the "Linux Philosophy for System Administrators."

3 Comments

Thanks for this. Give the recent AMT exploits found in the Intel chips, it looks like I'll be updating firmware very soon.

I imagine this would work for any desktop/laptop? (Lenovo ThinkPad T-420 & T-430) I'm wanting to not only upgrade the BIOS but the processors as well...(from i5's to i7's) Maybe this can help me do that? I so love these devices, as they're sturdy and are deigned to DO things on! They might not look flashy or have shiny builds, but they're workhorse and handle everything I throw at them...I just want to upgrade their innards to better specs. Hopefully the links you've provided can give me some guidance on getting this done. Thanks for the great article!

I have always upgraded to the latest version of BIOS available and have had no problems doing so. As a System Administrator of about 120 servers uprgrading BIOS was for me part of routine maintenance when doing major upgrades and usually one of the first things to do when encountering hardware issues. Manufacturers do not very often advertise what problems the BIOS upgrades fix, but usually I feel there is no point finding out the hard way. Why not put the most recent version on, since it has solved all problems known to that point in time?

Creative Commons LicenseThis work is licensed under a Creative Commons Attribution-Share Alike 4.0 International License.