I have an external (USB) disk, which has been working OK for some time and shows no errors whatsoever in /var/log/$relevantfiles (no errors on reading/writing, for example).Here's the thing:if I ask for sudo fdisk -l /dev/sda this returns:Disk /dev/sda: 1000.2 GB, 1000204886016 bytes255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectorsUnits = sectors of 1 * 512 = 512 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 512 bytes / 512 bytesDisk identifier: 0x24796452Device Boot      Start         End      Blocks   Id  System/dev/sda1              63  1953520064   976760001   83  Linuxwhich is exactly how I did it.Now, I want to recover a partition in this disk to use for some other purposes, which require hfs, instead of ext{2,3,4}.So I turned myself to the old dear parted to resize the partition and create a new one.Asking parted this returns:(parted) print                                                            Model: ST310005 28AS (scsi)Disk /dev/sda: 1000GBSector size (logical/physical): 512B/512BPartition Table: macNumber  Start  End    Size    File system  Name            Flags1      512B   1535B  1024B                partition map2      368MB  371MB  2982kB               OneClick-Readyand if I run gparted I see all the empty space, and I cannot resize my partition, since it's not there.Any pointers how to fix this things? I've never seen anything like it. The whole thing's running on a raspberry pi, using raspbian.Thanks!
parted not recognizing my current partition on external disk. How to fix without losing data?
linux;raspberry pi;gparted;parted
You appear to have both a dos and mac partition table on the disk, and parted is recognizing the mac one.  You should be able to zap the mac partition table with:sudo dd if=/dev/zero count=1 bs=2 of=/dev/sda