Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I need to reinstall windows xp , i have ubuntu too , i had installed windows first then ubuntu , forgot which is in MBR , i dont knw either it is GRUB or windows boot loader
When i reinstall windows xp , will it make any problem to my ubuntu, i'm supposed to install in earlier windows location itself
Please help ..
XP will replace the loader in the MBR. No big deal - you can re-install grub easily enough after the event. Your Ubuntu system will still be there, but you won't be able to access it directly after the XP re-install.
XP will replace the loader in the MBR. No big deal - you can re-install grub easily enough after the event. Your Ubuntu system will still be there, but you won't be able to access it directly after the XP re-install.
How can i access my ubuntu then .. ? Shud anything done in MBR , please help me to perform , i dont knw much about MBR , or grub reinstall , that kind of words
Distribution: slackware 12.0, Vector Linux STD 6.0 and 5.8, ZenWalk 4.6.1, OpenBSD 3.9
Posts: 389
Rep:
Quote:
Originally Posted by vibinlakshman
I was supposed to reinstall ..Still having ubutntu in another partition
if you reinstall windows with ubuntu still existing, xp will over write your MBR so your boot loader (whether grub or lilo) will be gone. BUT your ubuntu is still available. you have just to reinstall your boot loader via using the ubuntu install cd.. (if i am saying it right) i have done this before. . .
Hi vibi,
Not sure why you feel you need to re-install windows (care to explain?). If not, here is the definitive & easiest way to restore your Grub. I think I got it from Ubuntu Forums...You might want to try this before re-installing anything!!!
How to restore Grub from a live Ubuntu cd.
This will restore grub if you already had grub installed but lost it to a windows install or some other occurence that erased/changed your MBR so that grub no longer appears at start up or it returns an error.
(This how to is written for Ubuntu but should work on other systems. The only thing to take note of, when you see "sudo" that will mean to you that the following command should be entered at a root terminal.)
Boot into the live Ubuntu cd. This can be the live installer cd or the older live session Ubuntu cds.
When you get to the desktop open a terminal and enter. (I am going to give you the commands and then I will explain them later)
Code:
sudo grub
This will get you a "grub>" prompt (i.e. the grub shell). At grub>. enter these commands
Code:
find /boot/grub/stage1
This will return a location. If you have more than one, select the installation that you want to provide the grub files.
Next, THIS IS IMPORTANT, whatever was returned for the find command use it in the next line (you are still at grub>. when you enter the next 3 commands)
Code:
root (hd?,?)
Again use the value from the find command i.e. if find returned (hd0,1) then you would enter root (hd0,1)
Next enter the command to install grub to the mbr
Code:
setup (hd0)
Finally exit the grub shell
Code:
quit
That is it. Grub will be installed to the mbr.
When you reboot, you will have the grub menu at startup.
Good Luck
Last edited by jonny5tails; 02-19-2009 at 11:28 PM.
Hi vibi,
Not sure why you feel you need to re-install windows (care to explain?). If not, here is the definitive & easiest way to restore your Grub. I think I got it from Ubuntu Forums...You might want to try this before re-installing anything!!!
How to restore Grub from a live Ubuntu cd.
This will restore grub if you already had grub installed but lost it to a windows install or some other occurence that erased/changed your MBR so that grub no longer appears at start up or it returns an error.
(This how to is written for Ubuntu but should work on other systems. The only thing to take note of, when you see "sudo" that will mean to you that the following command should be entered at a root terminal.)
Boot into the live Ubuntu cd. This can be the live installer cd or the older live session Ubuntu cds.
When you get to the desktop open a terminal and enter. (I am going to give you the commands and then I will explain them later)
Code:
sudo grub
This will get you a "grub>" prompt (i.e. the grub shell). At grub>. enter these commands
Code:
find /boot/grub/stage1
This will return a location. If you have more than one, select the installation that you want to provide the grub files.
Next, THIS IS IMPORTANT, whatever was returned for the find command use it in the next line (you are still at grub>. when you enter the next 3 commands)
Code:
root (hd?,?)
Again use the value from the find command i.e. if find returned (hd0,1) then you would enter root (hd0,1)
Next enter the command to install grub to the mbr
Code:
setup (hd0)
Finally exit the grub shell
Code:
quit
That is it. Grub will be installed to the mbr.
When you reboot, you will have the grub menu at startup.
Good Luck
Oh man u were so good , I got it .. Will perform it
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.