Sebagai contoh :-
eth0 | 192.168.10.1255.255.255.0 | |
eth1 | 192.168.10.2255.255.255.0 | |
eth2 | 192.168.10.3255.255.255.0 | |
eth3 | 192.168.10.4255.255.255.0 |
/proc/sys/net/ipv4/conf/(eth0 || eth1)/arp_filter change the value to a 1 instead of 0.
ip route del default
route add default gw 192.168.1.1 dev eth1
route add default gw 192.168.1.1 dev eth0
ip route add 192.168.1.0/24 dev eth0 table 2
ip route add 0/0 via 192.168.1.1 dev eth0 table 2
ip rule add from 192.168.1.123 table 2
ip rule add to 192.168.1.123 table 2
ip route add 192.168.1.0/24 dev eth1 table 3
ip route add 0/0 via 192.168.1.1 dev eth1 table 3
ip rule add from 192.168.1.121 table 3
ip rule add to 192.168.1.121 table 3
echo 1 > /proc/sys/net/ipv4/conf/eth0/arp_filter
echo 1 > /proc/sys/net/ipv4/conf/eth1/arp_filter
No comments:
Post a Comment