how to recover grub loader after reinstall windows xp

Posted on 2003-02-21
Medium Priority
Last Modified: 2013-12-06
I had a dual system (RedHat and win xp in two hard drives). After winxp crashed down, I reformated the windows partition and reinstalled xp. But I lost the grub boot loader and can't boot the linux. Can any body tell me how to get my linux back  instead of installing a new one?
Question by:delphet
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Expert Comment

ID: 7998235

You do not have a floppy to boot into Linux with ? If not I think you can boot from the red hat cd to get into linux (have not tried this with red hat though, it works on suse linux)

If you somehow manage to get into red hat again you maybe want to create a boot floppy with grub, then you wont risk to do the opposite of what you just did (not getting into windows after reinstalling grub).

You can do this with the following commands:

# cd /usr/share/grub/i386-pc
# dd if=stage1 of=/dev/fd0 bs=512 count=1
1+0 records in
1+0 records out
# dd if=stage2 of=/dev/fd0 bs=512 seek=1
153+1 records in
153+1 records out

By the way you can read about dual boot on red hat systems here:



Expert Comment

ID: 7998323
You can also, booting with your Linux instalation CD or with a Rescue Disk, configure the Windows XP boot loader to start linux...

1. When logged into linux, use the following command.

If your linux boot partition is /dev/hda1 and your WinXP partition is mounted on /winxp/

# dd if=/dev/hda1 of=/winxp/bootsect.lnx bs=512 count=1

2. Then, edit /winxp/boot.ini and add this line:


3. Reboot, you should be able to select and start linux from your Windows boot menu.

For Rescue Disks, check this page:

Hope this helps you, good luck !

Expert Comment

ID: 8008257
You can just download a mini-distro to get into linux. Then edit your lilo.conf file so that you can boot with lilo.
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.


Author Comment

ID: 8027173

Thanks for all the messages from you. I tried them but they don't work. There is no /winxp directory in my machine so garisoain's suggestion can't work. According to Cygnus78's message, I should write someting to the floppy (/dev/fd0 is the floppy drive). I don't think that can help and it really didn't. I guess I may not describe my problem clearly. I had a dual boot system (RedHat and Winxp) before. When I reinstalled XP, I can't get GRUB boot loader run when booting the machine. It goes directly to XP. I don't want to reinstall RedHat. So my question is how I can recover the existing GRUB and make it work again. Hope that makes my situation clear.

Thanks again.


Expert Comment

ID: 9087911
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
Post your closing recommendations!  No comment means you don't care.
LVL 12

Expert Comment

ID: 9259402
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is to:

Be PAQ'd/Points No Refunded

Please leave any comments here within the next seven days.


EE Cleanup Volunteer

Accepted Solution

YensidMod earned 0 total points
ID: 9325519
PAQed per request/recommendation - No Refund

Community Support Moderator

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to demonstrate how we can use conditional statements using Python.
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Suggested Courses
Course of the Month11 days, 11 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question