Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: SpamAssassin: devel

[Bug 6745] spamd crashes because of memory problems in Logger.pm

 

 

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded


bugzilla-daemon at bugzilla

Mar 20, 2012, 6:07 AM

Post #1 of 7 (392 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

Stephen M <spambox [at] slashorg> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |spambox [at] slashorg

--- Comment #7 from Stephen M <spambox [at] slashorg> 2012-03-20 13:07:15 UTC ---
Hello,

I've had the same problem last night, SA crashed with the following error:

Mar 19 23:53:06 shapai spamd[67540]: Out of memory during ridiculously large
request at /usr/local/lib/perl5/site_perl/5.14.2/Mail/SpamAssassin/Logger.pm
line 239.

My maillog contains the following:

Mar 19 23:53:06 shapai postfix/local[86791]: 390F211551:
to=<sysmail [at] xxxxxxxxx>, orig_to=<root [at] xxxxxxxxx>, relay=local,
delay=16, delays=0.36/0.01/0/15, dsn=2.0.0, status=sent (delivered to command:
/usr/local/bin/procmail)
Mar 19 23:53:06 shapai postfix/qmgr[72002]: 390F211551: removed
Mar 19 23:53:06 shapai spamd[67540]: prefork: child states: III
Mar 19 23:53:06 shapai spamd[67540]: prefork: adjust: 3 idle children more than
2 maximum idle children. Decreasing spamd children: 86809 killed.
Mar 19 23:53:06 shapai spamd[67540]: spamd: handled cleanup of child pid
[86809] due to SIGCHLD: interrupted, signal 2 (0002)
Mar 19 23:53:06 shapai spamd[67540]: Out of memory during ridiculously large
request at /usr/local/lib/perl5/site_perl/5.14.2/Mail/SpamAssassin/Logger.pm
line 239.

I'm using 6.4-RELEASE-p7 on a i386 CPU with perl-5.14.2_2. All ports are up to
date.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Mar 20, 2012, 6:18 AM

Post #2 of 7 (364 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

--- Comment #8 from Kevin A. McGrail <kmcgrail [at] pccc> 2012-03-20 13:18:47 UTC ---
Not discounting the issue but with a failure to reproduce and no email that
appears to cause the issue, there is very little we can do.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Mar 27, 2012, 4:23 PM

Post #3 of 7 (346 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

Mark Martinec <Mark.Martinec [at] ijs> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|WORKSFORME |

--- Comment #9 from Mark Martinec <Mark.Martinec [at] ijs> 2012-03-27 23:23:44 UTC ---
What is common between both submitted logs is that the error occurs in
a *parent* spamd process immediately after a child process termination
which terminated due to SIGINT:

spamd: handled cleanup of child pid [39936] due to SIGCHLD: interrupted, signal
2

The log message is produced by a sub child_handler, which is a signal
handling routine:
$SIG{CHLD} = \&child_handler;

Perl docs warn against doing complex processing while handling a signal,
it is considered good practice to just set a flag in a pre-allocated
variable and leave the rest to the main program flow.

It does not surprise me that an error like "Out of memory" can occur
in such a scenario. What I don't know how to better handle the situation.
Perhaps just commenting out the call to info() in child_handler would
suffice.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 5, 2012, 2:10 PM

Post #4 of 7 (344 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

Julian Yap <julianokyap [at] gmail> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |julianokyap [at] gmail

--- Comment #10 from Julian Yap <julianokyap [at] gmail> 2012-04-05 21:10:12 UTC ---
This issue started occurring for me when I upgraded from to Perl 5.14.2
(running latest perl-5.14.2_2).

Issue does NOT occur on perl-5.10.1_6.

Exact same error message:
Out of memory during ridiculously large request at
/usr/local/lib/perl5/site_perl/5.14.2/Mail/SpamAssassin/Logger.pm line 239.

I'm running FreeBSD 8.2-RELEASE.

I'm going to downgrade to Perl 5.10.1 now because this issue is killing me.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 10, 2012, 3:50 PM

Post #5 of 7 (338 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

Michael Scheidell <scheidell [at] secnap> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |scheidell [at] secnap

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 15, 2012, 8:34 PM

Post #6 of 7 (327 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

Kevin Fenzi <kevin [at] scrye> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |kevin [at] scrye

--- Comment #11 from Kevin Fenzi <kevin [at] scrye> 2012-04-16 03:34:11 UTC ---
We are seeing this in Fedora now as well...

https://bugzilla.redhat.com/show_bug.cgi?id=812359

Fedora 16 also has perl-5.14.2

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Apr 23, 2012, 5:40 PM

Post #7 of 7 (324 views)
Permalink
[Bug 6745] spamd crashes because of memory problems in Logger.pm [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6745

--- Comment #12 from Mark Martinec <Mark.Martinec [at] ijs> 2012-04-24 00:40:25 UTC ---
Created attachment 5052
--> https://issues.apache.org/SpamAssassin/attachment.cgi?id=5052
Avoid logging and any complex operations in a sigchld handler

Would something like the attached patch still do the job
while avoiding the problem?

(My brief testing under perl 5.14.2 looks alright even when prefork
is adjusting the number of child processes, but I'm not running spamd
in production, so more stress testing is appreciated).

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.