Muilt-home routing question?
Here is what I am tiring to do? I have 2 T1 a and b and there gateways
are say 1.0.0.1/26 and 2.0.0.1/26 and a local network that attach's
several sites together using 10.10.10.1/24 with the rest being
10.10.x.x I started with this and it doesn't work caused all kinds of
problems due to default routes.
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 1.0.0.20
netmask 255.255.255.192
network 1.0.0.0
broadcast 1.0.0.63
gateway 1.0.0.1
auto eth0:1
iface eth0:1 inet static
address 2.0.0.20
netmask 255.255.255.192
network 2.0.0.0
broadcast 2.0.0.63
gateway 2.0.0.1
auto eth1
iface eth1 inet static
address 10.10.10.20
netmask 255.255.255.0
network 10.10.10.0
broadcast 10.10.10.255
gateway 10.10.10.1
I did a good search and found this
http://www.debian-administration.org/articles/377 but it would require 3
Nic's and I couldn't figuire out how to route for the 10.10.x.x
address. I only have 2 Nics in my machines and they are converted sun
boxes I am not sure if I can even get more nics for and don't have a
budget for it right now. I read the attached how-to but I can't figure
out how to convert what is in the how-to in to a debian config. I tried
this but it didn't work.
# The primary network interface
auto eth0
iface eth0 inet static
address 1.0.0.20
netmask 255.255.255.192
post-up ip route add 1.0.0.1/26 dev eth0 src 1.0.0.20 table uplink1
post-up ip route add default via 1.0.0.1 table uplink1
post-up ip rule add from 1.0.0.20 table uplink1
post-down ip rule del from 1.0.0.20 table uplink1
#Uplink2
auto eth0:1
iface eth0:1 inet static
address 2.0.0.20
netmask 255.255.255.192
post-up ip route add 2.0.0.1/26 dev eth0:1 src 2.0.0.20 table uplink2
post-up ip route add default via 2.0.0.1 table uplink2
post-up ip rule add from 2.0.0.20 table uplink2
post-down ip rule del from 2.0.0.20 table uplink2
That didn't work I am not sure how to change the settings to make this
work any idea's or how-to that I have missed that you can think of to help.
Thanks
Robert
Reply to: