Should "Defragment and Optimize Drives" be running for an SSD?

Page 1 of 9 123 ... LastLast

  1. Posts : 31
    Windows 10, Linux Mint 18.3, Centos 7.5
       #1

    Should "Defragment and Optimize Drives" be running for an SSD?


    I just noticed this today. I have a Samsung 960 EVO with Win 10 pro installed. I was monitoring something else with the Task Manager when I noticed that the optimize operation was running (Under the Task Manager it is listed as Service Host: Disk Defragmenter: Optimize drives). So I checked out Control panel > Administrative Tools > Defragment and Optimize Drives and saw that it was indeed in the process of optimizing the drive. Am i correct in assuming optimizing means defragmenting? The C: Drive is recognized as an SSD and "Scheduled Optimization" is turned OFF. Knowing that it is bad to unnecessarily defragment an SSD due to wear levels, I was surprised to see it running. Shouldn't Windows be smart enough to not be doing this?
      My Computers


  2. Posts : 2,585
    Win 11
       #2

    Thanks for the heads up on this. I've seen posts about Win 10 not automatically defragging SSD's but mine was turned on (I have an SSD) and it showed it had been defragged 23 days ago. I turned defragging off.
      My Computers


  3. Posts : 31
    Windows 10, Linux Mint 18.3, Centos 7.5
    Thread Starter
       #3

    fireberd said:
    Thanks for the heads up on this. I've seen posts about Win 10 not automatically defragging SSD's but mine was turned on (I have an SSD) and it showed it had been defragged 23 days ago. I turned defragging off.
    Well, how do i turn it off? I have automatic defrag correction "optimize" turned off; am I missing another setting somewhere?
    Last edited by pjc123; 18 Aug 2018 at 13:37.
      My Computers


  4. Posts : 19,518
    W11+W11 Developer Insider + Linux
       #4

    What exactly says about SSD ? Optimize may mean De-fragment a HDD or run Trim for SSD. not same thing at all.
      My Computers


  5. Posts : 26,445
    Windows 11 Pro 22631.3447
       #5

    CountMike said:
    What exactly says about SSD ? Optimize may mean De-fragment a HDD or run Trim for SSD. not same thing at all.
    In Samsung Magician is has an option to Optimize so I would agree that De fragment is only for Spinners and Trim is for SSD's.
      My Computer


  6. Posts : 19,518
    W11+W11 Developer Insider + Linux
       #6

    Josey Wales said:
    In Samsung Magician is has an option to Optimize so I would agree that De fragment is only for Spinners and Trim is for SSD's.
    That's exactly right except in their infinite wisdom MS decided to keep neutral name "Optimize" although it's technically correct, Defrag and Trim are kinds of disk optimizing.

    Should "Defragment and Optimize Drives" be running for an SSD?-image.png
      My Computers


  7. Posts : 18,432
    Windows 11 Pro
       #7

    Here we go again....
    If Windows is recognizing the drive as an SSD in the Optimize Drives control panel, then it should be left alone to automatically optimize once a week. Windows 10 will run TRIM on the SSD needed to keep the drive running - well optimally. Windows WILL also defrag the SSD. But this is not the traditional defrag that we think about with spinners. It is a defrag that is run in order to keep the filesystem on the SSD from crashing due to running out of room in the filesystem database that keeps track of where the file fragments are located:

    The real and complete story - Does Windows defragment your SSD? - Scott Hanselman

    Quote from the article:
    The short answer is, yes, Windows does sometimes defragment SSDs, yes, it's important to intelligently and appropriately defrag SSDs, and yes, Windows is smart about how it treats your SSD.

    The long answer is this.

    Actually Scott and Vadim are both wrong. Storage Optimizer will defrag an SSD once a month if volume snapshots are enabled. This is by design and necessary due to slow volsnap copy on write performance on fragmented SSD volumes. It’s also somewhat of a misconception that fragmentation is not a problem on SSDs. If an SSD gets too fragmented you can hit maximum file fragmentation (when the metadata can’t represent any more file fragments) which will result in errors when you try to write/extend a file. Furthermore, more file fragments means more metadata to process while reading/writing a file, which can lead to slower performance.

    As far as Retrim is concerned, this command should run on the schedule specified in the dfrgui UI. Retrim is necessary because of the way TRIM is processed in the file systems. Due to the varying performance of hardware responding to TRIM, TRIM is processed asynchronously by the file system. When a file is deleted or space is otherwise freed, the file system queues the trim request to be processed. To limit the peek resource usage this queue may only grow to a maximum number of trim requests. If the queue is of max size, incoming TRIM requests may be dropped. This is okay because we will periodically come through and do a Retrim with Storage Optimizer. The Retrim is done at a granularity that should avoid hitting the maximum TRIM request queue size where TRIMs are dropped.
    Now, if Windows is not detecting the SSD as an SSD in the Optimize Drive settings window, such as with my SSD that is in a USB 3.0 to SATA enclosure...then it is a problem.
      My Computer


  8. Posts : 56,825
    Multi-boot Windows 10/11 - RTM, RP, Beta, and Insider
       #8

    NavyLCDR said:
    Here we go again....
    If Windows is recognizing the drive as an SSD in the Optimize Drives control panel, then it should be left alone to automatically optimize once a week. Windows 10 will run TRIM on the SSD needed to keep the drive running - well optimally. Windows WILL also defrag the SSD. But this is not the traditional defrag that we think about with spinners. It is a defrag that is run in order to keep the filesystem on the SSD from crashing due to running out of room in the filesystem database that keeps track of where the file fragments are located:

    The real and complete story - Does Windows defragment your SSD? - Scott Hanselman

    Quote from the article:


    Now, if Windows is not detecting the SSD as an SSD in the Optimize Drive settings window, such as with my SSD that is in a USB 3.0 to SATA enclosure...then it is a problem.
    What do you do in that case? The SSD in an enclosure? I'm going to do just that mid-week. EVO 860 512GB in a Thermaltake Blac-X enclosure.
      My Computers


  9. Posts : 18,432
    Windows 11 Pro
       #9

    f14tomcat said:
    What do you do in that case? The SSD in an enclosure? I'm going to do just that mid-week. EVO 860 512GB in a Thermaltake Blac-X enclosure.
    Mine is in an OICENT enclosure. It's tool less with a cover that is removed easily. It is a SANDISK SSD. SANDISK dashboard will not recognize the drive connected via the USB enclosure either, so I think it is the enclosure that is blocking things. I have a drive slide in bay in the front of my desktop computer, I plan on just removing the drive out of the enclosure once a month or so, popping it into the desktop computer bay and running TRIM on it. Since the drive is used in a USB enclosure anyway, I'm not too worried about it running at optimum speed always...but I certainly don't want Windows to do the traditional hard drive defrag on it. So I guess turn off optimization in settings for this drive only.
      My Computer


  10. Posts : 56,825
    Multi-boot Windows 10/11 - RTM, RP, Beta, and Insider
       #10

    NavyLCDR said:
    Mine is in an OICENT enclosure. It's tool less with a cover that is removed easily. It is a SANDISK SSD. SANDISK dashboard will not recognize the drive connected via the USB enclosure either, so I think it is the enclosure that is blocking things. I have a drive slide in bay in the front of my desktop computer, I plan on just removing the drive out of the enclosure once a month or so, popping it into the desktop computer bay and running TRIM on it. Since the drive is used in a USB enclosure anyway, I'm not too worried about it running at optimum speed always...but I certainly don't want Windows to do the traditional hard drive defrag on it. So I guess turn off optimization in settings for this drive only.
    Thanks. I'll have to give it a good under-the-covers inspection first time I fire it up in the Blac-X. I'll try to remember to post back how much smoke there is.....
      My Computers


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 19:23.
Find Us




Windows 10 Forums