Intro Download and install Frequently Asked Questions Tips and tricks

Homepage







© J.C. Kessels 2009
MyDefrag Forum
May 21, 2013, 08:07:15 am *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1] 2 3
  Print  
Author Topic: Intel X18-M 1st Gen: how to use mydefrag for trimming my drive?  (Read 6526 times)
neowam
Newbie
*
Posts: 4


View Profile
« on: December 03, 2009, 11:52:42 am »

I am the owner of a X18-M 1st Generation. Intel will not update the firmware with TRIM support, only for the 2nd Gen, stupid!!!

So, I got an alternative also called TONY-TRIM. You can find the information here: http://www.ocztechnologyforum.com/forum/showthread.php?t=64753

It's simple what it does:
  • Consolidating free disk space with Perfect Disk
  • With AS Cleaning tool, write a big file and then delete it

It is possible to do this also with an Mydefag Script, or maybe a feature todo this with mydefrag within one step?

Please read the guide of OCZ fully before sending me an answer, because otherwise you don't know were I am talking about.
« Last Edit: December 03, 2009, 11:55:07 am by neowam » Logged
quanthero
JkDefrag Hero
*****
Posts: 234



View Profile
« Reply #1 on: December 03, 2009, 12:48:25 pm »

In my experience, MyDefrag consolidates free space as good as PerfecDisk does, given the right choice of VolumeActions. The 'Consolidate Free Space' script would be best for complete free space consolidation, in my opinion.
Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #2 on: December 03, 2009, 02:56:21 pm »

It is possible to do this also with an Mydefag Script
Yes, I think so. All you have to do is add a RunProgram line to the end of the MyDefrag FlashMemoryDisks.MyD script to start up the "Freespacecleaner AS-Clean" program. All automatic, and easier to setup than perfectdisk.... And free.

Quote
or maybe a feature todo this with mydefrag within one step?
Interesting idea, I will consider it. It would make MyDefrag more useful, I think. It sounds simple enough to "write a big file and then delete it". Are you sure that is all it does? I have read the article at your link but it's not entirely clear from that text.

p.s. The free Microsoft SDelete program can also wipe a disk, but it uses zero's so I'm not sure if it's suitable for SSD's.
Logged
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #3 on: December 03, 2009, 04:17:39 pm »

Okay I'm a bit lost... What's good on overwriting an SSD drive with 1s? Doesn't that count as write cycle too?
First I thought it's done to make Windows to free the NTFS reserved zone, but that can be IMO done without really writing anything to the drive as far as I know...
Logged
neowam
Newbie
*
Posts: 4


View Profile
« Reply #4 on: December 03, 2009, 06:43:36 pm »

Okay I'm a bit lost... What's good on overwriting an SSD drive with 1s? Doesn't that count as write cycle too?
First I thought it's done to make Windows to free the NTFS reserved zone, but that can be IMO done without really writing anything to the drive as far as I know...

Please read the guide on the OCZ forum carefully. Then you will understand the story.

Please also read http://www.anandtech.com/storage/showdoc.aspx?i=3531 on Anandtech to make a good understanding how SSD defragging works.
Another forum with good example pictures is http://www.lostcircuits.com/mambo//index.php?option=com_content&task=view&id=69&Itemid=1

Here is also another thread I logged on the Intel forums: http://communities.intel.com/thread/8897?tstart=0
« Last Edit: December 03, 2009, 06:53:02 pm by neowam » Logged
neowam
Newbie
*
Posts: 4


View Profile
« Reply #5 on: December 03, 2009, 06:58:16 pm »

In my experience, MyDefrag consolidates free space as good as PerfecDisk does, given the right choice of VolumeActions. The 'Consolidate Free Space' script would be best for complete free space consolidation, in my opinion.

Can somebody describe the process better: what is consolidating and what it exactly does with the data?
Logged
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #6 on: December 03, 2009, 09:47:58 pm »

Please read the guide on the OCZ forum carefully. Then you will understand the story.

Please also read http://www.anandtech.com/storage/showdoc.aspx?i=3531 on Anandtech to make a good understanding how SSD defragging works.
Okay, I have read these two (sorry, don't have time to read the rest) but I still don't see why writing a file full of 1s may count as trimming the drive. In my opinion, consolidating free space means a lot of reading and writing mostly on files that don't need to be moved and overwriting all free space also means a lot of erasing and writing all over the drive. I can imagine mechanisms that may make it all improve things (particularly write speed) but they are not mentioned explicitly. AND you still improve your drive write speed a bit at a cost of overall wearing out the drive and reducing its lifetime.
Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #7 on: December 04, 2009, 12:04:28 am »

Can somebody describe the process better: what is consolidating and what it exactly does with the data?
Consolidation simply moves all files together, so that the gaps as large as possible. SSD disks internally use large blocks (generally 128 pages or 512KB). If a small file is created and the SSD can find a free block then it's nice and fast. If it cannot find an entire free block then it has to use part of another block. It then has to read the entire block, change the part that is used by the file, and write the entire block back. This is called memory block fragmentation and can dramatically reduce the speed of SSD disks.
Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #8 on: December 04, 2009, 12:10:57 am »

Okay, I have read these two (sorry, don't have time to read the rest) but I still don't see why writing a file full of 1s may count as trimming the drive.
See my posting above. When a file is deleted then the SSD does not know that the blocks are now free. This is because deleting a file is only done by Windows by deleting the file's entry in the MFT/FAT. Apparently when writing 1's to a memory block this signals the SSD that the block is free. I did not know that, this TONY-TRIM thing is news to me.
Logged
fxm
JkDefrag Senior
****
Posts: 35


View Profile
« Reply #9 on: December 04, 2009, 01:12:23 am »


When a file is deleted then the SSD does not know that the blocks are now free. This is because deleting a file is only done by Windows by deleting the file's entry in the MFT/FAT. Apparently when writing 1's to a memory block this signals the SSD that the block is free.

A sort of top-level description is here
  http://en.wikipedia.org/wiki/TRIM_(SSD_command)
and a lower-level description is here
  http://www.devwhy.com/blog/2009/8/4/from-write-down-to-the-flash-chips.html
(including an explanation of why the 1's are important).

One could easily imagine something like a version of contig modified to create a file filled with 1s and then delete it [or an equivalent function in MyDefrag].

Using SDelete as a base (not that you suggested any such thing) would appear to be out of the question; its recursive and exhaustive first pass would be enough of a disaster on a [limited life] SSD device even with the subsequent [apparently useless in this context] overwrite passes disabled.
Logged
fxm
JkDefrag Senior
****
Posts: 35


View Profile
« Reply #10 on: December 04, 2009, 02:46:07 am »

On further thought...

Either I'm missing something or the so-called defragging of an SSD (at the OS level) is complete snake oil.

Blocks that appear contiguous to the OS need not be (in general won't be) anywhere near contiguous in the page space of the device.

Clearly a function that fills the entire drive with 1s will do exactly what it is supposed to do:  restore near-new performance.  The benefit of filling anything less than the entire drive, however, seems to be unpredictable at best.
Logged
poutnik
JkDefrag Hero
*****
Posts: 1105


View Profile
« Reply #11 on: December 04, 2009, 07:31:04 am »

Okay I'm a bit lost... What's good on overwriting an SSD drive with 1s? Doesn't that count as write cycle too?

AFAIK
SSD erasing is writing 1s to cleaned blocks.
SSD writing is writing  0s or leaving 1s in a written block.

If a writing does not need to revert some 0s to 1s  ( well, rare case ),
then the block can be even rewritten without erasing.
( Write block size is smaller then erase block size ).

So, writing 1s is technically erasing previously written and freed blocks,
and deleting such file leaves blocks ready to next write.
It cleans bits needed to be cleaned and does nothing to already clean blocks.
« Last Edit: December 04, 2009, 07:33:59 am by poutnik » Logged

It can be fast, good or easy. You can pick just 2 of them....
Treating Spacehog zone by the same effort as Boot zone is like cleaning a garden by the same effort as a living room.
Kasuha
JkDefrag Hero
*****
Posts: 595


View Profile
« Reply #12 on: December 04, 2009, 10:20:54 am »

Let's assume if a page is being overwritten with all 1s, that page's old version is invalidated but new version is not even allocated. Let's also assume that overwriting a non-allocated page with all 1s does not allocate it. If that is true, then making a big file containing all 1s should be very fast as there is nothing really written to the disk, only old pages are getting invalidated and eventually invalid blocks erased. That's very strong assumption IMO and even if some SSDs do that, I am definitely not sure if that can be guaranteed for all SSDs as it's way deep in the firmware level of the SSD. And yet, the chance that it will free a new page is relatively small as you still have to invalidate all 128 pages in a block for that and these chances go down very fast with the disk fill ratio.

If the above assumptions are true, then yes, overwriting the disk free space with 1s helps and does not wear out the drive significantly, but the effect goes down fast as the disk fills up. If they are not true for that particular SSD, it means extensive wearing out the drive without any positive effect.

However I completely fail to see how consolidating free space on the disk may even remotely improve anything.
Assuming files were written there in random order, there are just random blocks getting invalidated and if there were previously any free blocks they get used, so in my opinion it just adds to overall internal fragmentation of the SSD data instead.

------------------------------------------------

Regarding how overwriting with 1s could be implemented in MyDefrag, I believe it could use a little different strategy. Windows often get freaked out when disk is getting very full and may display various warnings and run various processes attempting to free disk space during that. MyDefrag could simply create a relatively small file (10 ~ 100 MB) full of 1s and then move it all over the drive so that it "visits" all unused clusters.
But it will only work if the above assumption is true which is something I still don't completely believe.
Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #13 on: December 04, 2009, 11:16:54 am »

http://www.devwhy.com/blog/2009/8/4/from-write-down-to-the-flash-chips.html
(including an explanation of why the 1's are important).
Thanks for the link, I appreciate it. The articles says that flash memory is initialized to 1's. But it does not say (maybe I have missed it) that writing 1's to a block will be a signal to the flash memory controller that the block is now free. Perhaps the controller does not think that at all, and will think that all memory is in use now.
Logged
jeroen
Administrator
JkDefrag Hero
*****
Posts: 7155



View Profile WWW
« Reply #14 on: December 04, 2009, 11:23:48 am »

MyDefrag could simply create a relatively small file (10 ~ 100 MB) full of 1s and then move it all over the drive so that it "visits" all unused clusters.
It's an interesting idea, and I wonder if it will work. I think the mapping of blocks by the internal flash memory controller may spoil things. It may place blocks anywhere. MyDefrag may think it is moving the temporary file to a particular block, but the memory controller may do something totally different. There is no 1-to-1 relation between what MyDefrag sees and the actual physical memory.
Logged
Pages: [1] 2 3
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.5 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!