How to keep an SSD in shape on Yosemite?

As of OS X 10.10, Apple uses kext signing. Ever since it has become difficult and dangerous to manually activate TRIM for third-party SSDs on OS X. That means users with non-Apple SSDs will sooner or later see degrading write speeds.

So I am wondering what are my options to avoid this situation. Some approaches I could think of imply additional problems:

  • Are you aware of any alternative approach, that does not require disabling kext signing?
  • Are there tools or tricks to manually clean up a SSD (i.e. issue a TRIM command)?
  • If I decided to temporarily use a tool like TRIM Enabler how long would it need to be activated, in order to clean the disk?

To summarize: No TRIM on Yosemite. What can I do?


Solution 1:

EDIT 3:

Yes! Since the release of 10.10.4, Apple now provides a new tool called trimforce, allowing users to activate TRIM also on unsupported disks. So now the ultimate and final answer is:

sudo trimforce enable

/EDIT 3

EDIT 1:

Finally I found a way! Apparently there is a neat trick hidden in the fsck tool as this answer says.

So in the future I will boot into Single User Mode (press +S at boot screen) from time to time and issue the command fsck -fy. It will check the disk and finish with the message Trimming unused blocks.

/EDIT 1

EDIT 2:

So there is a new tool called Disk Sensei that specializes on exactly that problem. It has a manual TRIM command and helps you turning Yosemite's kext signing on and off.

/EDIT 2:

Furthermore, I read about DiskFresh which would somewhat accomplish what I was originally asking for. This Windows (Bootcamp partition required) tool will rewrite all data of partitions or an entire disk. This approach seems a little less painful than wiping my SSD and restoring it from a backup. However, it also comes with the downside of doing an additional write cycle.