On Sun, 2010-01-31 at 12:51 -0600, JW Simpson wrote:
On Sun, 2010-01-31 at 12:31 -0600, JW Simpson wrote:
On Sun, 2010-01-31 at 15:40 +0100, Michelle Konzack wrote:
Hello,
...
procmail: Executing " test -z "${TMPVAR5}""
procmail: Failed to execute ""
procmail: Non-zero exitcode (69) from " test -z "${TMPVAR5}""
Some more info:
http://www.unix.com/unix-advanced-expert-users/15577-arg-list-too-long.html
says:
The system could not handle the number of arguments given to a
command or program when it combined those arguments with the
environment's exported shell variables. The argument list limit
is the size of the argument list plus the size of the
environment's exported shell variables.
The easiest solution is to reduce the size of the parent process
environment by unsetting extraneous environment variables. (See
the man page for the shell you're using to find out how to list
and change your environment variables.) Then run the program
again.
An argument list longer than ARG_MAX bytes was presented to a
member of the exec() family of system calls.
The symbolic name for this error is E2BIG, errno=7.
... and ...
Check out the xargs command. Can you post the command that is failing?
Following up on that, I get this:
john(_at_)system76-pc:~/kon$ SIZE=127;export BIGVAR=`seq -ws '' 1
1000000 | dd count=$SIZE bs=1K`;test -z "${BIGVAR}"; echo /bin/sh -c 'test -z
"${BIGVAR}"; echo $?' | xargs --show-limits
127+0 records in
127+0 records out
130048 bytes (130 kB) copied, 0.0055172 s, 23.6 MB/s
Your environment variables take up 132526 bytes
POSIX upper limit on argument length (this system): 1962578
POSIX smallest allowable upper limit on argument length (all
systems): 4096
Maximum length of command we could actually use: 1830052
Size of command buffer we are actually using: 131072
/bin/sh -c test -z ${BIGVAR}; echo $?
Calling xargs from procmail gives me this:
john(_at_)system76-pc:~/kon$ cat kon.rc
SHELL='/bin/sh'
NL='
'
LINEBUF=654321
# 127 works; 128 fails
SIZE=127
LOG="SIZE=${SIZE} kB${NL}"
BIGVAR=`seq -ws '' 1 100000 | dd count=$SIZE bs=1K`
VERBOSE=yes
LOG=`xargs --show-limits test -z "${BIGVAR}"`
:0
* ? test -z "${BIGVAR}"
{
LOG=matched
}
VERBOSE=no
:0
|
john(_at_)system76-pc:~/kon$ :|procmail -m kon.rc
SIZE=127 kB
127+0 records in
127+0 records out
130048 bytes (130 kB) copied, 0.00661226 s, 19.7 MB/s
procmail: [16986] Sun Jan 31 12:58:54 2010
procmail: Executing "xargs,--show-limits,test,-z,000001 <snip> 0216740216"
Your environment variables take up 130398 bytes
POSIX upper limit on argument length (this system): 1964706
POSIX smallest allowable upper limit on argument length (all systems): 4096
Maximum length of command we could actually use: 1834308
Size of command buffer we are actually using: 131072
procmail: [16986] Sun Jan 31 12:58:54 2010
procmail: Assigning "LOG="
procmail: Executing " test -z "${BIGVAR}""
procmail: Non-zero exitcode (1) from " test -z "${BIGVAR}""
john(_at_)system76-pc:~/kon$ :|procmail -m kon.rc
SIZE=128 kB
128+0 records in
128+0 records out
131072 bytes (131 kB) copied, 0.02596 s, 5.0 MB/s
procmail: [17001] Sun Jan 31 13:00:38 2010
procmail: Executing "xargs,--show-limits,test,-z,000001 <snip> 02184502"
procmail: [17001] Sun Jan 31 13:00:39 2010
procmail: Failed to execute "PROCMAIL_VERSION=3.22"
procmail: [17001] Sun Jan 31 13:00:39 2010
procmail: Assigning "LOG="
procmail: Executing " test -z "${BIGVAR}""
procmail: Failed to execute " test -z "${BIGVAR}""
procmail: Non-zero exitcode (69) from " test -z "${BIGVAR}""
Personally, I think you would do better by revising your code to use less
environment space.
--
JW Simpson <john(_at_)swajime(_dot_)com>
SwaJime's Cove℠
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)de
http://mailman.rwth-aachen.de/mailman/listinfo/procmail