I have a Windows 2012 server configured with two SSD under a Software RAID 1 (controlled by Windows), under that configuration the optimization tool is not supported.
Is the TRIM still scheduled/performed by the OS, just not visibly so, and with no manual controls?
Is there a way to force it, given it's a simple mirroring RAID, and the OS is capable of TRIM when the SSD are not RAID'ed?
I found an "option" early on, but it's obviously not suitable for use in production: detach one disk from the raid (thus killing the RAID), perform the TRIM on the single-disk, then rebuild the RAID.
(the SSDs are 120GB Intel Sandforce in case that matters, they host several databases, are under constant read/write 24/7, and there is a data rotation of several gigabytes per day)
Windows software RAID only supports Trim/Unmap pass-through for RAID-0 at this time.
However, Sandforce (and most other SSD chips) will pickup that a block is being zeroed and mark the block for garbage collection instead (what Trim would do). You can force Windows to zero unused disk space with the
cypher /w X:\
command. This does not work on encrypted drives.See Is TRIM possible on SSD disks in RAID 1?
What you are asking for does not make sense. TRIM is an ongoing process not a once off pruning and it can't work in conjunction with RAID.
But the drives will still do their own background garbage collection so it is something you simply do not need to worry about.
The entire path the data takes from the OS to the SSD needs to support the pass trough of TRIM commands.
Generally the issue is that the hardware RAID controller does not pass trough the TRIM commands.
Software RAID should be able to pass trough the TRIM commands as long as you use a normal controller (LSI HBA SAS controller or something).
The arguement that overprovisioning reduces the advantage of TRIM is somewhat faulty since overprovisioning just means the SSD has more space to use than you realize and you can fill this space up just as easily which will result in the same lower performance but it takes a little longer to get to that point. Normal disks have around 7% overprovisioning, Enterprise disks have 25%+ overprovisioning but in the end you fill them up and you'd be in the same place.
We have this issue with one of our systems at the moment and we will probably switch from using a LSI RAID controller to an LSI HBA SAS controller to make sure the TRIM commands get passed on. Another solution is getting a JBOD but that's a little more expensive than changing controllers. We have Enterprise disks in RAID 1 that are less than a year old but even with the overprovisioning and garbage collection the performance has dropped significantly.