View previous topic :: View next topic |
Author |
Message |
lazx888 Tux's lil' helper

Joined: 13 Sep 2005 Posts: 118
|
Posted: Mon Jan 16, 2006 6:35 pm Post subject: Dual Internet and Application Routing |
|
|
I have 2 internet connections through eth0 and eth1. I was wondering how I would go about having certain applications traffic going strictly through eth1 and all other traffic going over eth0?
Thanks |
|
Back to top |
|
 |
adaptr Watchman


Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Mon Jan 16, 2006 7:13 pm Post subject: |
|
|
iptables can do that easily, with rules like "for proto tcp port 80, goto eth0; for proto udp port 53, goto eth1".
Outgoing as well, if you like. _________________ >>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen |
|
Back to top |
|
 |
lazx888 Tux's lil' helper

Joined: 13 Sep 2005 Posts: 118
|
Posted: Mon Jan 16, 2006 7:43 pm Post subject: |
|
|
what if the listening ports change? I essentially want a proxy server like application... I am not sure if iptables can do this, but if it can, that would be great... I really don't want to install a server for this use |
|
Back to top |
|
 |
adaptr Watchman


Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Mon Jan 16, 2006 7:49 pm Post subject: |
|
|
I have no idea what you mean - "listening ports change" ? Change why ? For what ?
The idea is that port numbers never ever change.
You would not be able to do anything useful on the Internet if they did. _________________ >>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen |
|
Back to top |
|
 |
lazx888 Tux's lil' helper

Joined: 13 Sep 2005 Posts: 118
|
Posted: Tue Jan 17, 2006 3:30 am Post subject: |
|
|
for example, ssh... lets say I am trying to ssh into a couple servers, server 1 is listening on port 22, server 2 on port 23 and so on... I want my ssh client to only use eth1 while the rest of my traffic goes over eth0
is that more clear now? |
|
Back to top |
|
 |
adaptr Watchman


Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Tue Jan 17, 2006 7:48 pm Post subject: |
|
|
Not at all - from where do you want to reach those ssh servers ?
If you're on the same network, or on any routable network, why would you want to change the ports ?
If you mean you want to reach them from the outside, you'll have to set up some way to route to the appropriate interface first - load balancing is not possible (at least, you can't do it.)
You could set up a dyndns / no-ip domain with different hostnames for the interfaces.
Beyond that, there's not much you can do from home. _________________ >>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen |
|
Back to top |
|
 |
lazx888 Tux's lil' helper

Joined: 13 Sep 2005 Posts: 118
|
Posted: Tue Jan 17, 2006 9:55 pm Post subject: |
|
|
All I want to be able to do is essentially load balancing... but I want it to be application based (port independent).
Sorry if this is not making sense, haven't done much networking |
|
Back to top |
|
 |
adaptr Watchman


Joined: 06 Oct 2002 Posts: 6730 Location: Rotterdam, Netherlands
|
Posted: Thu Jan 19, 2006 8:28 pm Post subject: |
|
|
You can distribute different apllications over different connections for a kind of manual load balancing.
You'd have to set up proper DNS entries for this to work from the outside.
True load balancing can only be attained when your ISP supports line bonding - and if they're two different ISPs, just plain forget about it.
So yes, it should be simple to do what you asked. _________________ >>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen |
|
Back to top |
|
 |
|