NTFS file compression via ATTRIB

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
#1
TCC 13.04.52 WinXP SP3 home
I tried to run the batch file below from the root directory of an NTFS drive:

*attrib/d/e/nej/s /a:-d-c-i +c +i * >>! F:\TMP\compress.log

The log file showed that files which previously did not have the C attribute obtained it, indicating that they were supposedly freshly compressed, thus using less disk space. However, the free space reported by @diskfree (executed in a separate TCC session) showed continuously decreasing free space - the exact opposite!

Any idea how this could be happening?
 
#2
perhaps it is a temporary effect, because the system is doing the compression in the background ... just speculation.
 

rconn

Administrator
Staff member
May 14, 2008
10,096
85
#3
The log file showed that files which previously did not have the C attribute obtained it, indicating that they were supposedly freshly compressed, thus using less disk space. However, the free space reported by @diskfree (executed in a separate TCC session) showed continuously decreasing free space - the exact opposite!

Any idea how this could be happening?
Unless you terminated every other process (including Windows Explorer) before running the test, the results will not be meaningful. There are dozens of foreground & background processes in Windows that continually allocate & free disk space. The only way to get a remotely significant result would be to test the free space before running ATTRIB, then do it again after ATTRIB has (completely) finished.

If you still get less free disk space (which I think is unlikely), complain to Microsoft -- it's their code.