[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 263
  • Last Modified:

Linux: Red Hat Fedora Core 4: Directory Limit

I know this question has been asked before but I could find no definitive answer...

I have a dedicated server setup by a hosting company.

I wrote a program that dumps up to 8 files in a directory. The files are no more than 100k each. Some dirs have more, some less. I reached about 2000 subdirectories in a directory when I was unable to write any more data. I had to purge part of the directory to write new data.

Is there a 'default' directory or file count limit for this OS?
0
Bob-Villa
Asked:
Bob-Villa
1 Solution
 
ygouthamCommented:
i think the number of subdirectories runs much higher than 2000. the number should be somewhere in the region of 32k to 64k. am not sure on this.  read somewhere that is the number supported by a "ext2".  but since we are now in ext3/reiser the number should only be higher.

i could also be wrong.  it might also be files + sub-dir = 32k.  i hope that the disk had sufficient space left???

goutham
0
 
ravenplCommented:
> Is there a 'default' directory or file count limit for this OS?
There is no such limit. It's only performance limit.

But there is a limit on number of files per whole filesystem. You can check the limit and current usage with
df -i

Also, what was the errormessage while file creation failed?
0
 
Bob-VillaAuthor Commented:
it is ext3. with your hints was able to find more info. Split up the directories into 4 subs and everything worked out fine. Thanks.
0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now