Re: [Exim] Exim in a malloc() loop?

Etusivu
Poista viesti
Vastaa
Lähettäjä: Philip Hazel
Päiväys:  
Vastaanottaja: Mark Morley
Kopio: exim-users
Aihe: Re: [Exim] Exim in a malloc() loop?
On Thu, 20 Dec 2001, Mark Morley wrote:

> Over the last month I've noticed several occasions where an Exim queue
> runner process will get stuck on a message and start allocating memory
> until it finally dies with the following error:
>
>    2001-12-20 16:39:02 16HC3r-000Jal-00 failed to malloc 33008 bytes of
>                        memory: called from line 136 of store.c

>
> The machine has half a gig of RAM, which under normal circumstances
> is mostly unused, until one of these problem messages comes along.


What happens later? Does the message get delivered eventually? If you've
got such a message stuck on your queue, try running

exim -d9 -M <message-id>

on it, and see if the debugging output shows anything helpful. Send it
to me if you like.

> The messages themselves are from various senders, but they are all (so
> far) destined for local users. The only thing they seem to have in
> common is a large number of "Apparently-To:" headers. This latest
> one had over 1,600 of them. Other than that, the messages appear
> normal and are not very big at all.


Exim does hold all the header lines in main memory, but when it receives
a message it applies a limit (default 1MB) to the amount of memory it is
prepared to use for a message's headers. Anyway, assuming a generous
line length of 100 characters means that 1,600 headers still only use up
160,000 bytes.

Have you got a system filter? Are you making any reference to
$message_headers in it?


--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.