LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Laptop and Netbook (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/)
-   -   Need help formatting hard drive (https://www.linuxquestions.org/questions/linux-laptop-and-netbook-25/need-help-formatting-hard-drive-735867/)

ziggyjoe21 06-26-2009 01:25 PM

Need help formatting hard drive
 
Just bought Dell Inspiron laptop with Ubuntu, but need to install Windows on it.

I read you have to format the hard drive before you can install windows, but I don't know how to. Dell tech support charges $130 for over the phone help.

Any help is greatly appreciated.

italiano40 06-26-2009 01:30 PM

if you need to format and partition a drive i would install gparted on ubuntu if you want the whole drive reformatted then use the live cd of gparted

pixellany 06-26-2009 01:52 PM

"formatting the drive" normally means installing a filesystem. I think all you need to do is delete all the partitions--this you can do with any partition utility. Any Linux live CD will have a partitioning tool, or you can use GParted, which comes on its own live CD.

vulariter 06-29-2009 11:51 PM

If you want to get rid of everything on the drive, before you install Windows, it's more a matter of destroying the partition table (the "map" that tells an OS where the partitions are), than it is about actually reformatting. Reformatting is to create a new file system. Creating any new file systems is essentially useless, since most Windows installers (XP, 2000, NT, and further back) want to reformat the partition(s).

I say, boot into a Linux live CD and run these key strokes to wipe out your primary drive's partition table (once you are on a root command line):

fdisk /dev/sda

<press return>

<press "o">

<press enter>

<press "w">

<press enter>

reboot

<press enter>

<done>

Once you reboot, insert your Windows CD (hopefully XP), and when you get to the partitioning prompt, create your partition(s) as with ntfs (and don't use the "quick format", if you can help it)....

Keep in mind that the instructions I've given are highly destructive and are to used with care. Please also keep in mind that this method will destroy your Ubuntu install (perhaps, beyond repair), although this method should not be considered a "secure" delete (for which you should lookup the "dban" live CD).

Enjoy!

vulariter

shane25119 07-01-2009 01:07 AM

The above respondents are offering excellent advice.

But remember one thing... Windows doesn't play too nice with other operating systems and often will destroy the GRUB boot menu (i.e. unless you use a boot floppy you're going to boot into Windows everytime) solution- install Windows first and Linux second.

jschiwal 07-03-2009 08:22 AM

I think that you want to use gparted to reduce your Linux partition's size, making room for Windows. Leave the free space unformatted. Select this unformatted space during the windows installation.

After installing Windows, you will need to fix the Linux entries in /boot/grub/menu.lst and if needed in /etc/fstab to reflect your new partition scheme. The new naming scheme for partitions in menu.lst and the fstab files may help reducing the amount of fixup you need. For example, if fstab uses the uuid of the partition instead of the device name, it won't need editing.

Add an entry for Windows to /boot/grub/menu.lst. Mine looks like this:
[code]
title Windows Vista
rootnoverify (hd0,1)a
---
If your Dell computer has a "recovery" partition, you might not want to delete that partition, just in case.

Good Luck!

repo 07-03-2009 08:25 AM

Quote:

Just bought Dell Inspiron laptop with Ubuntu, but need to install Windows on it.
Do you want to remove ubuntu and install windows, or do you want to install windows together with ubuntu (dual boot) ?


All times are GMT -5. The time now is 03:02 AM.