File System Limitation

Apparently I am only the second person on the internet to hit this error (judging by my Bing search this morning), but I thought I would share the solution in case someone else ever hits it :).

I was attempting to copy a 150 GB VHD file from one Windows Server 2008 R2 server to another, and after approximately 30 minutes, I would get the following error:

Move File

An unexpected error is keeping you from moving the file. If you continue to receive this error, you can use the error code to search for help with this problem.

Error 0x80070299: The requested operation could not be completed due to a file system limitation.


It turns out that the destination directory that I was copying to had NTFS compression enabled, and directories with NTFS compression enabled will not accept files over a certain size (according to this article on MSDN it is ~30GB: File Compression and Decompression).  As the file I was copying was just going to be archived, I disabled NTFS compression, zipped up the file, and copied it over with no problems.

For what it’s worth, although it was not the cause of my problem, I do see that KB 967351 mentions that this error can also be caused by a heavily fragmented hard drive.  The article also mentions compression as a potential problem, with 40-90GB as the threshold for errors:

Compressed files are more likely to reach the limit because of the way the files are stored on disk. Compressed files require more extents to describe their layout. Also, decompressing and compressing a file increases fragmentation significantly. The limit can be reached when write operations occur to an already compressed chunk location. The limit can also be reached by a sparse file. This size limit is usually between 40 gigabytes (GB) and 90 GB for a very fragmented file.