[SOLVED] Re: Increasing the maximum number of open files

Nifty Hat Mitch mitch48 at sbcglobal.net
Thu Aug 5 18:15:34 UTC 2004


On Tue, Aug 03, 2004 at 06:01:55PM +0200, J.L. Coenders wrote:
> On Tuesday 03 August 2004 09:09 am, Rainer Traut wrote:
> > Hi,
> >
> > J.L. Coenders wrote:
> > > Hi guys,
> > > I have a program which tells me it needs more open files than the system
> > > can handle.
> > > When I do nlimit -n, it tells me I have 1024 files max. How do you
> > > increase this number, permanently? I found some stuff about
> > > changing /etc/security/limits.conf and /etc/pam.d/gdm and some others,
> > > but that doesn't really work. It's probably some simple trick and I
> > > remember something alike before, but I cannot remember how it was done.
> > > I use FC2 with KDE.
> >
> > /etc/security/limits.conf is the right place:
> > [root at asp5 root]# cat /etc/security/limits.conf |grep nofile
> > #        - nofile - max number of open files
> > notes           soft    nofile          90000
> > notes           hard    nofile          90000
> > [root at asp5 root]# su - notes
> > [notes at asp5 notes]$ ulimit -a|grep files
> > open files                    (-n) 90000
> >
> > Rainer
> 
> Thanks,
> This solved my problems.
> - Jeroen
> 

Caution... a program that opens so many files likely has a bug.  It
might be opening all the files in or under a dir or doing something
else silly.  It may get you at a later time.  If 1024 was the limit
today, then when will the limit of 90000 be hit...

Try to find out what it is doing and find ways to manage it, fix it or
get it fixed before it hits the 90000.

Since each open file establishes structures in the process and the
kernel eventually there will be a limit that you cannot tune your way
out of.  At that point things will stay broken until the bug is fixed
or you know how to manage the context.


-- 
	T o m  M i t c h e l l 
	/dev/dull where insight begins.





More information about the fedora-list mailing list