Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 03-08-2005, 03:13 PM   #1
LQ Newbie
Registered: Dec 2004
Posts: 3

Rep: Reputation: 0
grub & ntldr

I recently re-installed XP on my dual boot box (Fedora Core 2 &XP). However i forgot that ntldr would over write grub. My question is how do i get ntldr to recognize my linux partition, or how do i re-install grub to MBR... if i can't boot FC2 but i can access all the files w/ Mount Everything. I've tried pointing ntldr to my boot sector, but nothing works. I appreciate any input on my situation.
Old 03-08-2005, 04:40 PM   #2
Senior Member
Registered: Oct 2003
Posts: 3,057

Rep: Reputation: 60
Here are my notes on repairing the grub....

1. Boot your machine from your boot media (cdrom1) and select linux rescue to install to the command prompt.

2. Redhat displays a message “If you would like to make your system the root environment, run the command: chroot /mnt/sysimage”. Go ahead and do that.

3. At the prompt, type rdev and make a note of the output. For example, if it looks like this... " /dev/hda2 / " . This indicates that the Redhat root partition is on the first drive and second partition. You need that info for the next step.

4. Get into the grub configuration utility with the command: grub.
At the prompt grub> type the command: root (hd0,1) ; this will tell grub that the linux files it needs are on the first hard disk (hd0) and the second partition (1) of that drive. Change this to meet your configuration needs. For instance, if the linux files are on the second hard disk (hd1), first partition (0) of that drive then type root (hd1,0).
If you selected the correct location (where linux is installed), you should see a message as follows.... Filesystem type is Ext2fs, partition type is 0x83.
Then issue the following command: setup (hd0) ; this will install grub in the MBR of your first hard disk. You could change that to use the /boot partition if desired.
Exit the grub utility with the command: quit

You can also try to use grub-install /dev/hda to install grub on your first hard drive's MBR. Sometimes the first method works better.


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
GRUB: NTLDR not found. Or is it? JZL240I-U Linux - Software 2 03-07-2005 04:33 AM
re-installed GRUB now NTLDR is missing Sygnus X1 Linux - Newbie 8 01-15-2005 02:07 PM
Debian/Windows lost grub to ntldr DigitalSmash Debian 1 01-12-2005 11:04 AM
GRUB / NTLDR problem dual booting lnxusr01 Linux - Newbie 1 07-14-2003 01:12 PM
dual booting Win2k & RH Linux using ntldr->GRUB has problems whitepine Linux - General 3 01-28-2003 06:39 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:55 PM.

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