System May Pause while Accessing Large NTFS Folder

Applies to: Microsoft Windows Server 2003 R2 Datacenter x64 EditionMicrosoft Windows Server 2003 R2 Enterprise Edition (32-Bit x86)Microsoft Windows Server 2003 R2 Standard Edition (32-bit x86)


When individual folders contain large numbers of files (more than 50,000 files), performance issues may occur while enumerating the list of files. In some cases, applications may also experience long delays when accessing folders containing more than 50,000 files.  This delay may appear as a momentary pause of an application, or the delay can last for several minutes. Enumerating the files over the network may result in a time out.

More Information

This issue can occur when a folder contains a large number of items or if an application stores a large number of items in a folder.The optimal design strategy for application developers is to implement a database engine for the storage of small data units in one database whenever possible. When an application enumerates the directory contents of a large folder, NTFS and cache manager are tasked with reading and processing large quantities of metadata to perform the enumeration. This can also occur when Explorer enumerates a folder with a large number of files.

The amount of time required to read, map, and process folder indexes may vary depending on hardware capabilities, file system fragmentation, memory, CPU, and cache performance. There is no prescribed limit to how many files you can place in an NTFS folder, but Microsoft recommends that you test your particular scenario to ensure that the time required to enumerate the contents of large folders does not affect application performance or uptime requirements.  If necessary, add additional layers to the folder structure so there are a smaller number of files per folder.