lkml.org 
[lkml]   [2004]   [Oct]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: 2.6.9 kernel oops with openais
FromSteven Dake <>
DateFri, 29 Oct 2004 16:57:06 -0700
Chris

The change was that from 2.6.8 to 2.6.9 the rlimit for memlock was
changed from infinity to 32k (and at the same time, normal users are now
allowed to use mlockall if they dont have alot of memory to mlock). I
fixed up the openais code by doing something evil from uid 0 like:

struct rlimit rlimit;

rlimit.rlim_cur = RLIM_INFINITY;
rlimit.rlim_max = RLIM_INFINITY;
setrlimit (RLIMIT_MEMLOCK, &rlimit);

Thanks
-steve

On Fri, 2004-10-29 at 16:45, Chris Wright wrote:
> * Steven Dake (sdake@mvista.com) wrote:
> > The use case is this (on 2.6.9):
> >
> > task starts as uid 0
> > task calls mlockall
> > task allocates several mb of ram
> > task drops root privs to non prived uid
> > further memory allocations fail
>
> What's the RLIMIT_MEMLOCK?
>
> thanks,
> -chris

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:07    [from the cache]
©2003-2010