Reply To: country ip classes to routing table

Home Page Forums Network Management Networking country ip classes to routing table Reply To: country ip classes to routing table

#49722

deejayq
Member

i have the following configuration


________
/
/
+
+ /
| | /
+
+
+ +
+
+ /
+
+ | vlan1 | | vlan1 | /
| | | | | | |
| Local networks +----+ Zeroshell | | ISP +--+ Internet cloud
| | | | | | |
+
+ | vlan2 | | vlan2 |
+
+
+ +
+
+
| |
+
+

________

on vlan1 is routed the traffic to romania
on vlan2 is routed all the other traffic
i use freebsd and i want to use zeroshell
i don’t know how to push the traffic to romanian ip’s thru vlan1

do you think that by using the following example will work?

echo 1 romania >> /etc/iproute2/rt_tables
ip route add default via x.x.x.x dev vlan1 table romania

ip rule add from a.a.a.a/24 table romania
ip rule add from b.b.b.b/24 table romania
...

where x.x.x.x is the gateway from my provider and a.a.a.a/24, b.b.b.b/24 etc are the ip classes from romania

thank you