https://bz.apache.org/SpamAssassin/show_bug.cgi?id=8253
Bug ID: 8253
Summary: t/spamd_client.t failure on low memory machines
Product: Spamassassin
Version: SVN Trunk (Latest Devel Version)
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Regression Tests
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: Undefined
There are a number of test failures of t/spamd_client.t showing up on CPAN
linux/unix test machines. with the symptom being the test failing after ok 4
with a "error reading from spamd (10): Connection reset by peer" message.
I have been able to reproduce the error by running on a VM with limited
resources, specifically 1000MB RAM and 1 core. Increasing either the RAM to
2000MB or giving the VM another core makes the failure go away.
Digging into it, it seems that a child process of spamd runs out of memory. If
the OOM process catches and kills the process before perl gets an out of memory
trap, then the t/spamd_client.t test still succeeds. What happens most of the
time is that perl traps while the client is waiting for a tcp response which
times out, resulting in "connection reset by peer".
I found that if in t/spamd_cient.t I move the start_spamd calls to after the
creation of a new client_obj, but before the client_obj is used to call spamd,
the failure goes away unless I reduce the memory to barely over the threshold
where the machine can't boot.
That's an empirical fix, but it does make gratuitous test failures disappear.
I'm going to make that change to the test, and also add a message at the start
of the test that 'Connection reset by peer' failure may be symptomatic of low
memory on the test machine.
--
You are receiving this mail because:
You are the assignee for the bug.