LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   cant boot (https://www.linuxquestions.org/questions/linux-newbie-8/cant-boot-520572/)

kanishk 01-18-2007 12:39 PM

cant boot
 
i am using fedora5 but can't boot

wat i've done is

root (hd0,5)

kernel /boot/vmlinuz-2.6.15-1.2054_FC5 ro root=LABEL=/ rhgb quiet


but it says file not found...
though partition is recognised correctly...
do i need to modify grub.conf ???
how to do that???
pl help!!

tuxrules 01-18-2007 01:38 PM

Quote:

Originally Posted by kanishk
i am using fedora5 but can't boot

wat i've done is

root (hd0,5)

kernel /boot/vmlinuz-2.6.15-1.2054_FC5 ro root=LABEL=/ rhgb quiet


but it says file not found...
though partition is recognised correctly...
do i need to modify grub.conf ???
how to do that???
pl help!!

Are you sure your root partition is (hd0,5) which would be hda6 since grub counts partitions starting from zero.

You can either edit the grub entries right when it tries to boot or you can boot via a live-cd and then change the grub configuration file. The file is most likely located in /boot/grub. File name can be either menu.lst or grub.conf.

saikee 01-18-2007 01:54 PM

Actually it is quite easy to solve.

press "c" to get a Grub prompt if you have not already done it.

Ask Grub where is the partition that has grub.conf by
Code:

find /grub/grub.conf
or just
Code:

find grub.conf
You can ask Grub to display the grub.conf by "cat" command

My guess is you may have a problem with /etc/fstab. I don't like Fedora's way of addressing its root by a label in a hard disk and change it to the standard device name, as used in every other Linux, in all the Red Hat I have.

kanishk 01-18-2007 02:37 PM

by "cat" command u mean i just enter cat and then i can edit grub.conf right?
thanks btw

saikee 01-18-2007 02:49 PM

Yep

This is the way you can get Grub to display the way it boots every system so that you can manully boot each one yourself if you want to alter the paramters.

Also Grub obeys the "tab" key so if you type
Code:

kernel /boot/vmlinuz-
and then press the "tab" key Grub will find a match and comes back with a suggestion of
Code:

kernel /boot/vmlinuz-2.6.15-1.2054_FC5
So make Grub works for its living!

kanishk 01-18-2007 03:12 PM

ok il do that in the time i tried to find
/grub/grub.conf
but it said file not found
and the same result for
find vmlinuz

???
anyway will post after trying again...

michaelk 01-18-2007 03:23 PM

fedora uses /etc/grub.conf

saikee 01-18-2007 03:24 PM

Deleted temporary

kanishk 01-18-2007 03:44 PM

kernel wasn't found and this was the output of grub.conf

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,7)
# kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
# initrd /initrd-version.img
#boot=/dev/sda
default=1
timeout=5
splashimage=(hd0,7)/grub/splash.xpm.gz
#hiddenmenu
title Fedora Core 5 (2.6.15-1.2054_FC5smp)
root (hd0,7)
kernel boot/vmlinuz-2.6.15-1.2054_FC5smp ro root=LABEL=/1 rhgb quiet
initrd boot/initrd-2.6.15-1.2054_FC5smp.img
title Windows XP
rootnoverify (hd0,0)
chainloader +1

kanishk 01-18-2007 03:45 PM

deleted temporary...as in?

pixellany 01-18-2007 03:46 PM

Could you post the output of fdisk -l (run this as root)

Note that the root (hdX,Y) entry must point to the partition which contains the /boot directory. This might not be the same as where the kernel will try to mount the root (/) of the filesystem

kanishk 01-18-2007 03:50 PM

i had tried it but said unrecognized command
could u pl tell the exact command as i am a newbie
just
fdisk -l didnt work

saikee 01-18-2007 03:59 PM

Life must be kind to me as I seem to have plenty of grub.conf

I got

31 /boot/grub/grub,conf
97 /boot/grub/menu.lst
31 /boot/etc/grub.conf

I always install a Linux in a single partition and so my /boot is a subdirectory of / in every case. That is why my /boot/grub/grub is the same as another user's /grub/grub.conf stored in a dedicated /boot partition. Also I also edit menu.lst and disregard grub.conf.

In the above it would suggest whever we have /etc/grub.conf we should have /grub/conf as a symbolic link (and also menu.lst). I know Grub cannot read a LVM and that is why every Red Hat must have a separate /boot partition (unless you do not use LVM and use a single partition like me). The /boot partition is always non-LVM.

Therefore Grub cannot access the /etc/grub.conf, as it will be inside the LVM, and must boot according to the grub.conf stored in the /boot partition or directory.
-------------------------
kanishk,

You have to do a
Code:

sudo fdisk -l
Code:

[root@localhost ~]# grub
Probing devices to guess BIOS drives. This may take a long time.


    GNU GRUB  version 0.97  (640K lower / 3072K upper memory)

 [ Minimal BASH-like line editing is supported.  For the first word, TAB
  lists possible command completions.  Anywhere else TAB lists the possible
  completions of a device/filename.]
grub> find /boot/grub/grub.conf
find /boot/grub/grub.conf
 (hd0,9)
 (hd0,10)
 (hd0,20)
 (hd0,21)
 (hd0,23)
 (hd0,24)
 (hd0,28)
 (hd0,29)
 (hd0,32)
 (hd0,46)
 (hd0,57)
 (hd0,58)
 (hd0,59)
 (hd1,6)
 (hd1,10)
 (hd1,12)
 (hd1,13)
 (hd1,20)
 (hd1,21)
 (hd1,27)
 (hd1,29)
 (hd1,30)
[Hit return to continue]
                        (hd1,33)
 (hd1,35)
 (hd1,39)
 (hd1,51)
 (hd1,54)
 (hd1,55)
 (hd1,57)
 (hd3,7)
 (hd4,8)
 (hd4,14)
grub> find /boot/grub/menu.lst
find /boot/grub/menu.lst
 (hd0,2)
 (hd0,5)
 (hd0,7)
 (hd0,10)
 (hd0,11)
 (hd0,12)
 (hd0,13)
 (hd0,18)
 (hd0,20)
 (hd0,21)
 (hd0,22)
 (hd0,23)
 (hd0,24)
 (hd0,28)
 (hd0,29)
 (hd0,30)
 (hd0,31)
 (hd0,32)
 (hd0,33)
 (hd0,35)
 (hd0,36)
 (hd0,42)
[Hit return to continue]
                        (hd0,43)
 (hd0,44)
 (hd0,45)
 (hd0,46)
 (hd0,47)
 (hd0,48)
 (hd0,51)
 (hd0,53)
 (hd0,55)
 (hd0,56)
 (hd0,57)
 (hd0,58)
 (hd0,59)
 (hd0,60)
 (hd0,62)
 (hd1,0)
 (hd1,1)
 (hd1,6)
 (hd1,10)
 (hd1,12)
 (hd1,13)
 (hd1,14)
[Hit return to continue]
                        (hd1,15)
 (hd1,17)
 (hd1,20)
 (hd1,21)
 (hd1,22)
 (hd1,24)
 (hd1,26)
 (hd1,27)
 (hd1,28)
 (hd1,29)
 (hd1,30)
 (hd1,32)
 (hd1,33)
 (hd1,34)
 (hd1,35)
 (hd1,37)
 (hd1,38)
 (hd1,39)
 (hd1,40)
 (hd1,41)
 (hd1,42)
 (hd1,43)
[Hit return to continue]
                        (hd1,44)
 (hd1,45)
 (hd1,46)
 (hd1,47)
 (hd1,48)
 (hd1,49)
 (hd1,50)
 (hd1,51)
 (hd1,53)
 (hd1,54)
 (hd1,55)
 (hd1,56)
 (hd1,57)
 (hd2,5)
 (hd3,2)
 (hd3,6)
 (hd3,7)
 (hd3,9)
 (hd3,10,f)
 (hd3,10,g)
 (hd3,11)
 (hd3,12)
[Hit return to continue]
                        (hd3,13)
 (hd4,2)
 (hd4,4)
 (hd4,5)
 (hd4,6)
 (hd4,7)
 (hd4,8)
 (hd4,9)
 (hd4,10)
 (hd4,11)
 (hd4,12)
 (hd4,13)
 (hd4,14)
grub>

grub> find /etc/grub.conf
find /etc/grub.conf
 (hd0,10)
 (hd0,11)
 (hd0,20)
 (hd0,21)
 (hd0,23)
 (hd0,24)
 (hd0,28)
 (hd0,29)
 (hd0,32)
 (hd0,42)
 (hd0,46)
 (hd0,57)
 (hd0,58)
 (hd0,59)
 (hd1,10)
 (hd1,12)
 (hd1,13)
 (hd1,20)
 (hd1,21)
 (hd1,27)
 (hd1,30)
 (hd1,33)
[Hit return to continue]
                        (hd1,35)
 (hd1,49)
 (hd1,51)
 (hd1,54)
 (hd1,55)
 (hd1,56)
 (hd1,57)
 (hd4,8)
 (hd4,10)
 (hd4,14)
grub>


pixellany 01-18-2007 05:12 PM

Quote:

Originally Posted by kanishk
i had tried it but said unrecognized command
could u pl tell the exact command as i am a newbie
just
fdisk -l didnt work

You have to run this command as the root user.

At least two ways to do it:
su to get root access, then fdisk -l
or
sudo fdisk -l

On some systems you might have to use /sbin/fdisk (or do "su -" to actually become the root user)


All times are GMT -5. The time now is 07:34 AM.