Mailinglist Archive: opensuse (2459 mails)

< Previous Next >
Re: [opensuse] limits.h (was /bin/rm: Argument list too long)
  • From: Wolfgang Woehl <tito@xxxxxxxxxx>
  • Date: Sat, 29 Mar 2008 15:36:53 +0100
  • Message-id: <200803291536.54231.tito@xxxxxxxxxx>
Sam Clemens:
Randall R Schulz wrote:
On Friday 28 March 2008 01:23, Wolfgang Woehl wrote:

Where can I read the argument list size limit? I fail to see
anything relevant with ulimit -a or in proc or in pam's
limits.conf.

% egrep ARG_MAX /usr/include/linux/limits.h
#define ARG_MAX 131072 /* # bytes of args + environ for
exec() */

Aha. Is there a decent method to calculate the size of any given
argv[] and thereby learn whether a process will exceed and fail?

Odd: ulimit -n gives 1024, grep OPEN_MAX limits.h gives 256. Also grep
LINK_MAX limits.h gives 127 but I can create more.

And I believe there's also a maximum size to the number of
pointers in the array char *argv[].

Couldn't find that one ...

Wolfgang
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups