Is it possible to recover data from TRIM enabled SSD?

Ah, yes. TRIM. It sounds like it could be something simple and easy to deal with. You know, innocent with a touch of sophistication, right? Well, that could be true on both points.

But what does TRIM stand for?

Let’s begin by looking at what TRIM stands for. Okay, I have to be frank with you here. TRIM actually has no meaning. That is to say, the letters T-R-I-M are not an acronym nor do they act as an abbreviation for anything. In fact, you probably shouldn’t even be spelling it with all-caps but since it has been referred in this way for so long, it is TRIM. Oh, and there isn’t a very good reason why the reference to this has been TRIM or trim.

So… what is this mystical TRIM?

In laymen’s terms, it is a performance optimization tool that is either present or not (enabled or disabled) on all modern, and some not-quite-so-modern SSD drives. Let’s just go ahead and say that all of the known SSD brands such as Sandisk, Kingston, etc. have TRIM installed.

SSD Manufacturers

Alright. We’ve gotten this far and you understand what I’ve said to this point, right? Okay. So now what kind of performance optimization am I talking about here?

Well, essentially, drives with enabled TRIM commands will show better performance writing and reading.

How does that work and what does it do? Well, it sort of works like a garbage cleaner tool like Roomba or Gufy… one of those robot cleaners that vacuum your carpets. You leave behind some dirt and when the robot sees it, it cleans it up and returns to where it was stored.

The SSD with TRIM sort of operates like that. You detect some files from the SSD with TRIM enabled command and it will wipe the place where the file was completely, which means it will write 0s in that specific block. That means the controller will see that files have been erased and will go to that very same block (or blocks) and clean up where those files were once located.

But keep this in mind: There have been some instances where TRIM shows signs of an anomaly. The anomaly here is if the file gets deleted TRIM doesn’t delete the whole file, but decides to leave behind the shell of that file and writes 0s inside of it. That means you may end up seeing that file, complete with a name and file size that may appear correct but if you check that file with HEX editor, you’ll discover the shell of the file stuffed with 0s.

What this means if you are hoping to recover data from TRIM enabled hard drives, the bad news is that it can’t be done.

However, TRIM works in tandem with the controller which means the controller tells it when and what to do. There have been examples where the controller decides to wait and not send commands to TRIM. That is a lucky break for those seeking data recovery. Do you see where I’m going with this?

SSD controller

Image Source: https://www.storagereview.com/node/3221

TRIM is a good tool if you are concerned about the performance of your SSD and are not too concerned about the data on that drive. But if the data is what you value most, my suggestion is to disable TRIM right now.

How exactly do you go about disabling TRIM? This Check TRIM support will tell you how and where to enable/disable it.

For data recovery in general, TRIM spells bad news. You can contact most any data recovery service and suggest that your SSD was accidentally formatted or erased. The first question you will be asked will be a variation on this one: “Was TRIM enabled?” Or you may be asked to check the drive to see if it has TRIM currently enabled. Once you confirm those questions, about 99% of those data recovery sites will refuse to help you because your data will be 98% unrecoverable. The 2% chance that it may be recoverable comes from when the controller and TRIM malfunctions and doesn’t do what it is supposed to do.