Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have an old Mac OS X drive that I would like to reuse as external storage. I'm trying to reformat the drive to allow me to do this using Linux parted. I've been successful removing all the old partitions except for the 32 KB head partition:

GNU Parted 2.2
Using /dev/sdc
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print                                                            
Model: ST375064 0NS (scsi)
Disk /dev/sdc: 750GB
Sector size (logical/physical): 512B/512B
Partition Table: mac

Number  Start  End     Size    File system  Name   Flags
1      512B   32.8kB  32.3kB               Apple

(parted) rm 1                                                             
Error: Partition map has no partition map entry!                          
Fix/Cancel? Fix                                                           
(parted) print
Model: ST375064 0NS (scsi)
Disk /dev/sdc: 750GB
Sector size (logical/physical): 512B/512B
Partition Table: mac

Number  Start  End     Size    File system  Name   Flags
1      512B   32.8kB  32.3kB               Apple

This appears to be filed as a bug for the related gparted program, so I'm guessing that parted has the same problem.

I also tried using fdisk:

sudo fdisk -c -u sdc
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x23b7e238.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Is it possible to use any Linux tool to accomplish this? This super user question seems to indicate the problem is solvable by installing a fresh OS, but I need a generic storage drive rather than a fresh OS install, so I'm hoping for an easier way.

share|improve this question
    
Just a heads up to let you know that PowerPC Macs (except for some very late models) won't boot from anything other than a Apple Partition Map drive. –  user203617 Mar 2 '13 at 14:49

2 Answers 2

up vote 1 down vote accepted

Have you read the bug report you mention? Its comment #4 says that the 32 kB partition contains the partition table itself, which is why it cannot be removed. (This is what Error: Partition map has no partition map entry! refers to.)

This is an implementation detail of the Apple Partition Map format, which your disk currently uses. If you want, you can change the disk to use GPT or MBR instead.


You can write a new, empty partition table (aka "disklabel") using parted's mklabel command. This will completely remove all existing partitions, if any.

  • mklabel gptGUID partition table, used by Intel Macs, supported by Linux, Windows Vista and above. (Recommended, unless you want to install Windows on the disk.)

  • mklabel msdosMBR, used by PCs, works practically everywhere, but comes with the "primary/extended" partition mess. (Use MBR if you need very good OS support, but pick GPT otherwise.)

  • mklabel macApple Partition Map, used by older (non-Intel) Macs, although Intel Macs and Linux can read it as well. (APM has been made obsolete by GPT.)


In addition to parted, GPT and MBR tables can be created with gdisk and fdisk respectively, similar to the command you tried – it seems that you just forgot to tell fdisk to actually write the new MBR to disk; "Changes will remain in memory only, until you decide to write them."

In fdisk, use c to force creating a new MBR partition table (discarding the old table), and w to write it to disk. (The -c -u command-line options aren't needed.)

In gdisk (sometimes gptfdisk), o will create a new GPT (importing existing partitions from APM or MBR), w will write it to disk.

share|improve this answer

Did you try to change the partition table to Reiser or EXT3?

I assume that you are trying to use Linux to do this, so did you umount the drive first?

Did you try to just stomp the partition by creating a new one on top of it?

The following may assist in your formatting woes:

Howto format a WD external hard drive

GPARTED MAN page

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.