[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [monit] monit not honoring ulimit -a setting

From: Mike Oliveras
Subject: Re: [monit] monit not honoring ulimit -a setting
Date: Tue, 13 Apr 2010 10:09:23 -0400

I'll look into that.

Thanks for the information, much appreciated.

On Tue, Apr 13, 2010 at 8:30 AM, <address@hidden> wrote:
The setting is not controlled by monit. The limits.conf setting is PAM related - monit starts as system service and there's no session => the limits.conf is not evaluated.
If you want to rise the filedescriptors limit, you can create monit startup script which will first set the ulimit and then start monit.

limits.conf manual page excerpt:
Also, please note that all limit settings are set per login. They are not global, nor are they permanent; existing only for the duration of the session.

M/Monit support

On Mon, Apr 12, 2010 at 11:33:51AM -0400, Mike Oliveras wrote:
> I have a SIP application that requires a lot of UDP ports, so the nofile
> parameter was increased in the limits.conf file.  My Machine is running
> Centos 5.4.  I am running monit 5.1.1 from inittab as follows:
> # Run monit in standard run-levels
> mo:2345:respawn:/usr/bin/monit -Ic /etc/monitrc
> moff:06:wait:/usr/bin/monit -Ic /etc/monitrc stop all
> My monit.rc file starts up the program as another user.
> # Test SBC
> check process testsbc with pidfile /home/test/sbc/data/
>     start program = "/etc/init.d/testsbc start"
>          as uid testsbc and gid testsbc
>     stop  program = "/etc/init.d/testsbc stop"
>          as uid testsbc and gid testsbc
> When monit tries to start testsbc, it fails with errorno=24 (too many files
> open).
> If I run the init script directly as the "testsbc" user then it runs without
> issue.
> If I execute ulimit -n from either the root or testsbc user, it does
> correctly display the nofiles as my increased limit.
> address@hidden sbc]# ulimit -n
> 65535
> address@hidden sbc]#
> address@hidden sbc]# su - factor
> address@hidden ~]$ ulimit -n
> 65535
> Anyone experience this before?  I was going to open a bug report but wanted
> to check first if I was just missing some configuration or something.
> Thanks,
> Mike

reply via email to

[Prev in Thread] Current Thread [Next in Thread]