max open files reached

Roman Neuhauser neuhauser at
Wed Jun 4 06:29:17 PDT 2003

I have a script run by periodic(8) in the daily batch that is supposed
to backup all databases from the local MySQL server using
mysqlhostcopy(1). It used to run fine for a few months, but has
been failing consistently with ENFILE (23) lately.

The box is an Intel Celeron 533 (or some such) with 128 MB RAM. These
are all the related sysctl knobs I could find. This is as of 20:40, so
the value of kern.openfiles is reasonable.

roman at ishtar ~ 1001:0 > sysctl -a kern|grep files
kern.maxfiles: 2024
kern.maxfilesperproc: 1821
kern.openfiles: 512

I've cranked the kern.maxfiles value to 4096, and the backup has run to
completion again, but am I risking anything? I mean, the fd's cost
memory, is there any potential for problems?

If you cc me or remove the list(s) completely I'll most likely ignore
your message.    see

More information about the freebsd-questions mailing list