procmail
[Top] [All Lists]

Re: Coredump on large emails (SOLUTION!)

2001-12-16 18:42:44
Hi,

        At the beginning of the month I complained of procmail v3.22
core dumping when a huge email (8 or so M) was received.  A few people
chipped in, but it was "Gary Funck" that kept after it and finally
cracked it.

        The initial problem was thought to be a file limit size. He
suggested using "http://sourceforge.net/projects/ctk-ulimitw/";.  After
first getting over the hurdle that it didn't compile in BSD/OS (Remove
the ulimit.h include, and :

#ifndef LOG_PERROR
#define LOG_PERROR LOG_ERR
#endif

#define UL_GETFSIZE   1       /* get file limit */
#define UL_SETFSIZE   2       /* set file limit */


        Nope, not it as "limit" showed.

        Turns out that the BSD/OS login.conf was limiting the "datasize".
Gary hacked the program, adding :

#define UL_GETDSIZE   8       /* get data segment size */
#define UL_SETDSIZE   9       /* set data segment size */


        and :

   if (ulimit(UL_SETFSIZE, ulimit_arg << ULIMIT_UNIT_SHIFT) == -1) {

                to

   if (ulimit(UL_SETDSIZE, ulimit_arg << ULIMIT_UNIT_SHIFT) == -1) {


        and finally :

   syslog(LOG_INFO, "UL_SETFSIZE for %s to %d" ULIMIT_UNIT_NAME, nav[0], 
ulimit_arg);

                to

   syslog(LOG_INFO, "data size for %s to %d" ULIMIT_UNIT_NAME, nav[0], 
ulimit_arg);

        once this was done, and the invocation changed to :

|IFS=''&&p=/usr/local/bin/procmail&&test -f 
$p&&ulim=/usr/local/bin/ulimitw&&test -f $ulim&&exec  $ulim --ulimit 64 --exec 
$p --av0 $p -Yf-||exit 75 #YOUR_USERNAME

        Thank you to Gary and all others that helped. We now have not had it
die since.

                Tuc/TTSG Internet Services, Inc.
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>
  • Re: Coredump on large emails (SOLUTION!), Tuc <=