Mobile app version of vmapp.org
Login or Join
Samaraweera270

: How many files can I stored in a linux folder?(Amazon EC2) On Linux systems (Amazon EC2), what is the maximum number of files that can be stored in one directory without slowing down performance?

@Samaraweera270

Posted in: #Linux

On Linux systems (Amazon EC2), what is the maximum number of files that can be stored in one directory without slowing down performance? (I know too many files in one directory on Windows systems will cause the system to operate slowly.)

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Samaraweera270

1 Comments

Sorted by latest first Latest Oldest Best

 

@Moriarity557

Personally, I would keep the count under 30 000 to make sure I wouldn't have to worry about performance problems with any versions of ls or similar tools.

From a great answer on SO, here's the number of files you are able to keep, depending on your chosen file system (ext3 is default on Amazon Linux I think).

FAT32:


Maximum number of files: 268,435,437
Maximum file size: 4GB
maximum number of files per directory: 65535


NTFS:


Maximum number of files: 4,294,967,295
Maximum file size: 16TB currently (16EB theoretically)


Ext2:


Maximum number of files: 10¹⁸
Maximum file size: 2TB
theoretical file per directory limit: 1.3 × 10²⁰ files


Ext3:


Maximum number of files: number of bytes in volume/2¹³.
Maximum file size: 16GB (1KB block) to 2TB (4KB block)


Also, see this on performance problems with ls when using large directories.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme