Advertisement
xXxSPYxXx

Untitled

Mar 31st, 2020
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.65 KB | None | 0 0
  1. root@:~# cat /etc/network/interfaces
  2. auto lo
  3. iface lo inet loopback
  4.  
  5. auto eno1
  6. iface eno1 inet dhcp
  7. #iface eno1 inet dhcp
  8.  
  9. iface eno2 inet manual
  10.  
  11. #auto vmbr0
  12. #iface vmbr0 inet dhcp
  13. #       bridge-ports eno1
  14. #       bridge-stp off
  15. #       bridge-fd 0
  16.  
  17. auto vmbr1
  18. iface vmbr1 inet static
  19.         address 10.0.0.1
  20.         netmask  255.255.255.0
  21.         bridge-ports none
  22.         bridge-stp off
  23.         bridge-fd 0
  24.  
  25.         post-up echo 1 > /proc/sys/net/ipv4/ip_forward
  26.         post-up iptables -t nat -A POSTROUTING -s 10.0.0.0/24 -o eno1 -j MASQUERADE
  27.         post-down iptables -t nat -D POSTROUTING -s 10.0.0.0/24 -o eno1 -j MASQUERADE
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement