LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 05-20-2009, 12:47 AM   #1
lgp171188
LQ Newbie
 
Registered: Apr 2009
Posts: 16

Rep: Reputation: 0
Question Need help reinstalling GRUB after installing Windows OS


Hi all,
I have a multiboot machine which used to run Debian Etch and Windows XP, and without saying, I often had to reinstall Windows XP after which I will have to reinstall GRUB again. I often used OpenSolaris LiveCD which has a GRUB prompt when booted. I pressed 'c' to go into the command prompt of GRUB and did a 'find /boot/grub/stage1' for which I got a partition like (hdX,Y). Then I did a 'root (hdX,Y)' and 'setup (hd0)' and GRUB would get installed.

Sometimes, I used to boot into Ubuntu live and do a 'grub-install /dev/sda' to fix it. But now with recent versions of Ubuntu and Debian Lenny these well-documented procedures do not seem to work.

When I do a 'find /boot/grub/stage1' in the grub prompt, it gives a 'file not found error' and when i do a 'grub-install' command it says it can't find the '/boot/grub/stage1 and etc. etc.'. But the files are there safe in the linux partition, which I confirmed by booting into the LiveCD and mounting the partition.

How to install GRUB now? I noticed that these problems weren't there with older versions of distros. Has something changed in newer distros that I am unaware of?

Thanks in advance.
 
Old 05-20-2009, 07:32 AM   #2
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian sid + kde 3.5 & 4.4
Posts: 6,823

Rep: Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947Reputation: 1947
I had similar troubles with trying to use a Knoppix CD to repair my MBR. I think something about its security settings may have been keeping it from working or something. Then I tried the SystemRescueCd, and it works great for this kind of thing. One thing you can do with it is boot your Linux partition directly using its own included kernel. Then you can use grub to reset your MBR straight from your regular installation.

It has other repair options too. Check it out.
 
Old 05-24-2009, 06:21 AM   #3
contusion
Member
 
Registered: Mar 2005
Posts: 310

Rep: Reputation: 34
Alternatively you can use a brub iso image. Write it to a CD and use the CD to boot your installation.
 
  


Reply

Tags
dual boot, grub, install


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 On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Reinstalling Windows - Screwing up GRUB hopesfall Linux - General 4 01-29-2006 06:52 PM
getting grub to work after reinstalling windows aenimax Linux - Software 12 07-06-2005 04:31 AM
reinstalling windows deleted my grub master boot file; how do I restore it? sohmc Linux - General 3 01-12-2005 01:27 PM
Reinstalling Grub after Installing XP niteshadw Fedora 3 07-31-2004 07:20 AM
Reinstalling Windows, will Grub go away then? jlj Linux - Newbie 4 10-03-2003 08:57 PM


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

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