keepcalculator

06 Numbers and Powers

NVMe Deleted E Partition Extended C Trim Data?

Card No. 06·73599 · Updated · Standard formula, shown below

If you deleted the E: partition on an NVMe drive and then extended the C: partition into the freed space, the old E: partition’s data is not immediately erased by the trim command, but it becomes unrecoverable in practice. The trim command tells the SSD which logical blocks are no longer in use, allowing the drive to erase them in the background, but the actual erasure happens later and may not cover every sector immediately.

What Trim Does on an NVMe Drive

Trim is an ATA command (called Deallocate in NVMe) that the operating system sends to the SSD after files are deleted or a partition is removed. It informs the drive which logical block addresses (LBAs) contain data that is no longer needed. The SSD then marks those blocks as invalid and can erase them during garbage collection, which improves write performance and prolongs the drive’s lifespan. However, trim does not guarantee immediate physical erasure. The drive may delay erasing the blocks until it needs to write new data to them, and some drives may not erase all deallocated blocks right away.

What Happens When You Delete a Partition and Extend C:

When you delete the E: partition in Disk Management, the partition table entry is removed, and the space is marked as unallocated. The data in that space is still physically present on the NAND flash, but the file system no longer references it. When you then extend the C: partition into that unallocated space, the file system (NTFS) sees the space as empty and may write new data over it. The trim command may or may not have been sent for the deleted partition, depending on how the deletion was performed. If you used Disk Management, Windows typically sends trim for the entire volume when it is deleted, but if you used a third-party tool that does not issue trim, the data may remain in the NAND until overwritten.

Can You Recover Data from the Deleted Partition?

If you deleted the E: partition and have not yet extended C: or written new data to that area, recovery is possible with data recovery software that scans for lost partitions. However, once you extend C: and the file system starts writing new files, the old data gets overwritten. Even if trim has not physically erased the blocks, the logical addresses are now part of C: and will be reused. Recovery becomes increasingly difficult and often impossible after the first write to that region. If you have already extended C: and used the drive normally, the chance of recovering the old E: data is very low.

Does Trim Affect Data Recovery?

Yes, trim makes data recovery harder on SSDs compared to hard drives. On an HDD, deleted files remain until overwritten, so recovery software can often find them. On an NVMe SSD with trim enabled, the drive may erase the blocks soon after deletion, making recovery impossible. The key factor is whether trim was issued for the deleted partition. If you deleted E: through Windows Disk Management, trim is typically sent for the entire volume, so the SSD knows those blocks are free. If you then extended C:, the file system will treat that space as empty, and the SSD may have already erased the blocks or will do so during the next garbage collection cycle.

How to Check if Trim Is Enabled on Your NVMe Drive

To see if trim is active on your Windows system, open a Command Prompt as administrator and type:

fsutil behavior query DisableDeleteNotify

If the result is 0, trim is enabled. If it is 1, trim is disabled. On modern Windows 10 and 11 systems, trim is enabled by default for NVMe drives. You can also check the drive’s health and trim status using the manufacturer’s SSD management software or third-party tools like CrystalDiskInfo, which shows a “TRIM” status. If trim is disabled, the SSD will not erase deallocated blocks until overwritten, which could theoretically make recovery possible longer, but it also degrades performance over time.

Common Misconceptions About Trim and Data Deletion

A common misconception is that trim immediately erases data, making it permanently unrecoverable. In reality, trim only marks blocks as invalid; the physical erasure happens later, often only when the drive needs to write new data. Another misconception is that deleting a partition and extending another will “wipe” the old data instantly. That is not true; the data remains until overwritten or erased by the SSD’s garbage collection. Some users also believe that trim works on all SSDs, but older SATA SSDs may not support trim, and some external USB drives may not pass the trim command through. For NVMe drives, trim is well-supported, but the actual behavior depends on the drive’s firmware and the operating system.

Frequently Asked Questions

Can I recover files from a deleted partition on an NVMe drive after extending C:?

In most cases, no. Once you extend C: and write new data to that space, the old files are overwritten. Even if trim hasn’t physically erased the blocks, the file system will reuse the logical addresses. Recovery software might find remnants if the drive has not been used much, but the success rate is low. If you haven’t extended C: yet, stop using the drive and use a partition recovery tool immediately.

Does the trim command permanently delete data?

Trim does not immediately erase data; it tells the SSD that the blocks are free to be erased. The SSD may erase them during garbage collection, which can happen later. So, trim does not guarantee immediate permanent deletion, but it makes recovery impossible once the blocks are erased. The timing depends on the drive’s firmware and workload.

Is it safe to extend C: after deleting a partition?

Yes, it is safe in terms of system stability, but you will lose the ability to recover the deleted partition’s data. Extending C: is a normal operation and does not harm the drive or the C: partition. Just be aware that any data in the deleted partition will be overwritten as you use the drive.

How can I prevent data loss when deleting a partition on an NVMe drive?

Before deleting any partition, back up the data to another drive. If you accidentally delete a partition, stop using the drive immediately and use a recovery tool that supports SSDs. Do not extend other partitions or write new data until you have attempted recovery. Also, consider using a disk imaging tool to create a backup of the entire drive before making partition changes.

Does Windows send trim when I delete a partition?

Yes, Windows typically sends trim for the entire volume when a partition is deleted via Disk Management or Diskpart. This informs the SSD that all blocks in that partition are free. However, if you use a third-party partition manager that does not issue trim, the blocks may not be marked as free, which could allow recovery longer but also leaves the SSD unaware of the free space.

Can I disable trim to improve data recovery chances?

You can disable trim by running fsutil behavior set DisableDeleteNotify 1 in an elevated command prompt. This prevents the OS from sending trim commands, so deleted data remains until overwritten. However, this will degrade the drive’s performance over time and is not recommended for normal use. If you need to recover data, it is better to stop using the drive and use recovery software before the data is overwritten.

Related

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.

More cards in this drawer

The whole Numbers and Powers drawer →