Jump to content
Corsair Community

NTFS allocation unit


Cadencia

Recommended Posts

I wanted to preview the effect on disk space of changing the NTFS allocation unit, so I wrote a little Visual Basic script to analyse what might happen.

 

All it does is to scan the system for disk drives, then work through the folders comparing the logical file size to the various possible allocation units to determine how much free space would be used up, perhaps unnecessarily.

 

In my particular case, changing the allocation unit would be a bad thing. But that's just me.

 

Anyway, I present the script here, in case it may help anyone else.

 

The script is in the zip file, what it looks like on my computer is in the png.

Analysis.PNG.de4cd70c36d31846e47241751ca5a75f.PNG

Link to comment
Share on other sites

  • Corsair Employees

I am sorry but VBS scrips are not allowed to many chances for Virus.

What exactly are you trying to run?

And with SSD Drives I would suggest you format them with 32K Allocation for best performance.

Link to comment
Share on other sites

OK, fair enough, I understand. I wrote the script for my own use, and thought it might be useful for others.

 

I wrote it as a VBS script so anyone who is interested could read the code and see that no evil hacker was at work.

 

If anyone is interested, contact me directly.

 

Ramguy, you ask what I'm trying to run. Actually, I was trying to assess the effect of changing the NTFS allocation size from 4K to other values, both in terms of disk space used, and in terms of actual performance.

 

Having run the script, I can be absolutely sure that in my case, with my system set up as it is, with only programs and system stuff on the SSD, and all my documents - work, photographs and stuff on the mirror RAID - that changing the allocation unit from 4K to 32K would cost me 1,228 4K blocks of disk that could never be used for anything. That's nearly 5GB.

 

That's because there are very few large files on the disk, I suppose. 71% of all the files on the disk are less than one 32K allocation unit.

 

For my purposes, the performance I seek is small random reads and writes - low latency, not high bandwidth. Almost none of the disk I/O I do is covered by the 'large sequential read/write' that ATTO tests, and that many others are looking for. I am very happy with the real performance, which, after all, does have all the caching turned on, unlike the benchmarks. I was a little concerned at first by the thought that the performance may suddenly fall away dramatically, but I've decided not to worry about that until it happens. I figure I can probably do more harm than good anyway.

 

I just find it interesting.

 

Specifically, I do not know what effect changing the allocation unit size would have on 4K reads/writes. I don't know whether that means that the minimum write size is therefore (say) 32K. That would seem unlikely, but I think it's still a fair question

 

Also, I wonder how the allocation unit size would interact with the stripe size in a RAID0 setup - not that I have one. I guess you would want the partition to align on a 128K boundary (assuming the smallest erase amount is 128K), and the normal file size to encompass at least two stripes. I assume that a file which doesn't cover more than a stripe only actually gets written to one of the disks. All this was easy when dealing with cylinders and tracks and sectors! Now there's no consideration of minimising head movement, just minimising erase cycles!

 

Now, I have two specific questions.

 

In various posts I have seen it firmly stated by either yourself or Bluebeard that the firmware level on the X256 is 1.0, and that it does NOT yet support TRIM, nor Garbage Collection.

 

Now, my x256 insists it has firmware 1.1, and insists that it supports TRIM. Obviously it is confused - but what's up?

 

And secondly, it has been said that one can 'restore' SSD performance by writing all x'ff' all over the SSD. And yet, when I examine my SSDs, the as-yet untouched sectors of the disk show up as all x'00'. That's one x256, one P256, and one foreigner examined, and that's all I have access to.

 

So what gives there?

CDI.thumb.PNG.0e03ddbb14ef1a6bcb555066b3786416.PNG

Link to comment
Share on other sites

  • Corsair Employees
For my purposes, the performance I seek is small random reads and writes - low latency, not high bandwidth. Almost none of the disk I/O I do is covered by the 'large sequential read/write' that ATTO tests, and that many others are looking for. I am very happy with the real performance, which, after all, does have all the caching turned on, unlike the benchmarks. I was a little concerned at first by the thought that the performance may suddenly fall away dramatically, but I've decided not to worry about that until it happens. I figure I can probably do more harm than good anyway.

 

I would suggest that these tasks be run from a spinning HDD and just use the SSD to start the system and I would also suggest moving the Temp and swap files to another HDD as well for best performance.

Link to comment
Share on other sites

Well, I hear what you say, and I understand why you say it. Thanks for the thought. But moving the swap file to a spinning disk rather than the SSD is not a good idea. Writing to the swap file is always done in large chunks, and reading from it is done in random fashion - just ideal for an SSD, even a badly performing one. Actually in my case, I have no swap file anyway, so the point is moot.

 

As for the temp files - again, why pay for a device that has zero seek time, then put the files that can most benefit from zero seek time (small random temp files) onto a device with seek times quantum amounts higher? Ultimately, the SSD will slow up because of using all the ready-erased blocks, we are told. But - as measured by others - even then the SSD is streets ahead of the very best spinning disk.

 

It is a shame that the benchmarks we use here demonstrate the extreme speed of the SSD in sequential read/write situations rather that the extreme low latency in random access situations. The former is really useful if you are streaming video or the like. The latter is extremely useful for everything else. It is low latency that makes the system FEEL faster, but it's hard to measure. And the SSD is the best way to convert a dog of a machine into a rocket ship. Out of the box.

 

You didn't answer the two questions at the end of my previous post. If you can't answer them, that's fine, but I would like a yes or no, please.

Link to comment
Share on other sites

  • Corsair Employees

The way you use the system is hard to judge from a few posts but ultimately to really get the best performance of any system configuration some down and dirty tweaking and testing is the only way to know 100% for sure. I think you get the idea from reading some of your other posts so I will leave the how you do/did it to you.

And sorry I must admit I missed the last two questions :eek: sorry!

Now, I have two specific questions.

 

In various posts I have seen it firmly stated by either yourself or Bluebeard that the firmware level on the X256 is 1.0, and that it does NOT yet support TRIM, nor Garbage Collection.

 

Now, my x256 insists it has firmware 1.1, and insists that it supports TRIM. Obviously it is confused - but what's up?

A: TRIM is defined by STATA.org as doing several tasks one of which is Garbage Collection or wiping deleted files and clearing empty blocks to get them ready to be written to with new data. And a form of TRIM was enabled with the released version but required a utility to do this function "Wiper Utility" But was never released in a official version only as beta.

Microsoft Also release Windows 7 with TRIM support for SSD's but this is done with in the O.S. Not all drives in fact most do not support Windows 7 version of TRIM, but I would expect that too change as new updates are released. I think Intel has released a working firmware that does not brick the drives and Indolinx seems to be close but not quite all the way. Samsung Just released their Trim Supported Version and seems to be working well. "Our P-Series Drives would be a reference"

And secondly, it has been said that one can 'restore' SSD performance by writing all x'ff' all over the SSD. And yet, when I examine my SSDs, the as-yet untouched sectors of the disk show up as all x'00'. That's one x256, one P256, and one foreigner examined, and that's all I have access to.

A: I would suggest using Parted Magic with the Erase command (it is easy to use and open source) this will wipe the drive so all clusters are clean and ready to written to. As you may know with Microsoft's file system/'s when a file is deleted it will not delete all of the data only the first character then rest of the file is still there, with a spinning HDD the left data will just be over written but with SSD's any data left in said Cluster must be erased before new data can be written, slowing the drives performance over time.

Link to comment
Share on other sites

  • Corsair Employees
You should ask the software vendor of that utility! The only requirement is that the block/'s show No data in them other wise an erase will have to be completed before new data can be written with an SSD.
Link to comment
Share on other sites

I am sorry Ram Guy... I really don't understand.... isn't there a default clean/no data state on the SSDs? The utility is Acronis which has been recommended over and over and over in these forums by Corsair people and others :).... Would this mean that either 0s or 1s, as long as they are all the same would indicate a clean state....

I am sorry that I am being thick here.... and I am usually a fairly intelligent guy... but I am truly trying to understand this :(....

Link to comment
Share on other sites

  • Corsair Employees
I would suggest using Parted magic with the Secure Erase Disk and the disk will be like new or Virgin state. Accronins would be used to create and restore the Image, I have not used the utility in Accronis that you are asking about but any utility that I have used and selected to write one's or Zeros has not erased any SSD I have tried properly. You should sue the Secure Erase. Please try what was suggested, you are welcome to use something else and try what ever you like but I am sorry there are just too many variables for me to support them all.
Link to comment
Share on other sites

I again tried to use GParted and Partied Magic which seems like a nice Linux GUI for GParted. I could delete partitions, but I find no way Secure Erase, and in terminal mode typing the command that is used in the thread on the forum and I get an I/O error. is there something that I am doing wrong. I assume that just deleting the partitions in Parted Magic does not reset the drive.
Link to comment
Share on other sites

Randy - you use GParted to tell you what the name of the SSD is according to Ubuntu/whatever distro you are using; GParted can't issue the Secure Erase command.

 

http://ata.wiki.kernel.org/index.php/ATA_Secure_Erase

 

Follow that to the letter. You can use a Ubuntu 9.10 CD - the commands and interface are basically identical. Use GParted to tell you Ubuntu's name for your SSD (e.g. /dev/sda or /dev/sdb - you need to remember that throughout the guide). If you are having trouble issuing a command, add "sudo" without "" before the command that isn't working.

 

If you can't get your drive out of the "frozen" state, you need to hot-plug your SSD, i.e. let the kernel load and Ubuntu user interface, then before you start GParted, plug your SSD in then. Then just follow the guide as closely as you can.

 

I don't know what Secure Erase does (you seem to be really very keen to know whether it writes all 1s or 0s) - but it's irrelevant in that it makes your drive factory-fresh and you won't be able to make it any cleaner than it is after issuing the secure erase command.

 

I hope this helps.

Link to comment
Share on other sites

Thanks to NickCPC for the ATA erase tip.

 

To get some answers to the other questions, I did some serious testing. My conclusions are detailed here:

 

http://forum.corsair.com/v3/showthread.php?t=84258

 

The only thing I am now really unhappy about is the fact that the various levels of firmware that are already in the wild are completely undocumented. The authoritative word in the FAQ is that firmware is at level 1.0. And yet I have a x256 with firmware at 1.1, and x32s with firmware at 2.0.

 

Now, there must be someone in Corsair who knows what changes between versions. They should let us know roughly what the differences are. And, if there are no differences other than, say, needing to handle different type of chip or something, that should be reported too.

Link to comment
Share on other sites

  • Corsair Employees

We are looking at the new firmware now and when we have all of the information ready we will post it. But we will not release it until there is a stable method of updating the firmware. That has been the hold up, and if you search other SSD Manufacturers you will see when they released Beta versions it often caused more problems that it resolved.

 

However, new production drives will have the latest firmware installed.

Link to comment
Share on other sites

Oh, quite so. I'm not bothered by how long it takes to get the on-site update sorted. Really. Better safe than sorry. Sometimes, when you're sitting on the bleeding edge you get cut - that's a given.

 

What bothers me is that to my certain knowledge there are at least three versions of the X series firmware out in the wild, and presumably they do different things, but that nobody will say what those different things are, and in what circumstances they do whatever it is that they do!

Link to comment
Share on other sites

  • Corsair Employees
Yes and I agree with you and apologize that the information has not been made public, however, they have decided to wait until there is a released version of the firmware and update utility before posting that information. I will ask but at this time our SSD Product team felt it best to wait for the final release.
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...