CMOS scheeMOS, clean up after yourself

I have had a problem with my home computer for some time.  It doesn’t quite boot right.  That is to say, when you turn it on, it actually doesn’t start windows or anything.  I have done some investigations and found out that when the computer is booting up it encounters a POST request of 36 and then it stops.  The workaround for this problem was to turn it off, and then after about 10-15 seconds turn it back on.


Yet, as this has bothered me for some time and eventually I did do a bit of research.  The answer that most people seemed to agree on was that the CMOS needed to be reset. I guess must have been living under a lucky star as with all of my computers I have never actually had this problem.  I have seen the battery go bad, problems with hard disks, windows patches mess things up, but never had this exact problem.

Perhaps I should set the stage.  My personal computer is fairly old as I have had it for six or seven years.  It was assembled with some assistance from my friend out of the following main parts.

Gigabyte FX v4.0 eXtreme
AMD 8350
blue ray dvd
8 GB

The machine had Windows 7 installed but it also had a dual boot for Linux Mint.  I didn’t want a hodgepodge of boot screens so I installed rEFInd as a unifying boot manager.  One boot manager to allow me to easily and graphically decide which operating system.

Resetting the CMOS won’t really be removing any of the files or changing the flle system but I keep putting this off this “small fix”.  That nagging little part of my brain that probably knows better but just last weekend I decided to cross that item off my list.  The process took about 15 minutes if you include moving the computer, cleaning out the dust bunnies, and replacing one of my fans.

The computer booted into windows on the very first try – one problem down.  This would have been good news except the boot manager should be the one getting booted.  It only took me a minute to discover that my boot manager was now gone.  That is to say, it was no longer considered to be a boot device by the motherboard.  Just the drives and the windows boot manager were the only possibilities.  It must have taken me 10 minutes to remember that last time I was fooling around with a linux tool to install rEFInd as an option to the listed among the boot devices.

$ sudo efibootmgr
BootCurrent: 0000
Timeout: 4 seconds
BootOrder: 0001,0000,0006,0005,0004,0003
Boot0000* rEFInd
Boot0001* Windows Boot Manager
Boot0003* Hard Drive
Boot0004* CD/DVD Drive
Boot0005* USB
Boot0006* UEFI: Built-in EFI Shell

Google did help me to find that this tool was probably efibootmgr but what was the exact syntax.  I booted up with a boot DVD and mounted the UEFI boot partition but I must have had a typo as it was showing me the old 8.3 files with two versions of rEFInd.


That didn’t seem right. I suspected that at that time I was fooling with a new version and simply failed to delete the old files.  Reboot, mount the boot partition correctly and then take a closer look.

The file system is correctly mounted but I am not sure why I have both the 32 and 64 bit versions in my refind directory.  Type first, think later. I take a look some other examples of how to add back my boot manager but now I have quite a few different combinations ahead of me.

efibootmgr -c -d /dev/sda -L refind -l fs0:\EFI\refind\refind_x64.efi
efibootmgr -c -d /dev/sda -L refind -l fs0:\EFI\refind\refind_ia32.efi
efibootmgr -c -d /dev/sda -L refind -l \EFI\refind\refind_x64.efi
efibootmgr -c -d /dev/sda -L refind -l \EFI\refind\refind_ia32.efi

Each time I try one of these options I have to reboot everything.  If this doesn’t work then I need to delete that boot manager entry.

efibootmgr -Bb 0000

The only problem is that my entry is not 0000 but 0001.  Copy, fix, run, reboot, copy, fix, run, reboot, ….

I imagine it was fate that had me delete entry 0000 not 0001.  I am not happy that Linux wasn’t working but now I am less happy that the windows boot process has been deleted.

Can I possibly stay cool long enough to fix this?  Maybe.  I have gone through all the possibilities in my list but I have had no success.

I could have tried to install a newer version of Linux but that both feels like cheating but also may be delaying the problem another 30 minutes. I decided to go back to the source and take a look at the excellent page by Rod Smith. .  I was actually a victim of Microsoft and their backslashes, well that and my apparent inability to delete the old unused configurations and files.

After using a few more slashes everything comes up roses.

efibootmgr -c -l \\EFI\\refind\\refind_x64.efi -L rEFInd

This time I need to not only make some notes, but I also need to save them someplace really safe for next time.  Who knows next time it might be an upgrade or replacing a disk after a crash.

This entry was posted in Setup From Scratch. Bookmark the permalink.