LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Using multiple IP addresses from client side (https://www.linuxquestions.org/questions/linux-networking-3/using-multiple-ip-addresses-from-client-side-271880/)

dhoro 12-30-2004 08:20 AM

Using multiple IP addresses from client side
 
Hi everybody!

What I want to do is basically use multiple IP addresses and a single outgoing internet connection. I already setup more subinterfaces (i.e. eth0:1, eth0:2, eth0:3 and so on) on a single physical interface (eth0). My question: is how should I set the routs so that when a connection is initiated from my linux box, the kernel will round-robin go through all the subinterfaces, each time assigning a new source IP address for the outgoing packet.

If I'm not being very clear here, what I want to do:
1. I initiate, let's say, an FTP connection
2. The kernel routes the SYN packet through eth0:1
3 I initiate an HTTP connection
4. The kernel routes the second SYN packet through eth0:2
And so on and so forth.

I think a way to accomplish this is to setup a SNAT between two subinterfaces, specifind more than one --to-source parameters to iptables. But that's not to elegant... :)

Thanks!
Dan


All times are GMT -5. The time now is 07:04 AM.