# File system, that handles over 2 million files

I'm going to store files in one folder in my server. The amount of files will exceed 2 million. Each file size will have range between 5MB - 100MB.

What kind of file system can handle well that amount of data?

I know that XFS can handle very large single files, can it handle large amount of files?

• AFAIK most filesystems perform better on operations such as listing files, following paths, or checking for the existence of a file when you don't store millions of files in a single flat directory, think beforehand about creating a naming convention and directory structure to more or less evenly distribute the files over a number (of levels ) of subdirectories. – HBruijn Aug 29 '18 at 13:28

But if you're going larger, you might want to consider using the -i size=512 option to give you a larger inode size. That will allow more directory-entries per inode, so the OS will have to thumb through fewer in order to traverse a tree. Given SSDs these days, this will improve things less than back in the spinning rust days; but it's an optimization to consider.