Multiple Source IP Addresses

Dennis O. Aliev doa at einsteinindustries.com
Fri Mar 11 21:37:31 CET 2005


Jason,

This is a great solution, but it has 1 limitation. There would be no way for webserver to track how many requests went through each external IP. Would you have any further suggestions?

Thanks a lot.

Dennis O. Aliev


On Fri, 11 Mar 2005 14:49:51 -0500
Jason Opperisano <opie at 817west.com> wrote:

> On Fri, 2005-03-11 at 14:40, Dennis O. Aliev wrote:
> > Baake,
> > 
> > Thank you for reply.
> > 
> > What you suggesting will take care of routing incomming packets (from internet) to web server. In my scenario, I have a bot that parses sites and so the packets are coming from webserver to internet and source addresses must be different to load balance between internet connections.
> 
> use multiple "--to-source" options in your SNAT rule:
> 
>   iptables -t nat -A POSTROUTING -o $EXT_IF -s $WEB_SRV_IP \
>     -j SNAT --to-source $EXTIP1 --to-source $EXTIP2  --to-source $EXTIP3
> 
> outbound connections will round-robin between the source addresses.
> 
> -j
> 
> --
> "Alright brain, you don't like me and I don't like you. But let's just
>  get through this and then I can get back to killing you with beer."
> 	--The Simpsons
> 



More information about the netfilter mailing list