From: "Roy" <roy@xxx.lt>
To: lartc@vger.kernel.org
Subject: Re: [LARTC] email/ftp over one connection, all else over second connection
Date: Tue, 09 Mar 2004 02:33:51 +0000 [thread overview]
Message-ID: <002e01c4057e$f5d435c0$030aa8c0@t> (raw)
In-Reply-To: <000b01c404c3$7f8a2430$fa01a8c0@unwired>
This is quite easy to do with IPTables ROUTE,
I suppose you are using nat anyway
you will need to nat to source at first ( at prerouting)
then ROUTE to approriate gw
basicaly there is no much diference how do you route packets
you can just ignore routing at all, and direct everything to default
gateway,
but receive from anywhere. all you need is to to nat to approriate source at
first
example:
iptables -t nat -A POSTROUTING --dport 110 -j SNAT --to-source 81.x.x.x
iptables -t nat-A POSTROUTING ! -d 192.168.0.0/255.255.0.0 -j
SNAT --to-source 62.x.x.x
this will direct all port 110 trafic to to be received on 81.x.x.x
and everything else on 62.x.x.x
if you want all port 110 trafic to GO TO 81.x.x.x then use route target
iptables -t mangle -A POSTROUTING --dport 110 -j ROUTE --gw
81.x.x.x --continue
everything else goes to default gw
usualy it is best to se both rules, but they can be used independently you
dont need packets to go through the same gateway in both directions.
any other very advanced configuartins are possible,
I am using similar setup to direct web trafic to one dsl and other trafic to
another
iptables condition module helps to switch links if one is detected dead.
seems iproute is not needed anymore ;-)
iptables does routing much better.(but proabbly slower)
----- Original Message -----
From: "Bryan Nolen" <reveng@arc.net.au>
To: <lartc@mailman.ds9a.nl>
Sent: Monday, March 08, 2004 6:11 AM
Subject: [LARTC] email/ftp over one connection, all else over second
connection
Hi all,
Just wondering what the easiest way to do the following is:
We have two connections (routed ADSL) - a 512k/512k symmetrical and a
1.5M/256k asymmetrical, what I would like is for all email and FTP traffic
to use the symmetrical link, and all other internet traffic to use the
asymmetrical link. The symmetrical link is already set as the primary MX, so
source routing problems aside - how can this be done?
Using IPTables ROUTE target? using IPRoute2 (ideally)?
The reasons for doing it this way is this company needs a reliable email and
ftp channel, but they also do a lot of '"'surfing'"' so I would like the
isolate
the two distinct traffic types in order to optimise traffic flow.
All help is welcome.
-Bryan
Bryan Nolen
Lead Developer, Arc.Net.Au
Ph: 03 9499 2929
Fax: 03 9854 5436
Mobile: 0402 022 292
Email: bryan@arcnet.com.au or reveng@arc.net.au
http://Arc.Net.AU
http://cdonline.com.au
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
prev parent reply other threads:[~2004-03-09 2:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-08 4:11 [LARTC] email/ftp over one connection, all else over second connection Bryan Nolen
2004-03-08 4:40 ` Bryan Nolen
2004-03-09 2:33 ` Roy [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='002e01c4057e$f5d435c0$030aa8c0@t' \
--to=roy@xxx.lt \
--cc=lartc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.