Link to home
Start Free TrialLog in
Avatar of topwiz
topwiz

asked on

What's the recommended max # of open files in my situation?

I run a very busy web server with 4000+ domains of which about 10% of them are very active. The tech specs:

1. RH 7.1 + Apache 1.3
2. Dual 1 GHz PIII
3. 4 GB ECC RAM
4. Dual 74 GB SCSI

May I know what's the recommended max # of open files (file-max) in MY SITUATION? In addition, should I increase the max # of open inodes (inode-max)? Please point me to the reference you used to formulate your conclusion. Please don't preach about Apache tuning or anything off topic. Thank you.



Avatar of jlevie
jlevie

The "recommended max # of open files" is whatever is necessary for your server to operate without encountering application failures as a result of too many open files. If you aren't having problem in that respect now the current number is adequate.

Fiddling with the file-max or inode-max isn't something you do to improve performance. However, gratuitiously increasing those values far above what the server really needs can negatively affect performance by increasing the amount of memory allocated for the data structures to kernel needs.
For the inodes part, I suggest using another filesystem like reiserfs in which you don't have to bother about inode limits.
Though you should be carefull. No directory with too many files.
ASKER CERTIFIED SOLUTION
Avatar of DonConsolio
DonConsolio
Flag of Austria image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Just a thought, but I suspect that the spec that you have given us will not be the bottleneck. The bottleneck on this setup will mostlinkely be the ethernet connection. This will apply if the majority of files being accessed are over about 5-10K.

The next area that I would expect the bottleneck to be if you upgrade your ethernet card to a 1000/100/10 card would be the SCSI.

Issues here depend on spindle, and hence access/latency timings for the hard drive. Also the RAID array (if used) could vastly increase access speed, especially if you have a fairly high performance setup with a caching RAID array.

Therefore, the first thing that I'd be monitoring would be the ethernet bandwidth usage. If it gets above about 30% of the rated bandwith...i.e. 30Mb for a 100Mb link, then I would start to get concerned. Above that, the number of collisions start to cause problems with service. However, I expect, that the banwith that connects this server to the internet might be more limiting than that?

HTH:)
Now you know where to look for the first singn of any problems:).....use ratios to multiply bandwidth up to 30% of that available, and I'd guess that would match up proportionally to a number of the other factors that you've mentioned monitoring tools for. Use that as the threshold for you to start thinking about taking action:)