Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linux partition removal? 1

Status
Not open for further replies.

gerald

Programmer
Apr 10, 2000
152
0
0
US
Hiya... I have a little issue I was hoping somebody could help me out with.

I have a hard drive which I partitioned using Disk Druid that came with RedHat 6.2. I create a native Linux partition and 2 swap partitions.

Now I need to use this hard drive in a Windows machine, and I cant get rid of the partitions.

I have tried using DOS fdisk, which tells me I have a primary DOS partition of 24megs and an extended dos partition which takes up the other 8gigs. If I try to delete the extended dos partition it tells me that I cannot delete it while there are logical drives assigned. If I try to list the logical drives, it tells me there are none so I cannot delete anything.

I have tried booting up using the RedHat Install CD and get to the Disk Druid again, but I cant get it to delete the partitions it wont activate any changes that I make until I continue a few more steps in the install process.

My question is, is there any easy way that I can just remove all partition information using Linux?

I can mount the drive on another linux machine and do it, but I am not familiar with what commands I would use.

I am very pressed for time on this issue or I would be able to research it and figure it out on my own. So if anybody has any clues plz let me know. Ill buy ya a beer. heh

Regards,
Gerald
 
hi,

i personally use aefdisk ( Ranish partition manager and Linux fdisk to manage partitions. one thing that i would not do without anymore is a linux boot disk containing tomsrtbt ( with this, i can boot whatever machine and read, write, delete, manage whatever partitions: ext2, fat, fat32, ntfs... it's great.

if you go with linux fdisk (tomsrtbt), just start fdisk (fdisk /dev/hda if hard disk #1) and then use the 'm' command to print out the menu. i think it's 'd' to delete a partition. once all is done just go with 'w' to write the new table to disk. then reboot using a win boot disk and format the drive.
 
Do it the easy way. Use the Linux fdisk from the DOS tools folder of the installation disk. This can't (won't?) write the DOS MBR record, but it can easily wipe the disk clean of all existing partitions. Then the DOS fdisk can do the rest. (Well, you could use it to create the new windows partition, but unless you intend to only use a part of the disk for Windows, I wouldn't bother.)
 
Do re-write the DOS MBR, there's an undocumented switch for fdisk,

fdisk /mbr

which will re-write your mbr.

I've had this trouble several times. Also, if you mount the drive on another linux system, you can use the linux fdisk program, which is text based, but not too hard to use.
 
Are you sure it's not fdisk/mbr (without the space)?
 
it will work either way rycamor, the switch character '/' is special: dir/w and dir /w behave the same
Mike
michael.j.lacey@ntlworld.com
 
Try with wdclear.exe an utility i found in the Net, can't remember the location, but if you don't get it, e-mail me and i'll send you.

This utility cleans the drive (write 0's to all the hd cylinders), and let you make a new partition
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top