Welcome Guest ( Log In | Register )



 
Reply to this topicStart new topic
> Ubuntu 7.10 + Windows Xp Dual Boot, how to reinstall GRUB after windows reinstall
mikesoft
post Mar 28 2008, 03:06 AM
Post #1


Member - Active Contributor
Group Icon

Group: [HOSTED]
Posts: 91
Joined: 26-December 07
From: Venezuela
Member No.: 27,134



Ok so for a long time I had my dual boot working great, windows and ubuntu. But 2 days ago my windows required a wipe and clean install because of some issues, like it usually happens after 8 months.

So I reinstalled windows, well, first deleted the windows partition using the windows XP install CD. Then assigned a partition for windows (same size) and left the ubuntu and swap partition intact. But of course, windows deletes GRUB and replace it with their boot info, so now I can't boot ubuntu (I can't choose).

How can I reinstall GRUB without having to reinstall ubuntu, so I don't lose all my files and settings?
Go to the top of the page
 
+Quote Post
pyost
post Mar 28 2008, 10:59 AM
Post #2


Nenad Bozidarevic
Group Icon

Group: [MODERATOR]
Posts: 993
Joined: 7-November 05
From: Belgrade, Serbia
Member No.: 9,500



I had to deal with similar issue (reinstalling Windows XP with Ubuntu 7.10 already installed), except I didn't delete the Windows partition, just formated. The thing is, at least according to my limited "boot" knowledge, that you have probably made the old GRUB unusable, since the Windows practically isn't on the same partition any more. This, however, shouldn't prevent you from trying the method I used. Be aware that I have done this only once, so there is a slight risk when following my instructions.

First of all, insert the Ubuntu Live CD and boot the computer from it. After doing so, and starting Ubuntu, run the Terminal (Applications -> Accessories -> Terminal) and run the following commands.

CONSOLE
$ sudo grub


After doing so, you will start the GRUB configuration utility which will allow you to setup GRUB on a desired partition.

CONSOLE
grub> find /boot/grub/stage1


This command will output (hd*,*), the asterisks being some numbers. Now you need to run these commands (replacing the asterisks with the numbers you got):

CONSOLE
grub> root (hd*,*)
grub> setup (hd0)
grub> quit


Exit Ubuntu, remove the disk and reboot your computer. You should now get the GRUB bootloader.

The chances are Ubuntu will run properly, but due to the deletion of a partition, Windows might not. If that is the case, start Ubuntu and run this command in the terminal:

CONSOLE
$ gksu gedit /boot/grub/menu.lst


The file menu.lst should contain something like this:

CODE
# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title        Microsoft Windows XP Home Edition
root        (hd0,0)
savedefault
makeactive
chainloader    +1


If Windows doesn't boot, the root line is wrong, and you need to replace (hd0,0) with the proper partition. Which one and how to do so? That I don't know...
Go to the top of the page
 
+Quote Post
rockershive
post Apr 1 2008, 02:02 AM
Post #3


Member [ Level 2 ]
Group Icon

Group: Members
Posts: 66
Joined: 21-September 07
Member No.: 24,999



Pyost's instructions are correct. That's in the case where you lost your GRUB menu during startup.

I am Quin-Booting or should we call it Penta-Booting (5) different Operating Systems in my AMD Machine, I experience a lot of times 'losing' my OSes when scrumbling more OS in a single PC, single hard drive.

This post has been edited by rockershive: Apr 1 2008, 02:04 AM
Go to the top of the page
 
+Quote Post
Miles
post Apr 1 2008, 11:20 AM
Post #4


Advanced Member
Group Icon

Group: [HOSTED]
Posts: 177
Joined: 25-December 07
Member No.: 27,129



Instead of the common grub-based dualboot setup, you could use a program called HyperOS. It has had support for linux since version 2004 I believe, however I think it costs money.
Go to the top of the page
 
+Quote Post
mikesoft
post Apr 18 2008, 12:23 AM
Post #5


Member - Active Contributor
Group Icon

Group: [HOSTED]
Posts: 91
Joined: 26-December 07
From: Venezuela
Member No.: 27,134



thank you pyost, it worked like a charm! sorry for taking too long to respond, but I didn't have time to try it. I did it and it works!

woot =D
Go to the top of the page
 
+Quote Post
Feedbacker
post Apr 21 2008, 03:34 AM
Post #6


Newbie [ Level 1 ]
Group Icon

Group: Members
Posts: 0
Joined: 1-November 07
Member No.: 25,869



error in finding grub
Ubuntu 7.10 + Windows Xp Dual Boot

I ran the sudo grub command. Ok
Grub> find /boot/grub/stage1 says file not found.
Pl. Advice

-question by syed
Go to the top of the page
 
+Quote Post
jbpostal
post May 7 2008, 05:34 PM
Post #7


Newbie [ Level 1 ]
Group Icon

Group: Members
Posts: 1
Joined: 6-May 08
Member No.: 30,179



We have already installed UBUNTU but when I am trying to get in it's showing Disc Error. What should I do?
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Which Distro Of Linux Is Best For A Windows User ?(42)
  2. Grub Error After Reinstalled Winxp(11)
  3. Knoppix!(3)
  4. Restoring Grub Boot Loader(9)
  5. Linux "hangs" On Boot(9)
  6. Linux Distro Most Like Windows?(13)
  7. Ubuntu Installation Help !(11)
  8. Ubuntu Livecd(7)
  9. Ubuntu Won't Log On(12)
  10. Ubuntu 7.04 - Test Drive(0)
  11. Get Wireless Working In Ubuntu 7.04(0)
  12. Automate The Advanced Setup Of Graphics Cards In Ubuntu And Debian(1)
  13. With Wubi The Hard Drive Does Not Have To Be Repartitioned Before The Ubuntu Installation(2)
  14. Do These Things Immediately After Installing Ubuntu(0)
  15. Do You Want To Find A Linux Equivalent To A Windows Application?(9)
  1. It Just Isn't Fair That Windows Users Get All The Viruses(3)
  2. Beginner's Guide To Installing Software In Ubuntu(2)
  3. Ubuntu 7.10(8)
  4. Review About Ubuntu 7.10(15)
  5. Three Ways To Access Linux Partitions From Windows On Dual-boot Systems(5)
  6. Simple Ubuntu Based Home File Server | For Newbies(1)
  7. Linux And Windows Partitions(2)
  8. Making Xubuntu Look Like Windows Vista(6)
  9. Need Help Downloading With Ubuntu(2)
  10. Is There A Php Editor That Runs On Pclinuxos Or Ubuntu?(7)
  11. How To Copy File & Folders From Linux To Windows?.(6)
  12. Access Linux Box From Windows Machine- Putty Tool(2)
  13. Ubuntu- How To Install C/ C++ Compilers.(2)


 



- Lo-Fi Version Time is now: 7th July 2008 - 12:32 AM