How to find where files reside on a partition

Solution 1:

A disk defragmenter might do what you want for this. Possibly.

OS X since 10.3 automatically defragments files, but doesn't do anything to move them all to the 'top' of your volume. A 3rd party defragmenter might do this, which theoretically would clear out all the cruft that's preventing non-destructive repartitioning from taking place.

The other option is what Apple recommends in that dialog: clone the volume at the filesystem level, reformat, and then clone it back--when it rewrites, all of the files will be written one by one at the 'top' of the volume. Of course, if you need to do that, you might as well repartition while you're in the process of reformatting the disk.

Solution 2:

There are a few third-party utilities that show disk usage graphically:

  • Disk Inventory X
  • GrandPerspective
  • DaisyDisk

If you're comfortable with the command-line, there's also du.