Patch for not going beyond NOFILE system limit (updated)

Started by Peter Eisentrautabout 17 years ago1 messageshackers
Jump to latest
#1Peter Eisentraut
peter_e@gmx.net

This is an updated and properly autoconf-guarded patch for this
previously reported issue:

"""
Jacek Drobiecki recently sent me a patch which stops postgresql to
actively violate the system limit of maximum open files
(RLIMIT_NOFILE) in src/backend/storage/file/fd.c, function
count_usable_fds().

This avoids irritating kernel logs (if system overstep violations are
enabled) and also the grsecurity alert when starting PostgreSQL.
"""

References:
http://archives.postgresql.org/pgsql-bugs/2004-05/msg00103.php
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=248967

I think we can put this into 8.4 or the first commit fest of 8.5.

Attachments:

check-rlimits-nofile.patchtext/x-diff; name=check-rlimits-nofile.patchDownload+23-0