Devices Check, Enable or Disable TRIM Support for SSD Drives in Windows 11

  • Thread starter Thread starter Brink
  • Start date Published: Start date Updated Updated:
  • Tags Tags
    drive

Defrag_banner.webp

This tutorial will show you how to check the current status of TRIM support for SSD drives, and to enable or disable TRIM support on SSD drives with NTFS and ReFS file systems for all users in Windows 10 and Windows 11.

When you delete a file on a SSD or NVMe drive, Windows sends a TRIM command to the drive to notify the drive of pages which no longer contain valid data. The SSD will then erase those pages in the background.

The TRIM command is essential to maintain the performance of SSD and NVMe drives at an optimal level over the lifetime of the drive. TRIM functions by actively deleting invalid data from the SSD’s memory cells to ensure that write operations perform at full speed. Since a memory block must be erased before it can be re-used, TRIM improves performance by pro-actively erasing pages containing invalid data, allowing the SSD to write new data without first having to perform a time-consuming erase command.

For a file deletion operation, the operating system will mark the file's sectors as free for new data, then send a TRIM command to the drive. After trimming, the drive will not preserve any contents of the block when writing new data to a page of flash memory, resulting in less write amplification (fewer writes), higher write throughput (no need for a read-erase-modify sequence), thus increasing drive life.

Delete notifications (also known as trim or unmap) is a feature that notifies the underlying storage device of clusters that have been freed due to a file delete operation. In addition:
  • For systems using ReFS v2, trim is disabled by default.
  • For systems using ReFS v1, trim is enabled by default.
  • For systems using NTFS, trim is enabled by default unless an administrator disables it.
  • If your hard disk drive or SAN reports that it doesn't support trim, then your hard disk drive and SANs don't get trim notifications.
  • Enabling or disabling doesn't require a restart.
It is recommended to always keep TRIM support enabled for SSD and NVMe drives.

If you are trying to recover deleted data from a SSD or NVMe drive, then temporarily disabling TRIM support may help allow you to recover the data before TRIM clears it permanently.

References:



Contents





Option One

Check Current Status of TRIM Support


1 Open Windows Terminal, and select either Windows PowerShell or Command Prompt.

2 Copy and paste the command below into Terminal, and press Enter. (see screenshots below)

fsutil behavior query disabledeletenotify

3 You can now check the output to see if TRIM support is currently enable or disabled.

TRIM Support Output​
Description​
NTFS DisableDeleteNotify = 0TRIM support enabled for SSDs with NTFS
NTFS DisableDeleteNotify = 1TRIM support disabled for SSDs with NTFS
NTFS DisableDeleteNotify is not currently setTRIM support for SSDs with NTFS is not currently set, but will automatically be enabled if a SSD with NTFS is connected.
ReFS DisableDeleteNotify = 0TRIM support enabled for SSDs with ReFS
ReFS DisableDeleteNotify = 1TRIM support disabled for SSDs with ReFS
ReFS DisableDeleteNotify is not currently setTRIM support for SSDs with ReFS is not currently set, but will automatically be enabled if a SSD with ReFS is connected.

query_disabledeletenotify-0.webp

query_disabledeletenotify-1.webp





Option Two

Enable TRIM Support


This is the default setting.

You must be signed in as an administrator to use this option.


1 Open Windows Terminal (Admin), and select either Windows PowerShell or Command Prompt.

2 Copy and paste the command below for what you want into Terminal (Admin), and press Enter. (see screenshot below)

(Enable TRIM support for SSD with NTFS file system)
fsutil behavior set disabledeletenotify 0

OR​

fsutil behavior set disabledeletenotify NTFS 0

AND/OR

(Enable TRIM support for SSD with ReFS file system)
fsutil behavior set disabledeletenotify ReFS 0

set_disabledeletenotify-0.webp




Option Three

Disable TRIM Support


You must be signed in as an administrator to use this option.


1 Open Windows Terminal (Admin), and select either Windows PowerShell or Command Prompt.

2 Copy and paste the command below for what you want into Terminal (Admin), and press Enter. (see screenshot below)

(Disable TRIM support for SSD with NTFS file system)
fsutil behavior set disabledeletenotify 1

OR​

fsutil behavior set disabledeletenotify NTFS 1

AND/OR

(Disable TRIM support for SSD with ReFS file system)
fsutil behavior set disabledeletenotify ReFS 1

set_disabledeletenotify-1.webp


That's it,
Shawn Brink


 
Last edited:
In what scenario would you want to disable TRIM?
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security

My Computers

System One System Two

  • OS
    Windows 11 Pro for Workstations
    Computer type
    PC/Desktop
    Manufacturer/Model
    Custom self build
    CPU
    Intel i7-8700K 5 GHz
    Motherboard
    ASUS ROG Maximus XI Formula Z390
    Memory
    64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz (F4-3600C18D-32GTZR)
    Graphics Card(s)
    ASUS ROG-STRIX-GTX1080TI-O11G-GAMING (11GB GDDR5X)
    Sound Card
    Integrated Digital Audio (S/PDIF)
    Monitor(s) Displays
    2 x Samsung Odyssey G75 27"
    Screen Resolution
    2560x1440
    Hard Drives
    1TB Samsung 990 PRO M.2,
    4TB Samsung 990 PRO M.2,
    TerraMaster F8 SSD Plus NAS
    PSU
    Seasonic Prime Titanium 850W
    Case
    Thermaltake Core P3 wall mounted
    Cooling
    Corsair Hydro H115i
    Keyboard
    Amazon Basics Wired Full Keyboard MD005
    Mouse
    Logitech MX Master 4
    Internet Speed
    2 Gbps Download and 100 Mbps Upload
    Browser
    Chrome and Edge
    Antivirus
    Microsoft Defender
    Other Info
    Logitech Z625 speaker system,
    Logitech BRIO 4K Pro webcam,
    HP Color LaserJet Pro MFP M477fdn,
    CyberPower CP1500PFCLCD
    Galaxy S23 Plus phone
  • Operating System
    Windows 11 Pro
    Computer type
    Laptop
    Manufacturer/Model
    Surface Laptop 7 Copilot+ PC
    CPU
    Snapdragon X Elite (12 core) 3.42 GHz
    Memory
    16 GB LPDDR5x-7467 MHz
    Monitor(s) Displays
    15" HDR
    Screen Resolution
    2496 x 1664
    Hard Drives
    1 TB SSD
    Internet Speed
    Wi-Fi 7 and Bluetooth 5.4
    Browser
    Chrome and Edge
    Antivirus
    Microsoft Defender
Possibly in a data recovery situation if not to late.
OK, makes sense. I keep multi-layer backups so the eventuality of that being an issue for me is probably close to zero, I never really considered that.
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
A question. If Trim clears data from the drive how does this prolong the life of the drive? When the data is cleared doesn't seem to matter since any erase operation means another write to the SSD? Are we saying data must be written to a prepared area instead of just writing at the time of hitting the enter key like disk drives? Also I would think the operation of determining whether written data is still valid would occur whether or not Trim is used. Seems like it's more a gimmick than anything.
 

My Computer

System One

  • OS
    Windows 10
    Computer type
    PC/Desktop
    Manufacturer/Model
    Leo625`s Amazing Time Killers
    CPU
    AMD RYZEN 5 2600
    Motherboard
    GIGABYTE X470 AORUS Gaming 7 WIFI
    Memory
    MEM 2Gx8|G.SKILL AEGIS
    Graphics Card(s)
    NVIDIA 750 Ti
    Sound Card
    Motherboard
    Monitor(s) Displays
    LG
    Screen Resolution
    1920 X 1080
    Hard Drives
    WD 1TB Black
    PSU
    Corsair 750
    Case
    Old
    Cooling
    3 - 120MM Fans and CoolerMaster Hyper 612 on CPU
    Keyboard
    Wired and Lighted Logitech
    Mouse
    Wireless Logitech
    Internet Speed
    Decent
    Browser
    Firefox
A question. If Trim clears data from the drive how does this prolong the life of the drive?
The SSD's internal controller writes blocks of data. If there is existing data in a block it wants to write new data to then the existing data is read, then re-written along with the new data. Deleted data that has not yet been trimmed is treated as data that needs to be kept. Trim tells the SSD controller that the deleted data can be disregarded, reducing the number of unnecessary writes and allowing wear levelling to work more effectively.
 

My Computers

System One System Two

  • OS
    Windows 11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Acer Aspire 3 A315-23-R9VY
    CPU
    AMD Athlon Silver 3050U
    Memory
    8GB
    Graphics Card(s)
    Radeon Graphics
    Monitor(s) Displays
    laptop screen
    Screen Resolution
    1366x768 native resolution, up to 2560x1440 with Radeon Virtual Super Resolution
    Hard Drives
    1TB Samsung EVO 870 SSD (from April 2026: 250GB EVO 850)
    Internet Speed
    150 Mbps
    Browser
    Edge, Firefox
    Antivirus
    Defender
    Other Info
    fully 'Windows 11 ready' laptop. Windows 10 C: partition migrated from my old unsupported 'main machine' then upgraded to 11. A test migration ran Insider builds for 2 months. When 11 was released on 5th October 2021 it was re-imaged back to 10 and was offered the upgrade in Windows Update on 20th October. Windows Update offered the 22H2 Feature Update on 20th September 2022. It got the 23H2 Feature Update on 4th November 2023 through Windows Update, 24H2 on 3rd October 2024 through Windows Update by setting the Target Release Version for 24H2, and 25H2 on 30th September 2025 through Windows Update by setting the Target Release Version for 25H2.

    UPDATE - 11 April 2026: due to mechanical deterioration this PC has been retired from active duty. The OS with all software and files has been migrated to my System Seven below to carry on as my general purpose 'main machine'.

    My SYSTEM THREE is a Dell Latitude 5410, i7-10610U, 32GB RAM, 512GB NVMe ssd, supported device running Windows 11 Pro.

    My SYSTEM FOUR is a 2-in-1 convertible Lenovo Yoga 11e 20DA, Celeron N2930, 8GB RAM, 256GB ssd. Unsupported device: currently running Win10 Pro, plus Win11 Pro RTM and Insider Dev, Beta, and RP 24H2 as native boot vhdx.

    My SYSTEM FIVE is a Dell Latitude 3190 2-in-1, Pentium Silver N5030, 8GB RAM, 1TB NVMe ssd, supported device running Windows 11 Pro, plus Insider Beta, Dev, and Canary builds (and a few others) as a native boot .vhdx.

    My SYSTEM SIX is a Dell Latitude 5550, Core Ultra 7 165H, 64GB RAM, 1TB NVMe SSD, supported device, Windows 11 Pro 24H2, Hyper-V host machine. Updated to 25H2 on 30th September 2025.

    My SYSTEM SEVEN is a Lenovo Thinkpad T580, Intel Core i7-8650U, 16GB RAM, 512GB NVMe SSD + 2nd 512GB NVMe SSD, a supported device for Windows 11. This is my current general purpose 'main machine'. The installed Windows 11 Home from my System One has been migrated to this machine.
  • Operating System
    Windows 11 Pro
    Computer type
    Laptop
    Manufacturer/Model
    Dell Latitude E4310
    CPU
    Intel® Core™ i5-520M
    Motherboard
    0T6M8G
    Memory
    8GB
    Graphics card(s)
    (integrated graphics) Intel HD Graphics
    Screen Resolution
    1366x768
    Hard Drives
    500GB Crucial MX500 SSD
    Browser
    Firefox, Edge
    Antivirus
    Defender
    Other Info
    unsupported machine: Legacy bios, MBR, TPM 1.2, upgraded from W10 to W11 using W10/W11 hybrid install media workaround. In-place upgrade to 22H2 using ISO and a workaround. Feature Update to 23H2 by manually installing the Enablement Package. In-place upgrade to 24H2 using hybrid 23H2/24H2 install media. Upgraded to 25H2 by Enablement Package. Also running Insider Dev, and Canary builds and Windows 10 as native boot .vhdx.

    My SYSTEM THREE is a Dell Latitude 5410, i7-10610U, 32GB RAM, 512GB NVMe ssd, supported device running Windows 11 Pro.

    My SYSTEM FOUR is a 2-in-1 convertible Lenovo Yoga 11e 20DA, Celeron N2930, 8GB RAM, 256GB ssd. Unsupported device: currently running Win10 Pro, plus Win11 Pro RTM and Insider Dev, Beta, and RP 24H2 as native boot vhdx.

    My SYSTEM FIVE is a Dell Latitude 3190 2-in-1, Pentium Silver N5030, 8GB RAM, 1TB NVMe ssd, supported device running Windows 11 Pro, plus Insider Beta, Dev, and Canary builds (and a few others) as a native boot .vhdx.

    My SYSTEM SIX is a Dell Latitude 5550, Core Ultra 7 165H, 64GB RAM, 1TB NVMe SSD, supported device, Windows 11 Pro 24H2, Hyper-V host machine. Updated to 25H2 on 30th September 2025.

    My SYSTEM SEVEN is a Lenovo Thinkpad T580, Intel Core i7-8650U, 16GB RAM, 512GB NVMe SSD + 2nd 512GB NVMe SSD, a supported device for Windows 11. This is my current general purpose 'main machine'. The installed Windows 11 Home from my System One has been migrated to this machine.
Thank You Bree: I misunderstood what I read. (It happens...:rolleyes: )
 

My Computer

System One

  • OS
    Windows 10
    Computer type
    PC/Desktop
    Manufacturer/Model
    Leo625`s Amazing Time Killers
    CPU
    AMD RYZEN 5 2600
    Motherboard
    GIGABYTE X470 AORUS Gaming 7 WIFI
    Memory
    MEM 2Gx8|G.SKILL AEGIS
    Graphics Card(s)
    NVIDIA 750 Ti
    Sound Card
    Motherboard
    Monitor(s) Displays
    LG
    Screen Resolution
    1920 X 1080
    Hard Drives
    WD 1TB Black
    PSU
    Corsair 750
    Case
    Old
    Cooling
    3 - 120MM Fans and CoolerMaster Hyper 612 on CPU
    Keyboard
    Wired and Lighted Logitech
    Mouse
    Wireless Logitech
    Internet Speed
    Decent
    Browser
    Firefox
A question. If Trim clears data from the drive how does this prolong the life of the drive? When the data is cleared doesn't seem to matter since any erase operation means another write to the SSD? Are we saying data must be written to a prepared area instead of just writing at the time of hitting the enter key like disk drives? Also I would think the operation of determining whether written data is still valid would occur whether or not Trim is used. Seems like it's more a gimmick than anything.
Here is a pretty good explanation of what trim factually does.
 

My Computers

System One System Two

  • OS
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Asus TUF Gaming F16 (2024)
    CPU
    i7 13650HX
    Memory
    16GB DDR5
    Graphics Card(s)
    GeForce RTX 4060 Mobile
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    512GB SSD internal
    37TB external
    PSU
    Li-ion
    Cooling
    2× Arc Flow Fans, 4× exhaust vents, 5× heatpipes
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
    Antivirus
    What's an antivirus?
  • Operating System
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Medion S15450
    CPU
    i5 1135G7
    Memory
    16GB DDR4
    Graphics card(s)
    Intel Iris Xe
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    2TB SSD internal
    37TB external
    PSU
    Li-ion
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
Sadly, the video takes 16 minutes to say what could be said in a couple of minutes! This is actually an epidemic with video creators, they all want to demonstrate their vast knowledge and as a result piddle away way too much time getting to the actual topic.
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security

My Computer

System One

  • OS
    Windows 11 Pro 25H2
    Computer type
    PC/Desktop
That's why I rarely watch YouTube videos for stuff like this. I can read and comprehend a written description of almost anything in a fraction of the time that it takes to watch and agonizingly long video saying what I could read in a flash!
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
The video description includes a list with timestamp links that allow you to quickly jump to any chapter you like to watch but most of the video is still relevant to understand what trim is for.

For example, if you don't know anything about how Garbage Collection relates to trim, then assertions like "If there is existing data in a block it wants to write new data to then the existing data is read, then re-written along with the new data" are not really among the most helpful IMHO. The reality is that most SSDs generally try to avoid re-writing existing data until Garbage Collection kicks in. Otherwise the write performance might take a hit during those times when the SSD is doing heavy writes.

The page on TouTube also has an auto-generated transcript for those who prefer to read text.
 

My Computers

System One System Two

  • OS
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Asus TUF Gaming F16 (2024)
    CPU
    i7 13650HX
    Memory
    16GB DDR5
    Graphics Card(s)
    GeForce RTX 4060 Mobile
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    512GB SSD internal
    37TB external
    PSU
    Li-ion
    Cooling
    2× Arc Flow Fans, 4× exhaust vents, 5× heatpipes
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
    Antivirus
    What's an antivirus?
  • Operating System
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Medion S15450
    CPU
    i5 1135G7
    Memory
    16GB DDR4
    Graphics card(s)
    Intel Iris Xe
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    2TB SSD internal
    37TB external
    PSU
    Li-ion
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
If Trim clears data from the drive how does this prolong the life of the drive?
Let's clear this up: Performing a TRIM operation does not prolong the life of an SSD. It is an issue of performance.

A standard HDD with spinning magnetic platters can directly overwrite data on the drive in exactly the same way as it would write to empty, unused space on the disk. In other words, there is no performance penalty for overwriting data vs writing to virgin, unused disk space.

On an SSD, if you write to a block that has had data written to it previously, the block must first be erased before it can be written to again, as Bree noted. Having to perform this extra erase cycle incurs a performance penalty. Remember that on a tradition HDD, when you delete data, it is not physically erased. The area(s) where the erased data is stored is simply marked as being free and available to be overwritten. This is why you can recover deleted files before anything overwrites those blocks.

On an SSD, when you delete a file, a TRIM operation is triggered telling the SSD controller to perform an erase operation on those blocks in the background. Now, when those blocks are used again in the future, an erase does not have to be performed because it has already been done. This boosts performance.

The drive will generally try to always write data to blocks that have already been erased first for the best performance. But sometimes the map of blocks could become outdated if something caused TRIM operations to not take place. An unexpected reboot is an example of his. So, Microsoft schedules an operation that scans the filesystem for unused areas and sends "hints" to the SSD controller to tell it "These are all the blocks that Windows sees as being unused. Check these, and if any of them have not been erased, go ahead and do that".

For those who used early SSDs before TRIM was a thing, they know about this only too well. You install a new SSD and everything is blazing fast. As you use the drive, it eventually bogs down and performance tanks drastically. This is because it is having to perform all those extra erase cycles.

Note the implication here: Data recovery is far more difficult (or impossible) on an SSD vs a HDD because TRIM actually erases data while a traditional HDD does not. Sometimes the TRIM does not happen immediately, but eventually, once it does, that data is really gone. Yet another good reason to always backup your data!

Here is a detail that may seem like I'm getting off into the weeds, but I think that this helps explain the need for TRIMjust a little bit more: Remember that the SSD has no clue what file system you are running. That is because there are so many different file systems out there like FAT32, eXxfat, NTFS, REFS, and many others used by other operating systems. The SSD has no clue about these. It only knows about raw blocks. So, when you delete a file in Windows, the underlying SSD has no clue. It only manipulates the raw blocks as the file system drivers instruct it to do. For all it knows, you could be running Bob's excellent file system which it has no understanding of. So, it is necessary for the operating system that manages that file system to tell the SSD what blocks are now unused within the file system. That is why it is the responsibility of the OS to send those TRIM commands to the SSD.

Hope this helps and isn't simply more confusing!
 

My Computers

System One System Two

  • OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
Note the implication here: Data recovery is far more difficult (or impossible) on an SSD vs a HDD because TRIM actually erases data while a traditional HDD does not. Sometimes the TRIM does not happen immediately, but eventually, once it does, that data is really gone. Yet another good reason to always backup your data!
Trim itself does not erases data, but marks the data as "invalid". After a Trim operation, data is read as a deterministic value (DRAT) or as 0s (DZAT). So, effectively, the original data can´t be read, even before the actual erase operation.
 

My Computer

System One

  • OS
    Windows 10
Note the implication here: Data recovery is far more difficult (or impossible) on an SSD vs a HDD because TRIM actually erases data while a traditional HDD does not. Sometimes the TRIM does not happen immediately, but eventually, once it does, that data is really gone. Yet another good reason to always backup your data!
True, but there is a hopeless overdependence on data recovery in any case. If you're doing proper backups of your critical data, data recovery shouldn't be a huge concern. While it would doubtless be inconvenient for one of my SSD drives to fail, it would be a long way from a catastrophe. At most, I'd lose less than a day's worth of updates.
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
At most, I'd lose less than a day's worth of updates.

Same for me. I learned long ago how important backups are when a major customer (a bank) lost millions of dollars because they had defective logic in their backups. A GOOD backup can save the day.
 

My Computers

System One System Two

  • OS
    Win11 Pro 25H2 (RTM+)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Acemagic
    CPU
    Intel i7-14650HX
    Memory
    32 GB
    Graphics Card(s)
    No GPU - Built-in Intel Graphics
    Sound Card
    Integrated
    Monitor(s) Displays
    Varies as machine will often be moved to locations with different monitors
    Screen Resolution
    Varies
    Hard Drives
    1 x 1TB Gen 4 NVMe SSD
    PSU
    120W Power Brick
    Keyboard
    Corsair K70 Max RGB Magnetic Keyboard
    Mouse
    Logitech MX Master 3
    Internet Speed
    1Gb Up / 1 Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
  • Operating System
    Win11 Pro 25H2 (RTM+)
    Computer type
    Laptop
    Manufacturer/Model
    Lenovo ThinkBook 13x Gen 2
    CPU
    Intel i7-1255U
    Memory
    16 GB
    Graphics card(s)
    Intel Iris Xe Graphics
    Sound Card
    Realtek® ALC3306-CG codec
    Monitor(s) Displays
    13.3-inch IPS Display
    Screen Resolution
    WQXGA (2560 x 1600)
    Hard Drives
    2 TB 4 x 4 NVMe SSD
    PSU
    USB-C / Thunderbolt 4 Power / Charging
    Keyboard
    Backlit, spill resistant keyboard
    Mouse
    Buttonless Glass Precision Touchpad
    Internet Speed
    1Gb Up / 1Gb Down
    Browser
    Edge
    Antivirus
    Windows Defender
    Other Info
    WiFi 6e / Bluetooth 5.1 / Facial Recognition / Fingerprint Sensor / ToF (Time of Flight) Human Presence Sensor
At most, I'd lose less than a day's worth of updates.
Same here, this is because I don't keep any personal information, Documents, Pictures etc. on my C: drive.
 

My Computer

System One

  • OS
    Windows XP (Stable, iconic) 7/8.1/10/11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Alienware PC
    CPU
    Intel i7 4790K
    Motherboard
    ASROCK Z97 EXTREME4
    Memory
    32GB DDR3 1600 MHz
    Graphics Card(s)
    ATI Radeon HD 7770 2GB GDDR5
    Sound Card
    Onboard
    Monitor(s) Displays
    SAMSUNG UE57 Series 28-Inch 4K UHD
    Hard Drives
    SAMSUNG 970 EVO PLUS M.2
    PSU
    EVGA 850 watt
    Case
    Alienware Area 51 Black Tower Case
    Keyboard
    HyperX - Alloy Elite 2 Mechanical Gaming Keyboard.
    Mouse
    Microsoft Wireless
    Internet Speed
    1.2 GHz
    Browser
    Chrome..Edge..Firefox
Same for me. I learned long ago how important backups are when a major customer (a bank) lost millions of dollars because they had defective logic in their backups. A GOOD backup can save the day.
I saw the same lesson in practice when I worked for IBM in the later 1960's! A major bank, who's name shall remain anonymous, used the IBM 2314 disks for their whole operation. They had two 9-drive cabinets, but no tape backup. They depended on spare removable 2314 disks for their backups. Of course, back in the bad old days of removable drives, one of the most frequent failures was a head crash that would also take out the disk pack. If you mounted a new pack, it would promptly destroy that one as well! Even worse was when you moved the crashed pack to a new drive, it would then wreck that drive! When I arrived they were in a panic and were swapping disks left and right to try to get back up and running. I stood in the middle of the computer room and at the top of my lungs I screamed "STOP"!!! A lot of the damage was already done, but I managed to stop them from a total meltdown! It took us several days to rebuild and rescue their data and repair all the disk drives. They had managed to destroy all their O/S boot disks, so we had to recreate that from scratch as well. I forget the final total, but I remember they had killed about 13 or 14 of the 18 drives with at least one crashed head, and even more of the disk packs. I don't know how much money that cost them, but they were off-line for three or four days before everything returned to a semblance of normal.
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
Same here, this is because I don't keep any personal information, Documents, Pictures etc. on my C: drive.
My C: drive is strictly Windows and my applications. I don't have a huge installation, my Windows drive with all the applications is 213GB, that gets automatically backed up weekly. My important data drive gets backed up daily to both an image and a file-by-file backup to two separate physical drives. It also is constantly being pushed to my cloud drive as it happens. My archives and media files also get a weekly backup, they don't change that much week over week.

All this stuff gets copied to the NAS as well.
 

My Computers

System One System Two

  • OS
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14500
    Motherboard
    Gigabyte B760M G P WIFI
    Memory
    64GB DDR4
    Graphics Card(s)
    GeForce RTX 4060
    Sound Card
    Chipset Realtek
    Monitor(s) Displays
    LG 45" Ultragear, Acer 24" 1080p
    Screen Resolution
    5120x1440, 1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 3D NAND NVMe M.2 SSD (O/S)
    Silicon Power 2TB US75 NVMe PCIe Gen4 M.2 2280 SSD (backup)
    Crucial BX500 2TB 3D NAND (2nd backup)
    Seagate 4TB Ironwolf, rotating HDD archive files
    External off-line backup Drives: 2 NVMe 4TB drives in external enclosures
    PSU
    Thermaltake Toughpower GF3 750W
    Case
    LIAN LI LANCOOL 216 E-ATX PC Case
    Cooling
    Lots of fans!
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
  • Operating System
    Win 11 Pro 25H2, Build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Brew
    CPU
    Intel Core i5 14400
    Motherboard
    Gigabyte B760M DS3H AX
    Memory
    32GB DDR5
    Graphics card(s)
    Intel 700 Embedded GPU
    Sound Card
    Realtek Embedded
    Monitor(s) Displays
    27" HP 1080p
    Screen Resolution
    1920x1080
    Hard Drives
    Crucial P310 2TB 2280 PCIe Gen4 eD NAND PCIe SSD
    Samsung EVO 990 2TB NVMe Gen4 SSD
    Samsung 2TB SATA SSD
    PSU
    Thermaltake Smart BM3 650W
    Case
    Okinos Micro ATX Case
    Cooling
    Fans
    Keyboard
    Microsoft Comfort Curve 2000
    Mouse
    Logitech G305
    Internet Speed
    Verizon FiOS 1GB
    Browser
    Firefox
    Antivirus
    Malware Bytes & Windows Defender Security
TRIM does not erase data nor tells the SSD controller to perform an erase operation on those blocks in the background.

The TRIM command triggers a cascade of state updates within the SSD’s Flash Translation Layer (FTL) metadata.
Here is precisely how TRIM handles those page-level and block-level markings:

1. At the page level: marking as stale​

When you delete a file, the Operating System sends a TRIM command containing a range of Logical Block Addresses (LBAs).​
  • The SSD controller looks up these LBAs in its mapping table.
  • It disconnects (unmaps) the physical NAND pages from those logical addresses.
  • It immediately marks those specific physical pages as stale (invalid) but the "immediately" here is not absolute (see my section about "retrim" down below).

2. At the block level: the dual outcome​

Once the pages are marked stale, the controller instantly evaluates the status of the parent block that contains them. It will mark the block in one of two ways:​
  • Scenario A: a "block with stale pages" (partially invalid)
    • Condition: The block now contains some stale pages, but still holds other pages with valid user data. It's a block that contains a mix of both valid (live) data and stale (dead) data.
    • State: It cannot be erased yet because doing so would destroy the good data inside it.
    • The problem: NAND flash can only be erased in entire blocks, not individual pages.
    • Fate: It must wait for Garbage Collection. The controller will eventually copy the few valid pages to a new location, turning this into a fully stale block.
    • Result: The controller flags this block internally as a candidate for future Garbage Collection. It notes the ratio of valid-to-stale pages so it can prioritize it later when free space runs low.
  • Scenario B: a "stale block"(fully invalid)
    • Condition: The TRIM command successfully invalidated the very last remaining valid page in that block, or the block was already filled with stale pages. It's a block where 100% of the pages are marked as stale or invalid.
    • State: It contains absolutely zero useful data.
    • The benefit: This is the ideal target for the SSD controller.
    • Fate: It can be erased immediately without moving any data first. This makes the recycling process incredibly fast and efficient.
    • Result: The controller flags the entire block as fully stale. Because it contains 0% valid data, the controller can bypass Garbage Collection entirely and move this block straight to the Erase Queue to be wiped during background maintenance.
If your SSD has to clear blocks with mixed pages, it must read the good data, write it elsewhere, and then erase the block. This extra work causes Write Amplification, which slows down your drive and wears out the flash faster. If the SSD can find fully stale blocks, it skips the moving step entirely, instantly boosting performance.

TRIM command received ➔ pages marked stale ➔ controller checks parent block ➔ flags the block as "Mixed" OR "Fully Stale".

Modern SSDs intentionally delay Garbage Collection (GC) until free blocks run low to protect the drive's lifespan and maintain peak performance.
This strategy is divided into two distinct modes: Idle GC and Reactive GC.

1. Idle Garbage Collection (background)​

When the SSD is sitting idle, it will occasionally clean up blocks, but it does so very conservatively.​
  • The goal: Prepare just enough free blocks for the next burst of write activity.
  • Why it waits: If the controller aggressively moves valid data too early, and the host operating system deletes that same data a few minutes later, the SSD just wasted write cycles. Waiting gives data a chance to "die" naturally. Another reason why it waits is to improve Wear Leveling (more on that soon).

2. Reactive Garbage Collection (foreground)​

This triggers only when the pool of free blocks drops below a critical threshold.​
  • The goal: Emergency space creation.
  • The action: The controller aggressively targets blocks with stale pages, forces the movement of valid data to a new block, and erases the old block.
  • The penalty: Because this happens while you are actively using the drive, it causes a noticeable drop in write speeds (often called the "GC cliff").

The strategy: why modern SSDs wait​

SSD controllers use a metric called Greedy Garbage Collection or Cost-Age-Based policies to decide exactly when to move data. They delay the process for three major reasons:
  • Minimizing Write Amplification: Moving valid data writes new data to the NAND. Doing this too often wears out the drive prematurely.
  • Data Consolidation: By waiting, more pages within a block are likely to become stale. It is much more efficient to clear a block that is 95% stale than one that is only 20% stale.
  • Host latency priority: Moving data takes processing power and bandwidth. Modern SSDs prioritize user read/write requests over background cleaning until they absolutely have no choice.
The intentional delay in Garbage Collection acts as a data stabilization window. It serves as a natural filter that provides the wear-leveling mechanism with richer, high-fidelity metadata over time. This synergy directly translates to improved lifespan and efficiency through several mechanisms:

1. Accurate Identification of "Hot" vs. "Cold" Data​
  • The concept: Data that changes frequently is "hot" (e.g., system logs, cache), while data that rarely changes is "cold" (e.g., operating system files, stored photos).
  • How the delay helps: If the SSD triggers GC too quickly, it cannot tell the difference between hot and cold data because both look identical when newly written. By delaying GC, the FTL can observe data behaviors over a longer period. Hot data will be repeatedly overwritten and invalidate itself naturally, while cold data remains untouched.
  • The Wear Leveling benefit: Wear leveling relies entirely on this distinction. It intentionally targets cold data to migrate into highly worn blocks (Static Wear Leveling). If it moves data prematurely, it might accidentally put high-turnover hot data into a worn-out block, destroying the block much faster.
2. Reducing Metadata "Churn"​
  • The concept: Tracking the precise Erase Counts (P/E cycles) and tracking which specific blocks are aging requires the FTL to maintain internal tracking tables (metadata).
  • How the delay helps: If GC and wear leveling were running aggressively in the background constantly, the SSD controller would spend a massive amount of its limited processing power and RAM constantly updating these tracking tables.
  • The Wear Leveling benefit: Waiting allows the controller to perform a comprehensive, holistic calculation of the drive's health status at longer intervals. This eliminates metadata "churn"—saving precious internal controller bandwidth and avoiding writing unnecessary metadata back to the NAND itself.
3. Preventing Adaptive Over-Correction (Oscillation)​
  • The concept: Dynamic wear leveling algorithms use real-time mathematical thresholds to decide where to route the next incoming write.
  • How the delay helps: In a short timeframe, an SSD might experience an unusual burst of heavy writing to one sector, making those blocks look abnormally worn out. If the controller reacted instantly, it would over-correct by shifting operations across the drive needlessly.
  • The Wear Leveling benefit: Deferring these deep cleanups gives the workload time to average out. The wear leveling algorithm gains a statistically accurate profile of the drive's global wear state, leading to precise, highly effective block choices rather than knee-jerk adjustments.

The bottom line: co-dependency​

Garbage Collection and Wear Leveling are often engineered as parts of the same loop. By letting blocks sit idle longer, the SSD successfully separates data by its "lifespan," which gives the wear-leveling engine the exact blueprint it needs to distribute physical stress flawlessly across the NAND array.

Without reverse-engineering the SSD, there is no way to tell if or when physical blocks will be erased in the NAND after you delete a file. Unless you're using enterprise SSDs with the NVMe Zoned Namespaces (ZNS) command set or the NVMe Key Value (KV) command set, without permanent data sanitization of the whole SSD, you cannot ensure that the deleted file's data content will be made irrecoverable within the NAND.​

Retrim​

To clarify on "TRIM immediately marks those specific physical pages as stale", the immediate part happens only if the OS uses Inline TRIM (Continuous TRIM). However, most modern operating systems rely heavily on Periodic Re-TRIM (Scheduled TRIM) instead.
Here is exactly how these two different OS approaches change when those pages actually get marked as stale:

1. Periodic Re-TRIM (delayed marking)​

Most modern OS environments (like Windows "Optimize Drives" or Linux fstrim) default to this method to preserve system performance.​
  • How it works: When you delete a file, the OS deletes it from its own file system but does not immediately tell the SSD. It keeps a log of those deleted addresses.
  • The "Re-TRIM" event: Once a week (or during low activity), the OS runs a batch job and sends a massive list of TRIM commands to the drive all at once.
  • The SSD state change: The SSD pages are not marked as stale at the moment of deletion. They remain marked as "valid" inside the SSD until that periodic Re-TRIM command finally arrives.
2. Inline TRIM (continuous: immediate marking)​

Some systems (like macOS or certain Linux configurations using the discard mount option) choose to send the command immediately.​
  • How it works: The exact millisecond you empty the trash, the OS pauses briefly to send the TRIM command down the SATA/NVMe bus.
  • The SSD state change: In this specific mode, the SSD does immediately mark those pages as stale.
  • The downside: This causes high "queue depth" overhead and can introduce micro-stutters during heavy file deletions, which is why operating systems moved toward the periodic method.
The SSD's secret catch: Command Queueing

Even when the OS sends a TRIM command (whether inline or periodic), the SSD controller itself might not process it instantly.​
TRIM is an asynchronous, non-blocking command in modern NVMe drives. The controller places the TRIM request into a low-priority internal queue. If you are in the middle of a heavy gaming session or exporting a video, the SSD controller will intentionally delay processing the TRIM command—leaving the pages marked as "valid"—until the drive goes idle.​
No TRIM commands are discarded from the SSD controller’s internal queue.
Once a TRIM command is sent by the operating system and accepted into the SSD's command queue, it is guaranteed to be processed, as discarding a valid command would cause data corruption. What sometimes creates confusion around this topic—and why the operating system still performs a periodic "Re-TRIM"—comes down to three specific architectural reasons:

1. The OS "Re-TRIM" is a safety net, not a resend of lost commands
When Windows or Linux runs a scheduled weekly Re-TRIM (via Defrag or fstrim), it isn't resending commands that the SSD threw away. Instead, it is doing two things:​
  • Catching missed blocks: During heavy system use, the OS file system driver might occasionally skip sending an inline TRIM command to avoid clogging the storage bus. The periodic sweep acts as a "catch-all" to find any deleted blocks it missed.
  • Cleaning up metapages: File systems constantly reuse metadata blocks. A periodic sweep ensures that space freed up by internal OS file system management is fully synchronized with the SSD.
2. Queue boundaries (hardware overflows)
While the SSD won't discard a command it has accepted, its internal queue does have a fixed physical size.​
  • If an OS floods a drive with too many inline TRIM commands at once, the SSD's command queue can fill up completely.
  • When the queue is full, the SSD doesn't discard commands; it handles it via flow control—it simply stops accepting new commands and forces the OS to wait (block) until the queue clears. This is why the OS batch-processes TRIM during idle times to avoid freezing the system.
3. FTL Processing Order vs. Deletion Order
When the SSD controller processes the TRIM queue, it doesn't necessarily execute them in the exact order they arrived. The Flash Translation Layer (FTL) will often sort and merge TRIM commands to match the physical layout of the NAND flash.​
A command might sit in the queue for a relatively long time while the SSD prioritizes user read/write traffic, but it remains safely in memory until the controller completes the unmapping process.​
 

My Computers

System One System Two

  • OS
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Asus TUF Gaming F16 (2024)
    CPU
    i7 13650HX
    Memory
    16GB DDR5
    Graphics Card(s)
    GeForce RTX 4060 Mobile
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    512GB SSD internal
    37TB external
    PSU
    Li-ion
    Cooling
    2× Arc Flow Fans, 4× exhaust vents, 5× heatpipes
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
    Antivirus
    What's an antivirus?
  • Operating System
    11 Home
    Computer type
    Laptop
    Manufacturer/Model
    Medion S15450
    CPU
    i5 1135G7
    Memory
    16GB DDR4
    Graphics card(s)
    Intel Iris Xe
    Sound Card
    Eastern Electric MiniMax DAC Supreme; Emotiva UMC-200; Astell & Kern AK240
    Monitor(s) Displays
    Sony Bravia XR-55X90J
    Screen Resolution
    3840×2160
    Hard Drives
    2TB SSD internal
    37TB external
    PSU
    Li-ion
    Keyboard
    Logitech K800
    Mouse
    Logitech G402
    Internet Speed
    30Mbit/s up, 500Mbit/s down
    Browser
    FF
Back
Top Bottom