Disable Defragmentation of Boot Files

Page 1 of 2 12 LastLast

  1. Posts : 42
    Windows 10 x64
       #1

    Disable Defragmentation of Boot Files


    Hello,
    In Windows 10 1903, to disable this via registry which path/key is used?
    If it's not possible to do via registry, is there a command to use in a batch file?
    Thanks.
      My Computer


  2. Posts : 5,048
    Windows 10/11 Pro x64, Various Linux Builds, Networking, Storage, Cybersecurity Specialty.
       #2

    Hmm.

    How do you know that your files are being Defragmented in the first place?

    Take a peek at this -

    Change Optimize Drives Schedule Settings in Windows 10

    Hope it helps.

    Last edited by Compumind; 22 Aug 2019 at 10:45.
      My Computer


  3. Posts : 42
    Windows 10 x64
    Thread Starter
       #3

    Thanks, actually I was trying "Windows 10 Manager" and it had some tweaks for optimizing SSDs.
    I never use such apps after clean Windows setup, but I just run my huge customized reg files to finish setup.
    So as I mentioned, I just need to Disable Defragmentation of Boot Files via registry, if not possible via cmd, I know it's possible since they already did it.
    Best :)
      My Computer


  4. Posts : 5,048
    Windows 10/11 Pro x64, Various Linux Builds, Networking, Storage, Cybersecurity Specialty.
       #4

    Kishvand said:
    Thanks, actually I was trying "Windows 10 Manager" and it had some tweaks for optimizing SSDs.
    I never use such apps after clean Windows setup, but I just run my huge customized reg files to finish setup.
    So as I mentioned, I just need to Disable Defragmentation of Boot Files via registry, if not possible via cmd, I know it's possible since they already did it.
    You don't need to.

    Just do this 1-2 times per week and you are fine:

    Start -> Programs -> Windows Administrative Tools -> Defragment and Optimize Drives

    Works for both SSD and HDD.

      My Computer


  5. Posts : 9,754
    Mac OS Catalina
       #5

    Boot files do not fragment. Forget those tweaks about speeding up the SSD. The OS housekeeping will take care of what needs to be "TRIMmed". Defrag on a SSD is not the same as how it is with a Platter Drive.
      My Computer


  6. Posts : 18,421
    Windows 11 Pro
       #6

    I agree, the automatic/ default settings for drive optimization work just fine in Windows 10. No real need or benefit from tweaking it.
      My Computer


  7. Posts : 42
    Windows 10 x64
    Thread Starter
       #7

    Found it, here it is, thanks anyway :)

    'Disable Boot Files Defrag
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction]
    "Enable"="N"
      My Computer


  8. Posts : 13,301
    Windows 10 Pro (x64) 21H2 19044.1526
       #8

    Kishvand said:
    Found it, here it is, thanks anyway :)

    'Disable Boot Files Defrag
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction]
    "Enable"="N"
    Which merely shuts down the Defrag/Trim at startup. Saves a whole 5 seconds of startup time.
    And makes your manual Defrag/Trim longer.
      My Computers


  9. Posts : 9,754
    Mac OS Catalina
       #9

    Kishvand said:
    Found it, here it is, thanks anyway :)

    'Disable Boot Files Defrag
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Dfrg\BootOptimizeFunction]
    "Enable"="N"
    Keep TRIM active. Otherwise you can lose data if the drive is not told by the OS when problems are seen.
      My Computer


  10. Posts : 525
    Windows 10
       #10

    bro67 said:
    Keep TRIM active. Otherwise you can lose data if the drive is not told by the OS when problems are seen.
    Interesting. Could you post some links to know more about this theory?
      My Computer


 

  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 05:43.
Find Us




Windows 10 Forums