setrlimit

foobar foobar at intter.net
Mon Apr 28 07:03:01 EDT 2003


Hi,

On Mon, 28 Apr 2003, Bob Tito wrote:

> To be honest, not a real problem here, but a error in the log on which i
> cannot find information with google...
>

man setrlimit , man ulimit , man sysctl

> setrlimit: unable to set file discriptors limit to -1...
> Is this a problem, an more how can i fix this ?
>

It tries to set fd-limits unlimited , 1024 should be reasonable I think
if your server doesn't handle much connections. Master should be started
as root (bind to 143, pop + setrlimits).

> Apr 28 11:31:01 nomagic master[19072]: exiting on SIGTERM
> Apr 28 11:31:01 nomagic saslauthd[19074]: server_exit     : master
exited:
> 19074
> Apr 28 11:31:05 nomagic master[3073]: setrlimit: Unable to set file
> descriptors
> limit to -1: Operation not permitted
> Apr 28 11:31:05 nomagic master[3073]: retrying with 1024 (current max)

This just tells (see man ulimit) that max open files is just 1024 which is
the default (filedescriptors for sockets etc). You need to be root to
setrlimit filedescriptors usually and thats why it says permission denied
there (running master as non-root?).

Example in ircd (sorry off-topic again): if you have ulimit -n 1024 then
you'll server will handle only ~1k connections same time (depends on how
many fd's opened) so usually before starting ircd we say
ulimit -n 10240 or something else.

I hope this helped (and shoot me again).

++Titus





More information about the Info-cyrus mailing list