geek software tips ubuntu

how to fix GRUB problems

cc-licensed photo by \in`som´ni`ous\
photo by \in`som´ni`ous\

After replacing a dead power supply I found out my GRUB boot menu refused to start the selected OS.
It just spat out this horrifying message:

Grub Error 21: Selected disk does not exist

After some Google-ing and asking some questions in the #grub IRC channel I downloaded a tool called SuperGrubDisk, wrote it to an oldskool floppy disk and managed to boot Windows and Ubuntu once again.

Now I at least knew my system wasn’t completely screwed, and it was just GRUB acting up for some reason. Well the reason was actually that during the initial installation my hard drive was recognized as hd1 instead of hd0. For some reason this had now changed after unplugging and replugging cables to replace the power supply. Thanks to SuperGrubDisk I managed to figure out this was the problem.

Using info on their wiki I figured out the GRUB configuration file is located in /boot/grub/menu.lst, and can be edited with any text editor. After manually changing the HD settings, all is well again.
So hurray for open source, and configuration files in plain text format!

While I was in there, I also changed the default startup OS and shortened the default 10 seconds to five. I must have thought about doing that for ages, but never got around to it.

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.