Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ip tunnel add gre1 mode gre local S1-ip remote main-ip ttl 255
- ip addr add 192.168.10.1/30 dev gre1
- ip link set gre1 up
- ip tunnel add gre2 mode gre local S2-ip remote main-ip ttl 255
- ip addr add 192.168.168.1/24 dev gre2
- ip link set gre2 up
- ip tunnel add gre1 mode gre local main-ip remote S1-ip ttl 255
- ip addr add 192.168.10.2/30 dev gre1
- ip link set gre1 up
- ip tunnel add gre2 mode gre local main-ip remote S2-ip ttl 255
- ip addr add 192.168.168.2/30 dev gre2
- ip link set gre2 up
- echo 200 grea >> /etc/iproute2/rt_tables
- echo 201 greb >> /etc/iproute2/rt_tables
- ip rule add from 192.168.10.0/30 table grea
- ip rule add from 192.168.168.0/30 table greb
- ip route add default via 192.168.10.1 table gre1
- ip route add default via 192.168.168.1 table gre2
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement