15

I'm about to purchase an external SSD enclosure (case) for my Samsung 860 QVO. Some case manufacturers mention "supports TRIM" in the description, some don't. Reading online, I only could find evidence that TRIM support is dependent on the drive that receives it and the OS that sends it. Could an enclosure with a cheap controller prevent the OS from performing TRIM on my drive?

2 Answers 2

19

Yes, in theory it could.

The drive speaks ATA, while all USB storage devices speak SCSI – the enclosure's controller has to translate between the two command sets (and usually provide a special "ATA passthrough" command for things that don't translate well). It could certainly be that the enclosure does not know how to translate the SCSI 'UNMAP' command to the equivalent ATA 'TRIM' command and doesn't report the capability to the OS.

(I seem to also remember something vague about this command only being allowed in UAS mode, not in the basic BOT mode, but I'm not sure how true that is.)

6
  • 1
    With some digging, I found the chip model: ASM225CM. This one supports UASP, but I'm guessing it doesn't automatically mean that it would translate the UNMAP command.
    – J13C
    Commented Jan 12 at 10:21
  • 6
    Not just in theory, a significant majority of SAT bridge chipsets I’ve seen used in these devices do not properly handle TRIM, and they often don’t handle other parts of the ATA command set either, such as NCQ, SCT ERC, AAM, or management of the HPA and/or DCO. Commented Jan 12 at 18:52
  • 5
    Many USB-to-ATA bridges also don't fully support the SMART command set, making it a headache to check the health status of HDDs. Commented Jan 13 at 1:19
  • 1
    @比尔盖子: Haven't seen any that wouldn't support it; ATA SMART usually goes through the generic "ATA PASS-THROUGH" command instead of needing its own translation, as it's a bit different from SCSI SMART anyway. (Although I do have an older external HDD that uses a proprietary Maxtor pass-through command instead of the standard one – it probably predates the standard command that I think was only specified in 2007 – but Linux 'smartctl' knows how to deal with it too.) Commented Jan 13 at 8:34
  • 1
    @u1686_grawity I have seen ones that don’t support it, or at least that don’t support it properly. Many cheap SAT adapters simply present as ‘plain’ USB MSC devices without any support for the required commands, or they explicitly block certain commands in the name of ‘safety’. It’s been quite some time since I saw one that actually provided full SMART support. Commented Jan 13 at 23:57
7

Yes, in practice it does.

It is rather hard to find an USB-SATA cable or adapter or enclosure that is capable of translating the TRIM command.

A colleague of mine was tasked to find a TRIM-capable cable (not enclosure) and they ended up buying about 6 or 7 different ones and testing them.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .