Re: [exim] Round-robin dnslists?

Top Page
Delete this message
Reply to this message
Author: Mike Cardwell
Date:  
To: Exim users
Subject: Re: [exim] Round-robin dnslists?
John Horne wrote:

> Anyone know if it is possible to configure the 'dnslists' condition in a
> round-robin order? I want to check to see if a sending host is listed on
> one of two RBL's, but don't necessarily want all the checks to go to the
> first listed RBL:
>
>        dnslists = rbl-a : rbl-b

>
> I would rather it alternated between the two, rather than testing
> 'rbl-a' all the time. Similar to the 'hosts_randomize' transport
> statement.


dnslists = ${if eq{${eval:$tod_epoch%2}}{1}{rbl-a:rbl-b}{rbl-b:rbl-a}}

In the above example, the order depends on whether or not the number of
seconds since the epoch is odd or even. Would that be sufficient?

--
Mike Cardwell - IT Consultant and LAMP developer
Cardwell IT Ltd. (UK Reg'd Company #06920226) http://cardwellit.com/