LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 11-13-2005, 11:18 PM   #1
fortezza
Member
 
Registered: Mar 2003
Location: Colorado
Distribution: Fedora Core 4
Posts: 297

Rep: Reputation: 30
FC4 - I Cannot Find Grub.conf


What I need this for only matters when I boot up Linux, the default Kernel is not the one I want, so I need to reorder the kernel load list. I used to do this by editing grub.conf, but with recently installed FC4, I cannot find grub.conf.

If I look in /etc/, there is no grub.conf, except for a link to :
lrwxrwxrwx 1 root root 22 Oct 27 22:19 grub.conf -> ../boot/grub/grub.conf

So I go to /boot and look for a grub folder. None there. In fact, check this out:
[root@phobos boot]# ll
total 8748
-rw-r--r-- 1 root root 58658 Oct 19 23:46 config-2.6.13-1.1532_FC4
-rw-r--r-- 1 root root 58595 Oct 20 00:00 config-2.6.13-1.1532_FC4smp
-rw-r--r-- 1 root root 1923345 Oct 28 14:55 initrd-2.6.13-1.1532_FC4.img
-rw-r--r-- 1 root root 1886522 Oct 28 14:20 initrd-2.6.13-1.1532_FC4smp.img
-rw-r--r-- 1 root root 788337 Oct 19 23:46 System.map-2.6.13-1.1532_FC4
-rw-r--r-- 1 root root 816141 Oct 20 00:00 System.map-2.6.13-1.1532_FC4smp
-rw-r--r-- 1 root root 1804356 Oct 19 23:46 vmlinuz-2.6.13-1.1532_FC4
-rw-r--r-- 1 root root 1602204 Oct 20 00:00 vmlinuz-2.6.13-1.1532_FC4smp

Compared with this:
[root@phobos boot]# uname -r
2.6.11-1.1369_FC4

My running kernel isn't in there, is it? Well, maybe I just need to mount the "real" /boot folder. After all, I have this entry in my /etc/fstab file:
LABEL=/boot /boot xfs defaults 1 2

Let's try it, shall we?
[root@phobos boot]# mount /boot
mount: special device LABEL=/boot does not exist

Well maybe it is already magically mounted somewhere else:
[root@phobos boot]# mount | grep boot
[root@phobos boot]#


Looks like I am out of luck here... Short of a reinstall, is there a way to get access to my grub.conf file to make the changes I want to make?

Thank You,



~Fortezza
 
Old 11-14-2005, 12:16 AM   #2
Mad Scientist
Member
 
Registered: May 2003
Posts: 167

Rep: Reputation: 30
Your grub.conf file is in /boot/grub/. You can search for the file with the command

Code:
locate grub.conf
If you get some warning about not having a database or your database being old, switch to root, and run

Code:
updatedb
and then perform the locate command.
 
Old 11-14-2005, 02:07 AM   #3
fortezza
Member
 
Registered: Mar 2003
Location: Colorado
Distribution: Fedora Core 4
Posts: 297

Original Poster
Rep: Reputation: 30
If you look at my original post, I did an "ll" ( aka ls -l ) command on the boot directory, and there are no subfolders to that folder. In addition, I noted there was a soft link called "grub.conf", but it points to a file that does not exist in a folder that does not exist.

However, I did execute the updatedb and locate commands, which located the soft link file I had mentioned in my previous post. Any other ideas out there? Grub must be working and configured b/c I get the kernel menu on bootup, and the system boots and runs Linux like a champ.

~Fortezza
 
Old 11-14-2005, 02:38 PM   #4
Mad Scientist
Member
 
Registered: May 2003
Posts: 167

Rep: Reputation: 30
I'm sorry I missed all of that; I was in a bit of a rush, if I remember correctly. What do

Code:
rpm -q grub
and

Code:
rpm -q --filesbypkg grub
give you?
 
Old 11-15-2005, 12:23 AM   #5
fortezza
Member
 
Registered: Mar 2003
Location: Colorado
Distribution: Fedora Core 4
Posts: 297

Original Poster
Rep: Reputation: 30
No worries. Here is the output of those commands:
# rpm -q grub
grub-0.95-13


#rpm -q --filesbypkg grub

grub /boot/grub
grub /sbin/grub
grub /sbin/grub-install
grub /sbin/grub-md5-crypt
grub /sbin/grub-terminfo
grub /usr/bin/mbchk
grub /usr/share/doc/grub-0.95
grub /usr/share/doc/grub-0.95/AUTHORS
grub /usr/share/doc/grub-0.95/COPYING
grub /usr/share/doc/grub-0.95/ChangeLog
grub /usr/share/doc/grub-0.95/NEWS
grub /usr/share/doc/grub-0.95/README
grub /usr/share/doc/grub-0.95/TODO
grub /usr/share/doc/grub-0.95/menu.lst
grub /usr/share/grub
grub /usr/share/grub/i386-redhat
grub /usr/share/grub/i386-redhat/e2fs_stage1_5
grub /usr/share/grub/i386-redhat/fat_stage1_5
grub /usr/share/grub/i386-redhat/ffs_stage1_5
grub /usr/share/grub/i386-redhat/iso9660_stage1_5
grub /usr/share/grub/i386-redhat/jfs_stage1_5
grub /usr/share/grub/i386-redhat/minix_stage1_5
grub /usr/share/grub/i386-redhat/reiserfs_stage1_5
grub /usr/share/grub/i386-redhat/stage1
grub /usr/share/grub/i386-redhat/stage2
grub /usr/share/grub/i386-redhat/stage2_eltorito
grub /usr/share/grub/i386-redhat/ufs2_stage1_5
grub /usr/share/grub/i386-redhat/vstafs_stage1_5
grub /usr/share/grub/i386-redhat/xfs_stage1_5
grub /usr/share/info/grub.info.gz
grub /usr/share/info/multiboot.info.gz
grub /usr/share/man/man1/mbchk.1.gz
grub /usr/share/man/man8/grub-install.8.gz
grub /usr/share/man/man8/grub-md5-crypt.8.gz
grub /usr/share/man/man8/grub-terminfo.8.gz
grub /usr/share/man/man8/grub.8.gz
 
Old 11-15-2005, 01:50 PM   #6
Mad Scientist
Member
 
Registered: May 2003
Posts: 167

Rep: Reputation: 30
Okay, very interesting. And, when you do

Code:
rpm -q kernel
I assume you see three kernels, right? The one you're running (2.6.11), and then the two 2.6.12 (one up, one smp). Now, have you tried doing an upgrade or a freshen via RPM with the same grub package (i.e. have you downloaded the grub rpm and tried doing this manually)? I would think the package manager would do a diff on the files it needs to install compared with the files already on your system and see that some are missing.
 
Old 11-15-2005, 10:59 PM   #7
dhlawrence
Member
 
Registered: May 2005
Location: salem county , New Jersey
Distribution: PCLinuxOS .92
Posts: 59

Rep: Reputation: 15
don't need grub.conf

/boot/grub/menu.lst
 
Old 11-18-2005, 10:17 PM   #8
tinybit
Member
 
Registered: Jul 2005
Location: China
Distribution: Mandriva
Posts: 84

Rep: Reputation: 15
GRUB and LILO always conflict with Windows.

So try GRUB for DOS please. It is a cross-platform boot loader based on GNU GRUB. The GRUB.EXE can be started from DOS/Win9x; and GRLDR can be started from BOOT.INI of Windows NT/2K/XP/2003; and even more, the GRUB.EXE can be started from LINUX via the KEXEC tool.

By using GRUB.EXE or GRLDR, you don't have to touch your MBR. It is the safest way coexisting with DOS/Windows.

You needn't install GRUB for DOS. Just run GRUB.EXE from DOS, or append a line of "C:\GRLDR=START GRUB" into your BOOT.INI(restart and select the "START GRUB" menu item), that will do.

Download GRUB for DOS here: http://freshmeat.net/projects/grub4dos/

There is a fat12grldr.img file with the GRUB for DOS release. You can create a GRUB bootable floppy with this fat12grldr.img file.

Or, you can just copy GRUB.EXE to your DOS floppy and run GRUB.EXE to enter the GRUB environment.
 
Old 11-20-2005, 10:25 AM   #9
dhlw
LQ Newbie
 
Registered: May 2005
Location: Brazil
Posts: 23

Rep: Reputation: 15
Hey, this sounds like a great solution if it works.

Quote:
Originally posted by tinybit
GRUB and LILO always conflict with Windows.

So try GRUB for DOS please. It is a cross-platform boot loader based on GNU GRUB. The GRUB.EXE can be started from DOS/Win9x; and GRLDR can be started from BOOT.INI of Windows NT/2K/XP/2003; and even more, the GRUB.EXE can be started from LINUX via the KEXEC tool.

...

You needn't install GRUB for DOS. Just run GRUB.EXE from DOS, or append a line of "C:\GRLDR=START GRUB" into your BOOT.INI(restart and select the "START GRUB" menu item), that will do...
So please detail for this newbie exactly where I should append that C:\GRLDR=START GRUB line in Windows XP Home Edition SP2 file boot.ini
To make replying easiest I'm posting exactly what my present boot.ini looks like right now:

<quote>

[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Microsoft Windows XP Home Edition" /fastdetect /NoExecute=OptIn

<unquote>

Thanks, Tinybit.
 
Old 11-20-2005, 07:01 PM   #10
tinybit
Member
 
Registered: Jul 2005
Location: China
Distribution: Mandriva
Posts: 84

Rep: Reputation: 15
Just this way please:

[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Microsoft Windows XP Home Edition" /fastdetect /NoExecute=OptIn
C:\GRLDR="START GRUB"
 
Old 11-21-2005, 08:51 AM   #11
dhlw
LQ Newbie
 
Registered: May 2005
Location: Brazil
Posts: 23

Rep: Reputation: 15
Appreciate your prompt response, Tinybit, but have been over at Sarovar and note some folks ran into problems with GRUB for DOS I want to avoid if poss before setting up this HP Pavilion notebook to dual-boot WinXP HE SP2 with Ubuntu 5.10. Grateful if you can clarify further two questions below the quote before I proceed.

Quote:
Originally posted by tinybit
Just this way please:

[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Microsoft Windows XP Home Edition" /fastdetect /NoExecute=OptIn
C:\GRLDR="START GRUB"
Question 1. So, after adding this line to C:\boot.ini, I still need to copy grldr from grub_for_dos-0.4.1pre32.tar.gz to same WinXP root C:\ partition? Note Linux fdisk -l lists WindowsXP-only 30.0GB internal drive C: as second disk below the external FireWire Seagate /dev/sda (believe GRUB calls Linux boot partition (hd0,0) on the Seagate as it's in /sda1):

[list=a]
/dev/hda1 Start 2 End 9 Blocks 64260 ID 84 System OS/2 hidden C: drive (HP Factory install FAT16)
/dev/hda2 Boot * Start 10 End 3648 Blocks 29230267 Id 7 System HPFS/NTFS (only WinXP NTFS partition)[/list=a]

Question 2. Will GRUB then automatically find the WinXP boot option (hd1,1), a NTFS partition, or throw a error as it only looks in (hd1,0) first FAT 16 partition on C: to boot WindowsXP if I don't do anything else to what's stated in question 1?

Thanks for your patience but I don't want to mess up the WinXP MBR a second time!
 
Old 11-21-2005, 09:52 AM   #12
tinybit
Member
 
Registered: Jul 2005
Location: China
Distribution: Mandriva
Posts: 84

Rep: Reputation: 15
No one actually run into problems with GRUB4DOS. The worst thing is that they might fail in starting GRUB4DOS. If you failed, nothing would happen. Invoke GRLDR this way won't touch your MBR, and won't touch anything inside your disks. It is a read-only operation.

1. You may copy grldr to ALL of your partitions, even the ext2/ext3 partitions(Of course, copy to their root dir). Thus, if GRLDR in NTFS failed, other GRLDRs will be used instead.

You may copy grldr to all partitions in /dev/hda1 AND all partitions in /dev/hda2, if you'd like.

2. When GRLDR starts, it will try to locate the menu.lst file. The menu.lst in the same root dir as the running GRLDR takes precedence. If there isn't, then it will search for GRLDR in ALL partitions in ALL drives in / (the root dirs) and then in dirs of this form: /boot/grub and then in dirs of this form: /grub

The menu.lst file controls how to boot your operating systems automatically.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
FC4 - Grub Can't Find Hard Drive bomdemais Fedora - Installation 3 07-01-2005 01:52 AM
Can't find edit grub.conf when im in command line. izac5 Linux - Newbie 7 11-16-2004 05:24 PM
create lilo.conf or grub.conf through commands newpenguin Linux - Software 1 11-28-2003 09:22 PM
commands work with interactive grub, but not in grub.conf richardg Linux - Newbie 2 11-23-2003 05:36 AM
lilo.conf and grub.conf no read access shanenin Linux - Software 1 10-02-2003 04:53 PM


All times are GMT -5. The time now is 05:46 PM.

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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration