How do I know that TRIM is working?

996GT2

Diamond Member
Jun 23, 2005
5,212
0
76
Now that I've flashed my Kingston SSD to the Intel firmware that supports TRIM, how do I know that Windows 7 is using actually using TRIM to clean up the drive? Does TRIM automatically run when I am not logged in to Windows? Does it give any messages that it's actually working?

Also, since I ran my drive without TRIM for a few months, how long would it take for the drive with its new firmware to go back to its original performance (or something close to its original performance)?

When I first got the drive, I remember the Windows Experience Index was a 7.3 in the hard disk section. Now it's something like a 5.9, which is kind of slow for an SSD. I am on a laptop and I don't expect to get the same numbers as a desktop chipset, but shouldn't the drive at least go back to something close to its original performance now that the firmware supports TRIM?
 
Last edited:

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
TRIM isn't something that runs, it's just a command used to tell the drive that certain blocks are free so the firmware can do whatever internal stuff it wants to clean, wear-level, etc them. So as long as the firmware and OS support TRIM it's being used.
 

Engineer

Elite Member
Oct 9, 1999
39,230
701
126
TRIM isn't something that runs, it's just a command used to tell the drive that certain blocks are free so the firmware can do whatever internal stuff it wants to clean, wear-level, etc them. So as long as the firmware and OS support TRIM it's being used.

But you can check on the status of TRIM at the OS level (Win 7) and also enable or disable it via command line:

TRIM Commands

Go to the Command Prompt and type:

fsutil behavior query disabledeletenotify


DisableDeleteNotify = 1 (Windows TRIM commands are disabled)
DisableDeleteNotify = 0 (Windows TRIM commands are enabled)


To enable TRIM (if it's disabled), go to command prompt and type:

fsutil behavior set disabledeletenotify 0


To disable TRIM, to go command prompt and type:

fsutil behavior set disabledeletenotify 1
 

jjmIII

Diamond Member
Mar 13, 2001
8,399
1
81
My understanding is, if its NOT grayed out, it is running and working.
 

AyashiKaibutsu

Diamond Member
Jan 24, 2004
9,306
4
81
Lol, thought I was in the programming forum was going to say something about not having spaces at the start or end of your string.
 

railman

Member
Dec 22, 2009
82
0
0
TRIM, if enabled and OS supported, will only run when invoked. This can be done a few ways. My favorite is to use Windows disk cleanup that will send delete commands for files that are no longer needed. The deletion of files is one way to invoke TRIM. You can also invoke TRIM by empting the recycle bin.

Additionally, TRIM is immediate, it tells the SSD drive controller to reset NAND cells containing invalid files to a free state.
 

c0balt

Junior Member
Nov 4, 2009
21
0
0
I just spent 20 minutes trying to verify TRIM is operable using the procmon procedure listed in posts 2&3 here:
http://www.ocztechnologyforum.com/forum/showthread.php?66696-New-FW-Flashing

TRIM is not working for me, or at least I'm not seeing the calls in the procmon trace. (which may mean I just need to play with procmon more.) Can anyone else verify that it's working for them using this method?

CrystalDiskInfo is not an option for me as it doesn't recognize my drive.
 
Last edited:

railman

Member
Dec 22, 2009
82
0
0
I just spent 20 minutes trying to verify TRIM is operable using the procmon procedure listed in posts 2&3 here:
http://www.ocztechnologyforum.com/forum/showthread.php?66696-New-FW-Flashing

TRIM is not working for me, or at least I'm not seeing the calls in the procmon trace. (which may mean I just need to play with procmon more.) Can anyone else verify that it's working for them using this method?

CrystalDiskInfo is not an option for me as it doesn't recognize my drive.

Are you saying you are not seeing the capitalized, underlined, process strings that me&er has in his post?
 

c0balt

Junior Member
Nov 4, 2009
21
0
0
Are you saying you are not seeing the capitalized, underlined, process strings that me&er has in his post?

Correct. Possibly because my controller is set to RAID even though I only have 1 SSD (I forgot to switch from RAID to AHCI when I installed.)

Here's the minute of traces following an emptying of the Recycle Bin (which contains 1 jpg file.) It's in two screenshots, note timestamp overlap.

776433933_LwGp4-L.jpg


776433914_aLQgx-L.jpg


Here are the filters I'm using:
776424223_WyMcZ-M.jpg


App in Explorer calls delete file:

Explorer Process –
IRP_MJ_CREATE operation reads attributes and opens up the read/write/delete mode along the Storage Stack.

File System metadata is updated and written to Vertex:

Explorer Process –
Then follows a series of IRP_MJ code requests that query, cleanup and close the volumes etc on Vertex.

Metadata is flushed and written to log:

System Process –
FASTIO_ACQUIRE and RELEASES on the data in Recycle Bin and then CC_FLUSH.
FLUSH_BUFFERS and writes to c: \$BitMap log.

Vertex is notified that blocks are no longer in use and blocks are marked as free in Volume Bitmap:

System Process –
FLUSH_BUFFERS and writes to c: \$BitMap log.
So what I'm seeing doesn't match. I don't see any IRP_MJ_CREATE nor IRP_MJ_QUERY nor IRP_MJ_CLEANUP

and I don't see any FASTIO_RELEASES

nor any FASTIO_ACQUIRE on the data in Recycle Bin

nor any FLUSH_BUFFERS

And this doesn't change when I toggle disabledeletenotify with

fsutil behavior set disabledeletenotify 1
fsutil behavior set disabledeletenotify 0
_______________________________________________


 
Last edited: