Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Oct 2003 15:02:05 +0100 (CET)
From:      Konrad Heuer <kheuer2@gwdg.de>
To:        "Woolworth,Derrick" <DWOOLWORTH@CERNER.COM>
Cc:        "'freebsd-questions@freebsd.org'" <freebsd-questions@freebsd.org>
Subject:   Re: Open Files
Message-ID:  <20031027150027.O91426@gwdu60.gwdg.de>
In-Reply-To: <F7C5516942F9DE4099D389C27E43C11F0C856594@mailwhq3.cerner.com>
References:  <F7C5516942F9DE4099D389C27E43C11F0C856594@mailwhq3.cerner.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Mon, 27 Oct 2003, Woolworth,Derrick wrote:

> I am having difficulty with one system - FreeBSD 4.8
>
> After a couple of days, the system continually reports that there are too
> many files open.  At that time I cannot ssh into the system or ftp, etc.
> obviously, the kern.maxfiles is too low.
>
> However, I have continually increased the number of max files - actually
> both:
>
> kern.maxfiles = 65535
> kern.maxfilesperproc = 65535
>
> The system is running 141 processes on average, which isn't terrible in my
> opinion.  Most of these are Apache 1.3.27, MySQL 4.1.0-alpha, Courier mail
> system, and a couple of applications my firm has written ourselves.
>
> The question is really, is there a way to examine how many files are open on
> a per process basis?  I know we can monitor the number of open files with
> pstat -T, but this doesn't help us troubleshoot which application is
> responsible for this large number of open files.
>
> The processes that we are building are daemons that are pre-forked - none
> seem to be crashing, and we've checked the open/close calls as closely as
> possible.
>
> Also, does anyone know of a bug in MySQL or mod_php4 (4.3.4.r1) or Courier
> 0.43.0 that would cause files to be opened and not closed?

I'd suggest lsof from /usr/ports/sysutils/lsof which listens all open
files in the system.

Regards
Konrad

Konrad Heuer (kheuer2@gwdg.de)  ____            ___  _______
GWDG                           / __/______ ___ / _ )/ __/ _ \
Am Fassberg                   / _// __/ -_) -_) _  |\ \/ // /
37077 Goettingen             /_/ /_/  \__/\__/____/___/____/
Germany





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031027150027.O91426>