What do you recommend? And why?

link|improve this question
3  
Be very careful when using non-windows provided defrag solutions if you're ever expecting to work with solid state disks. – Robert P Apr 13 '10 at 23:31
2  
needs to be community wiki... – studiohack Apr 14 '10 at 18:32
@pepkaro Basically all MyDefrag does is send "move this file to that location" commands to the API. The API is part of the operating system and can safely move almost any file on the disk, without risk and while the computer is in full use. Most defragmenters nowadays work this way. – zildjohn01 Apr 14 '10 at 22:18
Near duplicate (does not mention "free"): superuser.com/questions/32496, "Defragmentation Applications Comparsion / Alternatives". – Peter Mortensen Apr 14 '10 at 22:22
Near duplicate (does not mention "free"): superuser.com/questions/6058, "Best defragmentation software?". It is not tagged with Windows, but all the answers seem to be for Windows and the question is probably about Windows defragmentation tools. – – Peter Mortensen Apr 14 '10 at 22:23
feedback

migrated from stackoverflow.com Apr 14 '10 at 18:26

This question came from our site for professional and enthusiast programmers.

closed as not a real question by random May 27 '11 at 0:36

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. See the FAQ for guidance on how to improve it.

12 Answers

I like MyDefrag (based on JkDefrag). Its UI is a bit stark, but it's lightweight and tiny, designed to run automatically. It's not open-source as its predecessor JkDefrag was, but it is free.

link|improve this answer
Wow, just tried this and I agree - head and shoulders above window's native. After running the sort by name and then standard defrag, my machine is much snappier! – Cory House Dec 8 '08 at 2:48
2  
MyDefrag is not GPL anymore and not open source either. JkDefrag was but is not further maintained. – jdehaan Jun 27 '10 at 10:32
Well, that's a shame. I edited my answer to remove the bit about the GPL. – Brant Bobby Jun 28 '10 at 14:04
Also it uses the windows defrag API – UpTheCreek Feb 3 at 14:56
feedback

A nice, free tool is Defraggler (http://www.defraggler.com), which is capable of defragmenting specific files or folders. This speeds up defragmenting times when using it on only frequently used files.

link|improve this answer
feedback

Excuse the ignorance, but what's wrong with the Windows default one?

Win XP:

C:\Documents and Settings\All Users\Start Menu\Programs\Accessories\System Tools\Disk Defragmenter  
or  
C:\Windows\System32\dfrg.msc
link|improve this answer
4  
It can't defrag a single file, hard to call from a script or run periodically – Martin Beckett Nov 24 '08 at 4:57
It also does not touch some system files, and especially the swap file and sometimesthe antivirus definitions. Interestingly enough, MyDefrag also uses the Windows Defragmentation API, but for some reasons Windows Defrag doesnt touch the files where defragmentation might help the most. – Posipiet Jun 28 '10 at 14:17
@mgb: It's perfectly scriptable. Run defrag.exe from the command line. Vista+ is even better because a single command line argument can defrag all drives, not just one at a time. – afrazier Jun 28 '10 at 14:52
@afrazier contig.exe from the resource kit can drive defrag from the commandline and even do individual files – Martin Beckett Jun 28 '10 at 15:22
feedback

I use contig lot.

It allows defragment of single files! Very handy for defragging VPC-images.

Default Windows defragmenter dosen't allow single file defrags.

Contig 1.54 on technet

link|improve this answer
feedback

Actually I don't use defragmentation anymore. NTFS does a pretty good job of keeping fragmentation low. You can get a small gain for a short time when defragmenting. But other than looking at pretty pictures of moving blocks for some time I don't think it's worth the time.

link|improve this answer
3  
You obviously do not do a whole lot of I/O on your drive! I've seen my share of NTFS volumes become horribly fragmented, especially on backup servers and SQL servers... – Badman Feb 9 '09 at 12:49
If you run defragmentation software it will still report drives as being fragmented, that's to be expected they want to keep their market. Try to measure performance before and after defragmenting on a modern os with NTFS. Hardly any difference. – Mendelt Feb 9 '09 at 13:38
1  
Mendelt- Respectfully, I must state that you're not quite correct for all cases. We have seen multiple XP machines at my office that were lagging horribly (one to the point of taking 15 minutes to boot), but deframenting cleaned them up to where they were able to perform well again. Adding in other simple maintenance (CCleaner and disk compaction), and the machines were performing like new again. – Tom Jul 21 '09 at 16:10
And don't forget - defragmentation, in the long run, is good for the life of your hard drive. – muntoo May 27 '11 at 0:15
feedback

As long as you leave a reasonable amount of free space on each file system (at least 10-15%), fragmentation is hardly an issue with NTFS. (And if you're still using FAT32, that's your problem right there…)

That said, if you want to defrag individual files or folders, Defraggler or Contig (see pirho's post) are good solutions.

link|improve this answer
feedback

http://www.disktrix.com/UDFree.htm

Read the PDF after it's installed, it's full of useful information about how it defrag's and details on how a hard drive works.

I switched to this about 5 months ago and so did my co-workers. It has a "circular" disk defrag report which is neat. But I think the best part is the options it gives you in defragging. If you select "auto" it will check all the date/time stamps on files and move most recently used ones to the outer edge of the disk, making access times to those files much faster.

link|improve this answer
feedback

I use a utility which combines Windows Defrag with Contig called Power Defragmenter.

Searching for Power Defragmenter displays numerous links. The first I grabbed was from MajorGeeks:

Power Defragmenter

link|improve this answer
feedback

On a single drive "home" system then just use built in defrag. Another way to get a nice clean and tidy drive is to ghost the drive. You may get a temporary improvement in disk IO.

If you're referring to a Windows Server, then any decent server would use a 3 or more drive RAID 5 array for storage*. There is no point defragmenting this drive as every other 64KB (typical) block is stored on a different drive. Your "large contiguous file" is actually dispersed almost randomly across the drives.

Also, with any multi-user system, there is no guarantee that the "drive head" will seek nicely across the platter without being interrupted by another user or process.

Finally, HDD's have large read ahead buffers, multiple platters and can store the data in a vastly different filesystem structure than you may expect.

*Yes, I know, RAID 5 is not appropriate for all server types, i.e. Databases.

link|improve this answer
feedback

I find UltimateDefrag pretty good - it uses strategic file placement to optimize performance by moving unused files (zip files etc.) to 'slow' parts of the drive, moving and grouping directories as well as requiring very low amounts of free space for defragmenting.

link|improve this answer
feedback

I second UltimateDefrag. The standard Windows defrag only puts fragments of files together on the hard disk but UltimateDefrag reorganises the location of files for quicker access.

There is a freeware edition of this app here

link|improve this answer
The built-in Windows Defrag most certainly reorganizes files on disk for quicker access. That's the entire point of the Prefetcher in XP and newer. Even Windows 98 had a rudimentary version of this called the (AppLog)[cwdixon.com/support/win98_support/disk_defrag.htm], which the built-in defragger would use to organize application files for faster startup. – afrazier Jun 28 '10 at 14:47
feedback

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