LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Reply
  Search this Thread
Old 06-23-2006, 06:10 AM   #1
pushtostart
LQ Newbie
 
Registered: Jun 2006
Posts: 9

Rep: Reputation: 0
Boots to grub; can't FIND grub.conf, start1


Hello all, I hope that I don't frustrate the forum with my first post. I am new to linux, but am otherwise pretty comfortable with computers. Here's my issue:

I had a good installation of Core 5 running. I wanted to try to load DSL onto my USB Flash Drive. After booting off of DSL and trying to start Frugal Lite to perform the installation, which is what I thought needed to be done, the process seemed to hang at a line creating a directory in /etc/...
After several minutes I was impatient, and somewhat concerned about my nice new Core 5 installation. I rebooted the machine and pulled out the CD and was met with:
GRUB>

I'm new to all of this so I started doing some research. I checked my partitions, which were still the default:
HD0,0
HD0,1

I tried FIND /boot/grub/grub.conf and FIND /boot/grub/start1 and found nothing. I don't recall if those were the exact paths offhand, but I had copied them verbatim from a forum. I also wasn't able to mount the partition /dev/hda.

Next, I rebooted to the Core 5 Installation Disc 1 and started linux rescue. When I got to the shell, I typed chroot /mnt/sysimage. I tried to edit the HD for grub.conf with nano, but it I'm greeting with a new file.

What should I run, check, modify to get grub to start Fedora again? Please include commands and paths as I'm still learning the environment. Any help would great!

Thanks!
Bryan
 
Old 06-23-2006, 06:21 AM   #2
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
Quote:
I tried FIND /boot/grub/grub.conf and FIND /boot/grub/start1 and found nothing.
The default location for grub.conf is /etc and not /boot.
Quote:
I also wasn't able to mount the partition /dev/hda.
/dev/hda refers to a whole drive and not just a partition, you should try
Code:
fdisk -l
to see what your partitions are example /dev/hda1, /dev/hda2

boot with the fedora cd in rescue mode and after the chroot /mnt/sysimage try this

Code:
grub-install hd0
 
Old 06-23-2006, 07:55 AM   #3
pushtostart
LQ Newbie
 
Registered: Jun 2006
Posts: 9

Original Poster
Rep: Reputation: 0
Thank you prozac! I'll try those out tonight and report back.

Does anyone know of a pdf or other file that lists out the directory structure for fedora, as a reference?
 
Old 06-23-2006, 07:56 AM   #4
prozac
Member
 
Registered: Oct 2005
Location: Australia
Distribution: slackware 12.1
Posts: 753

Rep: Reputation: 32
the directory structure is more or less same for every other distro with minor exceptions.
 
Old 06-23-2006, 08:04 AM   #5
decrepit
Member
 
Registered: May 2006
Distribution: Ubuntu10.04, < fedora12
Posts: 347

Rep: Reputation: 34
I'm not a linux expert, but on all my installation grub.conf is in /boot/grub, but in this core4 installation there is a link in /etc to grub.conf.

[mike@core4 ~]$ cd /boot/grub
[mike@core4 grub]$ ls
device.map grub.conf minix_stage1_5 stage2
e2fs_stage1_5 iso9660_stage1_5 reiserfs_stage1_5 ufs2_stage1_5
fat_stage1_5 jfs_stage1_5 splash.xpm.gz vstafs_stage1_5
ffs_stage1_5 menu.lst stage1 xfs_stage1_5
 
Old 06-23-2006, 08:30 PM   #6
pushtostart
LQ Newbie
 
Registered: Jun 2006
Posts: 9

Original Poster
Rep: Reputation: 0
Code:
fdisk -l
returned:
/dev/hda1
/dev/hda2
with hda1 being marked as boot.

When I ran
Code:
grub-install hd0
This message was returned:
The file /boot/grub/stage1 not read correctly.

What should I check or do next? Is grub hosed?

Thanks!
 
Old 06-23-2006, 09:16 PM   #7
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,131

Rep: Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121Reputation: 4121
The files you were looking for were "menu.lst" and "stage1" - as per the ls above from decrepit.
Try the find commands again (correct this time ) and use the partition returned (say (hd0,0) ) in the following
Code:
root (hd0,0)
setup (hd0)
reboot
If that doesn't work, yes your grub is hosed.

EDIT: you may need to do the find against /grub/... rather than /boot/grub/... - at that stage, Linux mounts are assumed for /boot even though Linux hasn't been loaded as yet.

Last edited by syg00; 06-23-2006 at 09:18 PM.
 
Old 06-24-2006, 07:36 AM   #8
pushtostart
LQ Newbie
 
Registered: Jun 2006
Posts: 9

Original Poster
Rep: Reputation: 0
Thanks syg00!

I tried the FIND and came up null.
root (hd0,0)
Filesystem type unknown, partition type 0x83
setup (hd0)
Error 17: Cannot mount selected partition

So this isn't good. How can I reinstall GRUB? I was reading that I can boot Linux manually by loading the kernel, but I'd have to find the full kernel name. Should I use the rescue CD to do that? I would be running something like:
root (hd0,0)
kernel <kernel name> ro root=hd0
boot
correct?
The syntax is a bit off, so I'll have to recheck it. I would like to rescue this machine rather than reinstall everything. Thanks for all of your help!
 
Old 06-24-2006, 08:49 AM   #9
Trip in VA
Member
 
Registered: Dec 2003
Location: Charlotte Co., VA, USA
Distribution: Aptosid
Posts: 34

Rep: Reputation: 15
Manually booting is not that difficult, it's just intimidating. I know; I've done it more than once when I screwed up GRUB.

You've got the basic idea down. Did you have /boot on a different partition? If not, it could change how you have to do this; these instructions assume a separate /boot partition on /dev/hda1.

root (hd0,0)

What you can do to figure out your kernel is to type the 'vmlinuz' or some part of the kernel name (if it's Fedora's default, it will be vmlinuz{number}) and press tab. Assuming it's reading the partition correctly, that is. So you'll type this (the {tab} is where you press tab to get the number):

kernel vmlinu{tab} root=/dev/hda1 ro

Then, to get it started, you type 'boot' as shown.

At least, that's been my experience. If you don't have a separate /boot partition, you might need to alter this line accordingly:

kernel boot/vmlinu{tab} root=/dev/hda1 ro

Let us know how it works out.

- Trip
 
Old 06-25-2006, 09:24 AM   #10
pushtostart
LQ Newbie
 
Registered: Jun 2006
Posts: 9

Original Poster
Rep: Reputation: 0
Thanks for your help Trip in VA!

It doesn't look good:

kernel vmlinu<tab>
Error 11: Unrecognized device string

kernel /vmlinu<tab>
Error 17: Cannot mount the selected partition

kernel /boot/vmlinu<tab>
Error 17: Cannot mount the selected partition

It looks like it's time to start over. I was just getting ndiswrapper going to try and use my wireless card and get online. Oh well, I hope I took good notes! Thanks for everyone's help, I did learn a bit more about the evironment though.
 
Old 10-09-2006, 05:01 PM   #11
daveymg
LQ Newbie
 
Registered: Aug 2003
Location: New Zealand
Distribution: Fedora Core
Posts: 4

Rep: Reputation: 0
Quote:
Originally Posted by pushtostart
Thanks for your help Trip in VA!

It doesn't look good:

kernel vmlinu<tab>
Error 11: Unrecognized device string

kernel /vmlinu<tab>
Error 17: Cannot mount the selected partition

kernel /boot/vmlinu<tab>
Error 17: Cannot mount the selected partition

It looks like it's time to start over. I was just getting ndiswrapper going to try and use my wireless card and get online. Oh well, I hope I took good notes! Thanks for everyone's help, I did learn a bit more about the evironment though.
I got to this thread after researching for a solution to the same problem/symptom. FWIW, I was able to correct the problem by booting from the FC CD, going into rescue mode and issuing the command fsck -y /dev/hda1

The fsck fixed many problems on hda1, after which I was able to reboot the system correctly.

My original problem occurred after the machine was powered of without being shutdown cleanly.

dg
 
  


Reply

Tags
find, grub, grubconf, harddrive, partition



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
grub can find grub.conf, how do i make it permanent? lankydenny Linux - Newbie 8 06-13-2006 06:47 PM
FC4 - I Cannot Find Grub.conf fortezza Fedora 11 11-21-2005 08:52 AM
How do I select which kernel the server boots with? grub.conf? abefroman SUSE / openSUSE 3 06-20-2005 02:56 PM
Is there a way to change which kernel/os boots without modifying grub.conf? niverson Linux - Software 2 01-05-2005 04:14 PM
boot stops at GRUB GRUB linux never boots coffeedemon Slackware 4 11-09-2004 02:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 08:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration