re-enable ZFS trim by default
I have tested a variety of SSDs with the fix from commit:
d0562c105d 11754 ZoL trim port used wrong offset for sd unmap
and everything seems to be working correctly. At this point I think it is safe to re-enable trim support.
Updated by Jerry Jelinek almost 2 years ago
I have tested the following different SSDs
ATA INTEL SSDSC2BX01 1490.42 GiB HGST HUSMH8010BSS204 93.16 GiB HGST HUSMR1619ASS204 1788.50 GiB HGST HUSMR3240ASS204 372.61 GiB SAMSUNG MZILS3T8HCJM/003 3576.98 GiB TOSHIBA PX04SRB192 1788.50 GiB WDC WUSTR6440ASS204 372.61 GiB
For testing, I created a zpool, or used the existing zpool, on the device, wrote a bunch of files into the dataset, then deleted most of those. I ran a trim and verified that 'zpool status' showed the device was trimming for some period of time. After the trim was complete, I scrubbed the zpool to verify there were no errors, and then exported/imported the zpool to confirm there were no problems. For the system's main pool (rpool or zones), I could not export the live pool so I rebooted to confirm things were ok.
There is no way we can test every SSD out there, but our code is consistent with the upstream philosophy from OpenZFS. They do not have a blacklist either, and recommend that people simply buy good quality SSDs if they want to use trim.
Updated by Electric Monk almost 2 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit fc5c75cf5edb072564020725faa0c4313714f09f Author: Jerry Jelinek <firstname.lastname@example.org> Date: 2019-12-18T18:02:41.000Z 12051 re-enable ZFS trim by default Reviewed by: Andrew Stormont <email@example.com> Approved by: Robert Mustacchi <firstname.lastname@example.org>