Operating System - HP-UX
1849227 Members
7296 Online
104041 Solutions
New Discussion

[Q] "nofiles" value change ..

 
Tony, Lim
Frequent Advisor

[Q] "nofiles" value change ..

All..

I would like to know what impact is expecting to change "nofiles" value.

Now, our UNIX server has a '256' value at nofiles parameter.

I could be confirmed using "ulimit -a" command.

I should change change this value '256' to '1024' due to another reason.
However, before then, I really want to know that this change will impact which part in UNIX server.

Would anyone let me know about this ?
5 REPLIES 5
Pete Randall
Outstanding Contributor

Re: [Q] "nofiles" value change ..

I'm assuming that you mean nfiles rather than nofiles. The only implication this will have is that your kernel will occupy a little more memory because it now has to have larger tables to keep track of the increased number of open files. The difference is minimal.


Pete

Pete
spex
Honored Contributor

Re: [Q] "nofiles" value change ..

Hi Tony,

I believe the 'nofiles(descriptors)' line you see when you run 'ulimit -a' is derived from the following kernel parameters:

nfile: System-wide limit on open files
maxfiles: Soft-limit on max. # of open files per process
maxfiles_lim: Hard-limit on max. # of open files per process

To increase this value, you'll want to adjust maxfiles and maxfiles_lim upward. Note that maxfiles <= maxfiles_lim << nfile.

PCS
spex
Honored Contributor

Re: [Q] "nofiles" value change ..

You can also increase nofiles for the current session by 'ulimit -n '.
A. Clay Stephenson
Acclaimed Contributor

Re: [Q] "nofiles" value change ..

Increasing nofiles wich is actually maxfiles and maxfiles_lim will increase the per-process number of open file descriptor limits. Because this could increase the system-wide number of open files, you need to also consider increasing nfile.

You should note that if 10 processes have the file "/MickeyMouse" open, that only counts as 1 for nfile so that increases in the per-process limits is not a direct
relationship to the needed increase in the system-wide files.
If it ain't broke, I can fix that.
Tony, Lim
Frequent Advisor

Re: [Q] "nofiles" value change ..

Thanks all.