Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Having issues with Grub's Error 21?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
Mekoryuk
Apprentice
Apprentice


Joined: 17 Sep 2003
Posts: 174

PostPosted: Sat May 08, 2004 5:18 pm    Post subject: Having issues with Grub's Error 21? Reply with quote

This was a thorn in my side for quite a while, as I had never encountered it during previous Gentoo installs. Turns out that realization of no problems before was part of the solution!

Please note that this might not solve your problem. There could be other problems responsible for receiving an Error 21 when it comes time to install your bootloader. However, due to the nature of the problem I encountered, I decided to post this, as I think it might affect more than a few people. If just a few are able to find it handy, then I'll be happy.

The problem arises when, in Gentoo 2004.1 (and maybe 2004.0, I need to check this), one tries to install a bootloader when one has their hard disk drives on /dev/hde or above (this problem, AFAIK, doesn't affect those starting from Stage 1).

The thing is, with the latest stage tarballs, there isn't a /dev/hde or above inside them. So when one tries:

Code:
grub> root (hd0,0)


or similar, it brings back:

Code:
Error 21:  Selected disk does not exist


Tab completion doesn't help, since grub, and your chrooted Gentoo environment, can't even see your hard drives, because they just aren't there under your /dev directory.

After much fretting, I finally discovered the solution to be tracking down an old tarball (I used the stage3-i686-20030910.tar.bz2 tarball), unpacking it into a temporary directory with the -xvjpf options (you don't have to let it all unpack. Watch for all the dev entries to get extracted, and you can hit ctrl+c to avoid waiting a few minutes for it to finish), going into the temp's dev/ directory, and copying over the missing device files over to your real dev directory:

Code:
$ cp hde* /dev


Make sure that if you execute the above line, you're actually chrooted into your Gentoo install. Otherwise, just remember that it's /mnt/gentoo/dev instead.

That's about it in a nutshell. I hope somebody else finds this useful, as I've tried googling and searching the forums myself when I was plagued by it, and didn't uncover much that was useful.

Hopefully the Gentoo devs will remember to put /dev/hde and above back into their stage tarballs the next time around. :)
Back to top
View user's profile Send private message
nazgum
Tux's lil' helper
Tux's lil' helper


Joined: 19 Apr 2003
Posts: 111
Location: Canada

PostPosted: Sat Jul 03, 2004 2:14 am    Post subject: Reply with quote

just wanted to post to say this helped me out with my new laptop :)

thanks!

Edit: hehe actually I figured it would have, but i can't seem to copy the hde files to my /dev dir. It just hangs when I try. Any suggestions for me? :)

Edit Again: Ok I found out MV works for these files but CP will hang, so if you are trying to do this, use MV
_________________
Jabber: nazgum@jabber.org
Back to top
View user's profile Send private message
Fluffy`
n00b
n00b


Joined: 02 Jul 2003
Posts: 54

PostPosted: Mon Jul 05, 2004 7:34 pm    Post subject: Reply with quote

I reinstalled Gentoo on my router/file server/"irc client in a screen" machine. Installation work but at grub this weird error came. After a phone call to a person I did put my router back as it was before reinstall and searched here.

Thanks! :)

I downloaded 2004.1 i686 today and that file missed it. Don't remember files date.


EDIT!
My router is a P3 450 with a old BX motherboard (Shuttle HOT-661) from 98 or something. For UDMA100 I have a controllercard running the disks on for better performance. Systemdisk is hde.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum