LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Linux Recovery after installation of Windos XP (https://www.linuxquestions.org/questions/linux-newbie-8/linux-recovery-after-installation-of-windos-xp-736320/)

GirishSharma 06-29-2009 01:52 AM

Linux Recovery after installation of Windos XP
 
Hello,

I had dual boot at my home PC i.e. Linux and Win XP.

Due to some problem, i format my C: (i.e. windows) and re-installed Windows XP; but now i am not getting the option for boot with linux...

Where is my earlier RHEL - 4 linux?

How do i get dual boot option and is there any problem with earlier installed linux?

Please guide me.

Thanks and Regards
Girish Sharma

austinium 06-29-2009 01:56 AM

you need to restore GRUB as the primary boot loader, windows installs its bootloader (NTLDR for XP) during installation,

have a look at the following link
http://mybosslinuxblog.wordpress.com...lling-windows/

good luck

jdkaye 06-29-2009 01:58 AM

There is a thread on this topic here:
http://www.linuxquestions.org/questi...-linux-735733/
In general it's a good idea to search this site for similar problems and if that doesn't help doing a google before starting a thread. This saves you a lot of time and trouble.
As you will see, installing windows on top of a linux installation is often a cause of trouble. Doing the reverse, installing linux on top of a windows installation is not. You can read all about it in the thread mentioned above.
cheers,
jdk

linuxlover.chaitanya 06-29-2009 01:59 AM

If you had searched LQ you could have easily got through some similar threads. Your grub has been wiped out and windows has written its own loader.
Boot using RHEL cd to boot to rescue mode.
Once you have a shell type the command

grub-install /dev/sda

PS: Assuming that your drive is recognized as sda. You should first check it with fdisk -l

GirishSharma 06-29-2009 04:32 AM

Thanks chaitanya.
As i came to know for recovery the linux i should follow:

1.insert RHEL first cd and press any key to boot from CD
2.at the prompt i should type "linux rescue" and press enter
3.after few seconds and reply no to start network settings
4.at the # prompt i should type chroot /mnt/sysimage
5.grub -install /dev/hda

here i am confusing; what should i type i.e. hda or sda. How do i know that it should be <n>da; i.e. result of fdisk -l

Regards
Girish Sharma

lemon09 06-29-2009 05:14 AM

first insert the RHEL CD or DVD in the drive.
choose install and then select the option upgrade.
this will upgrade ur system and install the GRUB.

linuxlover.chaitanya 06-29-2009 05:57 AM

Post the output of fdisk -l.

GirishSharma 06-30-2009 01:22 AM

Hello chaitanya,

1.inserted RHEL cd 1 in cdrom.
2.boot from CD
3.linux rescue at the command prompt
4.after few seconds; selecting US keyboard and No to network settings i got the prompt.
5.chroot /mnt/sysimage
6.grub -install /dev/hda

When i see fdisk -l there was no entry of sda in the output; so i just hit hda. After 4-5 seconds, i got my prompt again without any error.
7.removed the cd from cdrom
8.reboot

Bingo...!!!

I got the two options as earlier and now both OS are working fine.

I wish to thank you and all of them who replied to my question.

Best Regards
Girish Sharma

linuxlover.chaitanya 06-30-2009 02:19 AM

Well done. Happy to know you got it working and found help here. If you think you got help from here, then click the Thumps up icon for all those who helped you.


All times are GMT -5. The time now is 06:21 AM.