Differences

This shows you the differences between two versions of the page.

Link to this comparison view

en:ressources:astuces:policy_routing [2013/12/07 16:45] (current)
Line 1: Line 1:
 +====== Linux Policy Routing ======
  
 +Create a custom routing table
 +
 +<​code>​
 +echo 200 custom >> /​etc/​iproute2/​rt_tables
 +</​code>​
 +
 +Route a source IP using the custom table
 +
 +<​code>​
 +ip rule add from 172.21.4.156 lookup custom
 +</​code>​
 +
 +Add a rule to the table that change the default gateway to a VPN
 +
 +<​code>​
 +ip route add default via 172.27.0.9 dev tun0 table custom
 +</​code>​
en/ressources/astuces/policy_routing.txt ยท Last modified: 2013/12/07 16:45 (external edit)
CC Attribution-Share Alike 4.0 International
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0