Re: [exim] On queue run prefer small messages first, how?

Inizio della pagina
Delete this message
Reply to this message
Autore: Philip Hazel
Data:  
To: jori.hamalainen
CC: exim-users
Oggetto: Re: [exim] On queue run prefer small messages first, how?
On Tue, 27 Sep 2005 jori.hamalainen@??? wrote:

> I want something like:
>
> if queue runner and retransmit time triggered then
> if message_size < 3k then deliver
> else wait until < 3k messages have been delivered, then start
> delivering big messages


This cannot be done by Exim, since it does not process messages by size.

> I realize that I can make a router for small messages which says defer
> on big messages, but how I can stop deferring when there is only big
> messages left on queue?


You might be able to hack up something external like this:

1. Use a MACRO in your configuration to specify the maximum size:

MAXSIZE=3K

2. Add a router to defer for any message greater than MAXSIZE.

3. Start queue runners manually, using -D to change MAXSIZE. You will
have to be root to do this. The sequence

exim -q
exim -q -DMAXSIZE=10M

should then achieve approximately what you want. It can only be
approximate - after all, new messages <3k can arrive at any time, and
such an arrival won't stop the second queue runner.

Untested, just an idea that I had.

Unless your large messages are really huge, however, I don't really see
the point of this. 3K is, after all, just 2 packets.


-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book