[clug] Routing to a different outgoing interface based on hostname
Tony Lewis
tony at lewistribe.com
Wed Jun 14 07:08:20 UTC 2017
I might be getting a fast wireless ISP to either complement or replace
my slow ADSL2. If I'm going to use them to complement each other I
would like to be able to route traffic based on the type of traffic.
Easy enough to do for different protocols, but I'd like to route, say,
all Windows and iOS updates (over HTTPS) over the unlimited, slow ADSL,
but allow traffic going to the user (YouTube, general browsing, Skype)
to go over the faster interface.
How might I do this robustly?
The best I can think of is to have some process where I try and discover
all the hostnames used for updates, and then interrogate DNS regularly
to turn them into IPv4 addresses, and feed them into iptables. It
sounds fraught with gradual degradation as servers are reprovisioned
(hostnames change), but also to major degradation if some parsing code
goes wrong.
The second best is sort of time-of-day. Redirect all after-hours
traffic to the unlimited ADSL2, and hope that most updates are smart
enough to pick an out-of-hours time to update.
Any other suggestions?
Tony
More information about the linux
mailing list