New to the list, but not new to computers. Been running qmail for almost a decade, spamassassin for about 1 year, but I seem to have hit a stumper...
My setup:
Was running spamassassin 2.55, upgraded to 2.6 (just in case); in daemon mode, "several different versions" of ifspamh [1], qmail 1.03 with minimal patches configged via LifeWithqmail, bash 2.05b /and/ pdksh 5.2.14, and no matter what, spamassassin/ifspamh is barfing badly on very large messages; which of course is causing qmail to defer delivery.
I have hacked ifspamh 72 ways from sunday trying to keep it's resources within check, and nothing seems to help. Until I started hacking about in ifspamh, spamc was dying with an "Error # 100" (I modified ifspamh to log spamc's error code when it started happening) and no matter what I did, I was getting this under bash:
deferral: /usr/local/bin/ifspamh:_xrealloc:_subst.c:468:_cannot_reallocate_1331584_bytes_(0_bytes_allocated)//usr/local/bin/ifspamh:_xrealloc:_subst.c:468:_cannot_reallocate_1331584_bytes_(0_bytes_allocated)//usr/local/bin/ifspamh:_xrealloc:_subst.c:468:_cannot_reallocate_1331584_bytes_(0_bytes_allocated)/spamc_returned_temporary_failure_#_100/
So, I set up ksh (thinking it's much smaller size and possibly a memory leak in bash was causing the problem) and I started getting this:
deferral: /usr/local/bin/ifspamh[71]:_internal_error:_alloc:_cannot_re-allocate/Out_of_memory!/
And amongst other things, I realized if-construct bashisms don't grok well under ksh, so I totally changed the script to totally support ksh -- no help. No matter what, ifspamh was barfing on this piece of code:
=-=-=-=-=-=-=-=-=-=-=
# we used to skip 'From ' - the 1st line that got added by spamd/spamc # but it seems newer versions don't add it (and SA 2.50 adds a 3 line # Received header) output="`$SPAMC | sed '1{/^From .*/d;}'`"
#^^^^^^^^^^^^^^^^ On this code ^^^^^^^^^^^^^^^^^^
exitcode=$?
# spamc will not process a "large email" msize=`echo "$output" | wc -c` # there's also a sizelimit with some shells that triggers around the 512kB mark # with an external printf and arguments size so we stop at this point if [ $msize -gt 250000 ]; then # probably deemed too large anyway .. let it through exit 0 fi
=-=-=-=-=-=-=-=-=-=-=
leading me to believe that bash/ksh just didn't have enough memory left to process a 5Meg file even before it found out it was a 5 meg file, so I changed the code to this:
=-=-=-=-=-=-=-=-=-=-=
# we used to skip 'From ' - the 1st line that got added by spamd/spamc # but it seems newer versions don't add it (and SA 2.50 adds a 3 line # Received header)
tempout=`head --bytes=50000 -`
# spamc will not process a "large email" msize=`echo "$tempout"|wc -c`
## [[[ the spamcheck would come later down the line, it wasn't ## even getting that far, so I didn't include it... ]]]
=-=-=-=-=-=-=-=-=-=-=
so "tempout" would never go over 50,000 bytes and never try to "count" the entire 5Meg file and take 5Meg of memory...
... and now this is what I get in the logs [WRT that file:]:
2003-09-29 18:18:39.525352500 delivery 7345: deferral:
And that's it. No status, no error, no nuthin!!!
All I can think of is this: Is there any type of ulimits that spamc/spamd has that I might not be able to find as of yet? I've upped the qmail memory limits from 6Meg to 22Meg (per instance, of course) to no effect - I'm not sure where this thing's running out of resources...
5 days worth of Google, searched every archive I can find, and all I've gotten so far are a few poor souls in the same prediciment as me... :-(
Thanks for anything anyone can shed...
Roger "Merch" Merchberger
[1] Was running ifspamh 1.5 happily until recently, I found 2-3 other versions of 1.5 to no avail, a "seems to be unsupported" version 1.6 (which didn't work well at all), and 1.4 isn't compatible with SA 2.5x/2.6... Is there a C version of it floating around somewhere? I could hack up a perl and/or python version of it, but I doubt that would help my resources much more than a 163K ksh shell...
-- Roger "Merch" Merchberger --- sysadmin, Iceberg Computers [EMAIL PROTECTED]
Hi! I am a .signature virus. Copy me into your .signature to join in!
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Spamassassin-talk mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/spamassassin-talk