DIY, Tech

How to Safely Defrag a MAC

Indeed, there has never been a defragmentation utility in the different versions of OS X, and there is still none in Yosemite.

I will not explain what the cause of fragmentation of a disc is because all explanations are available online in a well-known encyclopedia. I will focus here on why and how to defrag a Mac.

The benefits of defragmentation are obviously faster access to data and therefore a gain in performance. Historically included in the operating systems of Windows, Apple does not consider it necessary to incorporate it into its OS, for good reasons as we will see.

Is it necessary to defrag Mac?

The users most prone to fragmentation on Mac are those who work with multimedia files – large image files, videos or sounds – regularly. The article also states that older hard drives are more prone to fragmentation, as the Mac OS X HFS Plus system automatically defragments itself through a process called Hot File Adaptive Clustering (HFC). So, users who regularly change Macs or external hard drives probably never need to defragment.

This corresponds exactly to the experience I have of defragmentation on Mac.

Do You Need to Defragment a Mac’s Hard Drive?

I did a lot of MAO and Video Editing on my old Macbook (2008 model) and the first time I defragmented it (after four years) the speed regained was quite good (see solutions for mac too slow ).

When I renewed the experience on a recent iMac after a few months of use – recording the media files externally and no longer on the system disk – it was actually barely fragmented and I did not feel any improvement in performance after defragmentation.

  • For SSD Disks:

There is no need to defrag SSDs because they have their own maintenance system known as TRIM.

Fragging wonderful: The truth about defragging your SSD

If you purchased your Mac directly with an SSD, TRIM is enabled by default. For those who have changed the disk on an existing machine the TRIM is not activated, and it must be activated through a utility like TrimEnabler.

  • Defragment an external hard drive:

I manipulated images and sounds (and I have some serial downloads) for 2 years on a 1TB external hard drive that started rowing seriously, until I understood how fragmented it was.

When a disk like this is very fragmented, its defragmentation can last up to 48 hours.

If you defragment the system disk, shutting it down is a very bad idea, and you may not be able to restart the Mac.

Defragment an external hard drive is very easy: launch iDefrag then select the disk, you will see the summary of the fragmentation. To start the defragmentation, choose an algorithm in the drop-down menu (Full Defrag is the most complete) and click on the PLAY button. In this case, the defragmentation lasted 48 hours!

How to Fix a Slow External Hard Drive

  • Defragment the system hard drive:

The advantage of iDefrag is that it allows a Full Defrag of the system disk without the need to reboot from a DVD or disk image. Just proceed in the same way as with an external drive, with the only difference that iDefrag will restart before starting defragmentation is the reboot-and-defragment mode. Below we can see that the disk of iMac after 2.5 years is only fragmented, logical because all the media files were on the external disk mentioned above, which took expensive fragmentation level instead of the system disk.

If there is not enough free space for iDefrag to defragment the system disk with a simple reboot, you will need either:

  • restart from a disk image on an external disk or a USB key,
  • connect the Mac to format in “Target Disk Mode”  and start defragmentation from the ‘master’ computer.

Generally, moving the iPhoto library is enough to recover the free space needed.

I played the game: I connected my iMac and MacBook with a thunderbolt cable, then restart the iMac by keeping the T key pressed. Once the computer starts, the Thunderbolt icon will appear on the screen and the disc will appear in the Finder on the other machine.


In short, the older a Mac is, the more likely it is to fragment, the newer ones delivered with an SSD will not break up. The defragmentation on Mac is, therefore, to disappear with the advent of SSD disks. Any HFS Plus formatted disk used to work with large media files will fragment. This is also valid if you download series as a pig, then erase the files and re-download from above. In this case, it is surely worth the defragmenter.

If you like this, You'll love These.

You Might Also Like