[lkml]   [2001]   [Sep]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: max arguments for exec

On Wed, 26 Sep 2001, Kiril Vidimce wrote:

> Yeah, I know, but we would like to avoid building a custom kernel. If
> we do end up going this route, I wonder if there is a limit for
> MAX_ARG_PAGES. Any idea? I think 128 pages (512K) would be sufficient
> for our needs.

be careful with MAX_ARG_PAGES, because struct binprm is allocated on the
kernel stack, so if it's too big, the kernel stack will overflow in
unexpected places. A realistic limit is 1-2 MB, that causes a 1-2 KB
kernel stack footprint.

(ob'plug: or use the patch i posted, the size of struct binprm is constant
and small there :-)


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:03    [W:0.050 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site