LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > General
User Name
Password
General This forum is for non-technical general discussion which can include both Linux and non-Linux topics. Have fun!

Notices


Reply
  Search this Thread
Old 09-11-2007, 01:31 PM   #1
amrapali_bs
LQ Newbie
 
Registered: Sep 2007
Posts: 0

Rep: Reputation: 0
Unhappy Need Help to install WindowsXP without removing Fedora


Hi All,

Here is my problem.
I have Windows XP and Fedora Core6 on my desktop.

Windows has got some virus, bcoz of which it keeps on restarting infinitely.
So want to format Windows and install it again.
When I try to boot WindowsXP bootable cd. It goes to the screen "Setup checking Hardware config"...and thats it...a black screen...it doesn't move forward.

From the other threads, I got to know abt formatting the complte harddisk with

dd if=/dev/zero of=/dev/hda bs=512 count=16

And then installing Windows followed by FC6

However, I dont wish to lose data on other Windows prtitions ( D & E) also dont wish to remove FC6 for the same.

Can someone please help, How I can format C drive and reinstall Windows.
 
Old 09-11-2007, 07:20 PM   #2
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
One option would be to use a program like partimage to save images of the other partitions, do the dirty work you need to do to reinstall XP, recreate the other partitions and restore them from their images. If you do this, you do need to make sure that the partitions you are restoring to are at least as large as the original partitions.

You will need to find someplace to store the images. You can save them across a network if you have another computer that has room.
 
Old 09-11-2007, 07:22 PM   #3
Jorophose
Member
 
Registered: Oct 2006
Location: Ontario, Canada
Distribution: Xubuntu 6.06!! =D
Posts: 137

Rep: Reputation: 15
You're probably going to have to resort to backing everything up, wiping the hard drive, and then reinstalling XP and then Fedora.

That's what you get for XP's lammo habbits. =/
 
Old 09-11-2007, 11:30 PM   #4
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Ubuntu 12.04, Antix19.3
Posts: 3,794

Rep: Reputation: 282Reputation: 282Reputation: 282
I think your problem lays somewhere else. Booting from the XP CD should work.

Formatting the whole HD sounds like overkill to me, but I might be wrong. You can try to remove the C-partition from within Linux and next try to install XP in the free space. Afterwards you can re-install Grub in the MBR (no experience with that).

PS Make backups if the data is important. A power failure or one little mistake by you or XP and it might all be gone.

Last edited by Wim Sturkenboom; 09-11-2007 at 11:41 PM. Reason: Added PS
 
Old 09-12-2007, 01:35 AM   #5
amrapali_bs
LQ Newbie
 
Registered: Sep 2007
Posts: 0

Original Poster
Rep: Reputation: 0
Guys, thanks a lot for the replies..

The XP cd doesn't boot at all while Fedora is there...

So, even if I format C partition, keeping the Fedora, XP cd still might not boot...
On the other hand...if I cud have got the XP cd booted...i cud have formatted the C partition from there also...no need to format it from Linux.

So to get the XP cd working I guess I will have to format the linux partitions atleast...

Last edited by amrapali_bs; 09-12-2007 at 01:36 AM.
 
Old 09-12-2007, 06:16 AM   #6
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
Quote:
Originally Posted by amrapali_bs View Post
So to get the XP cd working I guess I will have to format the linux partitions atleast...
The instructions you found on the Internet wipe out (well, actually fill with zeros) the first 16 sectors of your disk, including the MBR, but do not touch your partitions per se. However, it does wipe out the partition table, which appears to make the partitions (Linux and otherwise) disappear. You could try using dd to save the partition table first, zero the first sixteen sectors and re-write the partition table, and see if it works. But before you try anything like that, you really should back up anything of value .
 
Old 09-15-2007, 07:52 AM   #7
amrapali_bs
LQ Newbie
 
Registered: Sep 2007
Posts: 0

Original Poster
Rep: Reputation: 0
Can you please tell me how to use dd to save the partition table ?
 
Old 09-16-2007, 02:18 AM   #8
blackhole54
Senior Member
 
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
Just in case I screw up the offsets or something, or you make a typo, I would recommend first saving the whole MBR. If you have that, then you are guaranteed not to have lost the partition table. (Yes, we all make mistakes! ) I am assuming below that your primary drive is /dev/hda. (If it is /dev/sda or something, just adjust the commands accordingly.)

Code:
dd if=/dev/hda bs=512 count=1 > filename.MBR
Choose the filename you want and prepend a path if you wish. Just make sure you get it someplace safe, such as a floppy or flash drive.

Then to copy just the partition table:

Code:
dd if=/dev/hda bs=1 count=64 seek=446 > filename.pt
To restore just the partition table:

Code:
dd if=filename.pt of=/dev/hda bs=1 skip=446
Setting both the input and output block size (bs) to 1 in both cases may be a bit inelegant, but it should get the job done.
 
  


Reply



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
Install on laptop keeping xp and removing fedora netjack Ubuntu 11 04-13-2006 11:04 AM
Removing Linux and Installing WindowsXP faster80 General 10 09-10-2005 07:29 PM
Removing Fedora Core 4 Linux to Install Windows elliotfuller Linux - Newbie 1 05-08-2005 11:53 PM
Sharing e-mail across Fedora and WindowsXP dataangel Fedora 5 10-17-2004 09:32 AM
Can not install WindowsXP after uninstalling Fedora Core Test 3 futurist Fedora 20 07-30-2004 08:23 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > General

All times are GMT -5. The time now is 10:34 AM.

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