LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-06-2004, 06:10 AM   #1
Jingle
Member
 
Registered: May 2003
Location: Netherlands
Distribution: Fedora Core 2
Posts: 41

Rep: Reputation: 15
Fix corrupted MBR on dualboot Machine


I need a little help ,
I currently have a dual boot WinXP (for the wife .. can't convince her to use Linux) and a fully configurated perfectly running Fedora Core 1 ( took a long time to have it all my way , so I really don't wanna start over again )

Here's the problem

I first installed Win XP and then Fedora , with grub on the MBR (cause grub can boot winXP ) so I have a dual boot choice from grub from the MBR . Now I recently tried to install windows XP service Pack 1 and told it to backup old files ,, and then Install the sevrice pack .. and than it happened .. during the install of the newer files of the service pack , winXP frooze , and the only thing left was to reset .. and you can guesss it .. windows won't boot .. (Linux does , otherwise I wouldn't be typing this) .
Now for me its no problem to reinstall windows , but it automatically will overwrite my MBR and therefore also my capability of starting grub and Linux ..

How am I to go about this (besides telling the wife Windows doesnt exist anymore and Tux took over , deal with it :-) ) ?

Is it possible to either change the location of grub and make a bootfloppy so I can stil boot into linux after an MBR overwrite ? , or make an exact cpoy of the MBR (is this possible!!) so after a reinstall of winXP I can put the old MBR back ?

Or any other Idea ??
 
Old 06-06-2004, 06:45 AM   #2
drigz
Member
 
Registered: Apr 2004
Distribution: Gentoo ~x86
Posts: 407

Rep: Reputation: 30
well, you can make a boot floppy so you can boot into linux when the mbr is set to windows. then you could reinstall windows, then use the boot floppy to get into linux and reinstall grub onto the mbr, which should work. not sure how to make a boot floppy, shouldnt be hard to find out with google (too tired now).

alternatively you could do what i did (my family relies on me for computer help) tell them if they wanna use windows they do it themselves, but if they use linux, youll go out of your way to fix every problem and make it work as well as possible. i now have every desktop in my house on linux
 
Old 06-06-2004, 07:22 AM   #3
Covel
Member
 
Registered: Oct 2003
Location: Portugal
Distribution: Gentoo
Posts: 116

Rep: Reputation: 16
I recently add reinstall WinXP. I wasn't using it for weeks and when I really needed it (Microsoft Visio) it would boot. I was also afreid to lose grub so I checked that I had a bootable disk. With it I could boot into linux and reinstall grub. So I reinstalled winxp (repair resintall not full) and my grub is still there!! Maybe you'll be that lucky too

But as drigz said, the solution is to have bootable disk.
 
Old 06-06-2004, 07:23 AM   #4
drigz
Member
 
Registered: Apr 2004
Distribution: Gentoo ~x86
Posts: 407

Rep: Reputation: 30
couldnt you use visio with wine or crossover?
 
Old 06-06-2004, 09:03 AM   #5
Covel
Member
 
Registered: Oct 2003
Location: Portugal
Distribution: Gentoo
Posts: 116

Rep: Reputation: 16
Quote:
Originally posted by drigz
couldnt you use visio with wine or crossover?
I don't have wine working yet. Last time I tried it I lost my displayed. Haven't had the time to try it again.
 
Old 06-06-2004, 09:19 AM   #6
doralsoral
Member
 
Registered: Aug 2003
Location: raleigh
Distribution: Gentoo 2005.1 x86_64
Posts: 931

Rep: Reputation: 31
you dont have to reinstall windows just boot up with the windows cd go tot he recorvery console and type fixmbr and yes this will rewrite your MBR so you will have to make that linux boot floppy and reinstall grub.
 
Old 06-06-2004, 09:23 AM   #7
-X-
Member
 
Registered: Oct 2003
Location: Tx,USA
Distribution: Slackware, Red Hat, CentOS
Posts: 495

Rep: Reputation: 30
What I do...
Find where what the /boot partition is on.
# /sbin/fdisk -l
Do a grub-install /dev/hda? (probably hda2)
Then peel off the first 512 bytes from it.
# cd /
# dd if=/dev/hda2 of=bootsect.lnx bs=512 count=1

Put the bootsect.lnx on C:\
Edit boot.ini

multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional" /fastdetect
C:\bootsect.lnx="Slackware 9.1"
 
Old 06-06-2004, 10:28 AM   #8
curmudgeon42
Member
 
Registered: May 2004
Posts: 86

Rep: Reputation: 15
i have found that if you run the "Repair Installation" from the WinXP Install CD instead of a brand new install, it won't touch the MBR. can't guarantee that is always true, as i've only used the repair install option once. but when I did, the mbr was still the way i had left it, with GRUB running the show.

also, when i did the repair, it got rid of all the of the service packs, hotfixes, and other Windows Update downloads i had done, so it should restore you from your bad Service Pack upgrade.

~ Justin
 
Old 06-06-2004, 11:33 AM   #9
Covel
Member
 
Registered: Oct 2003
Location: Portugal
Distribution: Gentoo
Posts: 116

Rep: Reputation: 16
Quote:
Originally posted by doralsoral
you dont have to reinstall windows just boot up with the windows cd go tot he recorvery console and type fixmbr and yes this will rewrite your MBR so you will have to make that linux boot floppy and reinstall grub.

That depends. If WinXP is screwd up, it wont boot. No matter what you do with the mbr :P
 
Old 06-06-2004, 12:59 PM   #10
drigz
Member
 
Registered: Apr 2004
Distribution: Gentoo ~x86
Posts: 407

Rep: Reputation: 30
if it was the mbr that was the problem, reinstalling grub should have fixed it. this would mean that your title is a bit misleading. i reckon doing a windows repair should fix it as it seems to be a problem with hte windows install. this is very easy - just boot up from the winxp cd and follow instructions to repair. it will be apparent.

this wont lose your data etc. just will replace windows system files.
 
Old 06-07-2004, 10:11 AM   #11
Jingle
Member
 
Registered: May 2003
Location: Netherlands
Distribution: Fedora Core 2
Posts: 41

Original Poster
Rep: Reputation: 15
I think I will do a clean install xp (more problems lately and i thougt a service pack and updates could help) after making a linux bootdisk ,
thanx for your tips and i'll let you know if I succeed ..
 
Old 07-10-2004, 02:02 PM   #12
Jingle
Member
 
Registered: May 2003
Location: Netherlands
Distribution: Fedora Core 2
Posts: 41

Original Poster
Rep: Reputation: 15
Well it didn't go that well after all , after making a linux boot flop and testing it after a FIXMBR in windows xp recovery console (i.o.w mbr is clean and without grub) , I was still able to boot linux from the flop , so I thought lets go and install XP (and later on overwrtite the mbr with grub which can start XP )

The XP install went allright but no internet .... but worse was ........
when trying to boot linux from flop ... nothing happend and grub wasn't able to find linux partitions at all .... whhhhhaaaa!!!! so Linux gone , XP not being able to acces the internet ..... well everybody knows the frustration if you experiment with your pc
Result .::::::
I cleaned out my disk completely and told my girlfriend to get used to Linux , and installed Fedora, on the entire disk and that is my distro now , works great ... and no more windows !!!!
 
Old 07-10-2004, 03:13 PM   #13
movitto
Member
 
Registered: May 2004
Distribution: Fedora 4 and Slackware
Posts: 179

Rep: Reputation: 30
Talking Im a bit confused

Jingle;
In your first post you said:

Quote:
...besides telling my wife Windows doesnt exist anymore and Tux took over
and your last post:

Quote:
I cleaned out my disk completely and told my girlfriend to get used to Linux
I dont mean to pry into your personel life (wife && girlfriend).... (j/k)

But onto the subject, here is a link that shows how to boot linux from the windows bootloader. I know its too later that you got rid of windows but maybe in the future.

http://www.linuxsolved.com/forums/ftopic125.html

Good luck with linux (as well as the wife and girlfriend )
 
  


Reply


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
by tring to fix the MBR i damage the MBR that was help... AKAKAK Fedora 4 03-21-2005 08:18 AM
dualboot fix challenge Peterius Linux - Software 2 06-01-2004 03:13 PM
Corrupted MBR HGeneAnthony Linux - Newbie 1 03-13-2004 10:07 PM
dualboot - lost win MBR clokwurk Linux - Newbie 4 09-14-2003 03:58 PM
new, need help mounting ntfs to fix dualboot oPRAH Linux - Newbie 5 07-29-2002 04:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:03 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration