Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

jaxrox1

macrumors newbie
Original poster
Oct 19, 2008
13
0
So I've been looking around trying to find a relatively simple answer to this question, and the more I look the more complex things seem to become.

I'm looking into using a PCIe adapter with a 128GB M.2 SSD AHCI as a boot drive, then striping together two 512GB SSDs in the internal bays as a RAID 0.

Can I use TRIM on either/both of the boot drive and/or the internally RAIDed SSDs?
 
Yes, for the M.2.

I don't think it will work for the RAID.
So am I better off not RAID-ing them - the purpose of the RAID is to increase performance, but if TRIM's not going to work, then it seems self-defeating?
 
Not sure about RAID, my understanding is no, but I didn't try that myself.

For 2 seperate Internal PCIe SSD, TRIM is supported (need to run at least a terminal command in OSX, depends on the version of OSX, you may need TRIM Enabler).

If your purpose is to increase read performance, then RAID them together should not be a problem. However, if you need the write performance, then, IMO, use SSD without TRIM is not a good idea.

To compensate that, you need to make a large over provision by yourself, which let GC can work better even without help from TRIM. But the downside is that not all free space are effectively over provision, and those dedicated space can't be use by the OS. So, in simple words, not recommended.
 
To compensate that, you need to make a large over provision by yourself, which let GC can work better even without help from TRIM. But the downside is that not all free space are effectively over provision, and those dedicated space can't be use by the OS. So, in simple words, not recommended.
To elaborate, when you "over provision", you leave unused space on the disk. This increases the chance that the garbage collector can find chunks that are free, and it can erase them without having to do an extra write. (There is a nice description of the process at https://en.wikipedia.org/wiki/Write_amplification )

Note however, to overprovision you need to start by doing a "secure erase", which effectively TRIMs the entire device. After erasing, partition the drive but create partitions smaller than the full size. 10% to 20% free is a good size unless you have an intense write load.

Never use that 10% to 20% space. If you do, it will be in use - even if you delete the partition you put there. Free space in the file system is not the same - once a block on the disk is touched, it is forever in use - even if the file is deleted. (Unless you have TRIM, of course. If a TRIM command is issued when the file is deleted, then those blocks effectively join the over provisioned pool.)

It you look at expensive enterprise SSDs, you'll see odd sizes like a 480GB drive. That will be a drive with 512GiB of flash, but about 15% of it is over provisioned (549.8GB - 480GB = 69.8GB). A consumer 512GB drive is about 7.8% over provisioned (549.8GB - 512GB = 37.8GB).
 
Last edited:
  • Like
Reactions: h9826790
So I've been looking around trying to find a relatively simple answer to this question, and the more I look the more complex things seem to become.

I'm looking into using a PCIe adapter with a 128GB M.2 SSD AHCI as a boot drive, then striping together two 512GB SSDs in the internal bays as a RAID 0.

Can I use TRIM on either/both of the boot drive and/or the internally RAIDed SSDs?

What are you using as your RAID solution? I use SoftRAID in my system, which allows TRIM on RAID sets.

I have four SM951's on an x16 PCIe Amfeltec card. One is running as a boot drive and the other 3 as a RAID 0. Both volumes have TRIM enabled and I've had 0 issues.

The TRIM will run on the internal SATA as well if using this software.
 
What are you using as your RAID solution? I use SoftRAID in my system, which allows TRIM on RAID sets.

I have four SM951's on an x16 PCIe Amfeltec card. One is running as a boot drive and the other 3 as a RAID 0. Both volumes have TRIM enabled and I've had 0 issues.

The TRIM will run on the internal SATA as well if using this software.

I was planning on using OSX - either via Terminal, or Internet Recovery Disk Utility (which supposedly still allows RAID)

If I use trimforce in OSX before RAIDing and/or after RAIDing, will this not work?

It you look at expensive enterprise SSDs, you'll see odd sizes like a 480GB drive. That will be a drive with 512GiB of flash, but about 15% of it is over provisioned (549.8GB - 480GB = 69.8GB). A consumer 512GB drive is about 7.8% over provisioned (549.8GB - 512GB = 37.8GB).

As a coincidence, I was looking into 480GB SSDs..

Is over-provisioning stated on the specs of a drive? If I buy an over provisioned SSD, will that suffice, or should I also over-provision with my own partition as well?
 
As a coincidence, I was looking into 480GB SSDs..

Is over-provisioning stated on the specs of a drive? If I buy an over provisioned SSD, will that suffice, or should I also over-provision with my own partition as well?
Not all drives explicitly state the amount, but most of them will have a "lifetime writes" spec. More over-provisioning gives more writes. For example, the Intel 535 480 GB SSD says "The SSD will have a minimum of five years of useful life under client workloads with up to 40 GB of host writes per day". In other words, 73 TB of lifetime writes.

Over-provisioning usually means non-partitioned space, although an used partition should be OK as long as it is unformatted or "quick formatted".

If the software allows, you could also create the RAID-0 volume the full size of the disks, and then at the OS level leave some of the volume unpartitioned. This would give you the option of expanding into the over-provisioned space if you want to.

I would be comfortable with the 480GB without user over-provisioning unless it's important to you to write very large files quickly. SSDs maintain a pool of erased blocks for quick writing - but when that pool is exhausted you have to wait for the garbage collector to erase blocks in real time. Write speeds can drop into the tens of MB/sec when that happens.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.