[nycbug-talk] How to raise openfiles ulimit in FreeBSD?
nikolai
nikolai at fetissov.org
Mon Apr 16 15:13:34 EDT 2007
> On Sat, 14 Apr 2007 13:59:10 -0700, "Bob Ippolito" <bob at redivi.com> wrote:
>> On 4/14/07, Yusuke Shinyama <yusuke at cs.nyu.edu> wrote:
>> > Hi,
>> >
>> > I'm trying to raise the per-user ulimit for openfiles. (FreeBSD)
>> > /etc/login.conf defines it unlimited and sysctl
>> kern.maxfilesperproc=11095.
>> >
>> > But when I login as a normal user, the openfiles is 1024,
>> > whereas I get 11095 as root.
>> >
>> > How this value is determined? (I checked my bashrc.)
>>
>> ulimit -n 11095
>
> I can do this as root. But I'd like to do this as a normal user.
>
> grape$ su -
> Password:
> grape# bash
> [root at grape ~]# ulimit -n 11095
> [root at grape ~]# ulimit -n
> 11095
> [root at grape ~]# exit
> grape# exit
> logout
>
> grape$ ulimit -n 11095
> bash: ulimit: open files: cannot modify limit: Operation not permitted
> grape$ ulimit -n
> 1024
>
> Any hints?
>
ulimit -aH to see hard limits
ulimit -aS to see soft limits
and check out getrlimit(2)
--
nikolai
More information about the talk
mailing list