Windows, SSDs and Defragmentation: the definitive answer

Martin Brinkmann
Jan 20, 2015
Windows
|
10

Solid State Drives are great. If you switch from a platter-based drive to a SSD you will think you are in speed-heaven for the first time. Windows boots faster, programs start faster and everything seems to be improved speed-wise.

With the first generation of Solid State Drives, things deteriorated quickly due to limited write cycles and controllers that were far from optimal.

New generation drives, like the Samsung 850 Evo,  benefit from better firmware and controllers, which makes them more durable and faster.

Drives did benefit from new operating system versions as well. Windows 7 introduced TRIM and Windows 8 came along with its own set of optimizations specifically for Solid State Drives.

solid state drive defrag

Common Wisdom is that Solid State Drives should not be defragmented. This is based on the fact that SSDs support limited writes and that defrag operations cause many writes on the device.

If you have installed Windows 8 on a system with a Solid State Drive or bought a PC with one running the operating system, you may have noticed that defrag runs on the Solid State Drive at times.

You may also have read about it on various blogs on the Internet.

If you check your system with a program like Check Boot Speed you get a detailed report that includes defragmentation information so that you know if your SSD gets defragmented or not.

Is defragmentation good or bad on SSDs?

The question that needs to be answered is whether that is a good thing that is done on purpose or a bug.

Microsoft confirmed to Scott Hanselman (who is a member of Microsoft's Web Platform Team) recently that Windows defragments Solid State Drives sometimes under Windows 8 (and probably newer versions as well) and that it does so on purpose.

SSDs are defragmented every 28 days on Windows 8 and newer if Volume Snapshots are enabled (the feature is used by System Restore and thus enabled by default) on the system. Defragmentation occurs if a drive is highly fragmented which slows down the read and write process on drives because of additional metadata that needs to be processed.

In addition, it is possible that drives hit maximum file fragmentation (when metadata cannot represent more file fragments) which will result in errors when trying to write or extend the file.

The underlying issue seems to be a limitation of the file system in regards to fragments and that Microsoft's workaround for it is to use defrag to reduce the number of fragments.

This makes defrag on SSDs a necessity under Windows even though that means additional writes on the system.

Summary
Windows, SSDs and Defragmentation: the definitive answer
Article Name
Windows, SSDs and Defragmentation: the definitive answer
Description
Is Windows defragmenting Solid State Drives? If so, is that a bug or is this done on purpose and why?
Author
Advertisement

Tutorials & Tips


Previous Post: «
Next Post: «

Comments

  1. SSDguy said on January 21, 2015 at 4:59 am
    Reply

    SSDs do suffer if they are fragmented, this can and usually does cause write amplification, which lowers the speed data is written at as well as reduces its lifespan. In bad cases the amplification factor can reach absurd three digit cases or more, burning through the flash cells quickly. Ie. a 100 mb file burning through 10 gb of flashcells.
    To avoid that some careful defragmentation every now and then helps keep things going smoothly. Trim on its own has shown to not do this job well.
    For more and better explanations refer to the Anandtech link.
    http://www.anandtech.com/show/2829/4

    Also write amplification is one reason why people may want sturdy SSDs, despite not writing much if they fail to do defrag.

  2. anon said on January 20, 2015 at 6:54 pm
    Reply

    Totally unrelated but you should check out hddb martin, it’s a very fast file indexer and is practically a successor for locate32. Aside from few quirks (like not being able to sort some column) it’s among the best IMO. It even has portable option for people like me.

  3. Howard said on January 20, 2015 at 5:41 pm
    Reply

    My SSD has scheduled optimization turned off yet it is still optimized (trimmed) every day more or less. Is there a way to determine what is doing this ? I have checked relevant programs I have installed that might be doing this and have found no setting turned on.

    It is an ASUS with with windows 8.1 64-bit.

  4. jasray said on January 20, 2015 at 5:01 pm
    Reply

    May want to check similar links about SSD lifespan and defragging. The number of writes needed to really wear out a SSD is so large that any HDD in use will most likely die before the SSD.

    “Durability

    The short answer is I wouldn’t worry about it.

    For applications which are heavy on random writes, you’re OK (meaning a life span of over 5 years) up to about 25 million writes per day per drive, which is nearly double the IO capacity of the fastest hard disk drives.”

    http://maxschireson.com/2011/04/21/debunking-ssd-lifespan-and-random-write-performance-concerns/

  5. fokka said on January 20, 2015 at 4:40 pm
    Reply

    even HDDs i wouldn’t defrag/optimize on a weekly basis and as we see at Nerdebeu’s example windows can’t really be trusted with SSDs neither. i don’t think a monthly defrag will be very harmful with the longevity of modern SSDs, but i’d just leave that decision to the software that came with the SSD itself.
    if ones OCD/performance paranoia is that huge, just defrag your SSD once or twice a year so you can feel better and leave it at that.

  6. Tim said on January 20, 2015 at 1:16 pm
    Reply

    What’s annoying is how long Microsoft have taken to explain why Windows defrags SSD’s.

    Two and a half years we’ve been saying that ‘Optimise Drives’ in Windows 8 sometimes defrags SSD’s rather than just trim them, only to be met with either silence or the usual “Windows doesn’t defrag SSD’s”. And that’s despite posting detailed screenshots showing it going through the multi-pass defrag process on an SSD drive.

    They really need to respond quicker with this type of thing, we’re now on Windows 10 FFS!

    1. Usnapper said on January 20, 2015 at 3:29 pm
      Reply

      Summed it up well I believe Tim.
      Hardware manufacturers should give definitive information about their products that we can rely on.

  7. intelligencia said on January 20, 2015 at 12:13 pm
    Reply

    @Nerdebeu
    “I defragment my mechanical hard drives, and I use software manufacturers for SSD. Driver Magician and Toolbox.”

    Indeed!

    I also follow your sage advice. I have an all solid-state laptop (running Windows 7) and I am NOT about to trust Windows to De-fragment my SSD’s – – and I Only use Intel’s ToolBox to Optimize these (since Intel is the manufacturer of these particular drives)!

    i

  8. Nerdebeu said on January 20, 2015 at 11:56 am
    Reply

    Three comments.

    When there are two different types of disks: HD and SSD, the description of the maintenance task is different. Defragmentation for HD and optimization for SSD. Would that be to not scare people or is that are two different actions?

    Then, on the alleged intelligence of Windows and what he made with the SSD. On my PC, I have two SSD and several mechanical hard drives. Each SSD installed a different Windows. Currently 8.1 on a Samsung 840 pro and 10 TP on an Intel.

    Sometimes I stay long on an OS without working with the other.When I return to the OS that I abandoned some time, Windows, told me, and it is logical, the SSD has need to be optimized (regardless of the version of Windows). Okay, but… But Windows also told me that I have to optimize one I’ve spent the last few weeks (and I optimized two days before …).

    What is to say that Windows is not based on the real state of ‘fragmentation’ of the SSD, but well on the date on which the latest optimization occurred, according to him. If I am not gone on Windows 10 for several weeks, it tells me that I need to optimize it, but also that I need to optimize the disk on which is 8.1, and the reverse is also true.*

    Another note, I disable the scheduled task (automatic service)of maintenance of discs and I do it manually. I defragment my mechanical hard drives, and I use software manufacturers for SSD. Driver Magician and Toolbox.

    If I run optimizations via these softwares, sometimes (not always) Windows tells me that the SSD needs to be optimized. And I must say that I have more confidence in the manufacturers than in Windows tools.

    Third Note: Windows always reports that the recovery partitions (on SSD) must be optimized, while still unable to (manually or automatically, and both GPT or MBR installations).

    Windows cannot optimize these partitions, but it signals a need for optimization of these very specific partitions Manager, it signals the need for optimization in “Optimize Drives”

    Conclusion, my trust in management of SSD by Windows is very relative.

    * I noticed the same phenomenon with 7 and 8 on two different SSD, and also 7 and 8.1.

Leave a Reply

Check the box to consent to your data being stored in line with the guidelines set out in our privacy policy

We love comments and welcome thoughtful and civilized discussion. Rudeness and personal attacks will not be tolerated. Please stay on-topic.
Please note that your comment may not appear immediately after you post it.