Image of the glider from the Game of Life by John Conway
Skip to content

OS Defragmentation

I always enjoy getting into technical discussions. Especially when the other person actually knows what they are talking about. In this case, it was during church, and the topic of discussion was defragmenting hard drives.

For those unfamiliar with fragmentation, filesystems fragment files when data is written to the hard drive. It doesn't matter what operating system you are using or what filesystem is used. Data is fragmented regardless. This means that your file may be scattered into several hundred pieces all over the drive. Fragmented files take the hard drive extra time to locate all the pieces for completion. The closer and less fragmented the data, the better the performance. However, it is how the operating system and filesystem treat that fragmentation that becomes the difference between performance and lack thereof.

The discussion between a fellow church member and I was how often we degrag our hard drives. I mentioned that in Windows, I have it set to defrag every Sunday at 2:00am. I just can't stand the performance issues when seriously fragmented. However, with Linux and Mac, I never need to worry about it, as both automatically defrag the drives in the background while working on the computer. This seemed to amaze him as he didn't think Mac atutomatically defrags its drives. It does. It's UNIX. Well, at least Panther 10.3.x and 10.4.x do.

With that said, there are defragging utilities for both Linux and Mac. The utility for Linux works only for the ext2 filesystem, and has not been maintained for years. In fact, it is less than par. It isn't worth the less than 2% performance increase you might see. As far as Mac goes, it only defrags the data, and does not optimize the disk automatically. There are only two tools that I am aware of for defragging and optimizing the disk. The first is iDefrag for $30. I hear it is decent and well-maintained. The second, for $90, is Disk Warrior. Disk Warrior will create a new map file for all the locations of the fragmented files. Both of them solid, neither one free.

Overall, there is really no need to defrag in Linux or Mac like there is in Windows.

Post a Comment

Your email is never published nor shared.