apt-get install iptables-persistent After that, run next commands every time you want save iptables changes permanently:netfilter-persistent savenetfilter-persistent reload
Continue reading...iptables
Iptables forwarding
root@sklepas:~# sysctl net.ipv4.ip_forward=1 root@sklepas:~# iptables -A PREROUTING -t nat -i eth0 -p udp –dport 27102 -j DNAT –to 107.161.126.115:27106 root@sklepas:~# iptables -A PREROUTING -t nat -i eth0 -p tcp –dport 27102 -j DNAT –to 107.161.126.115:27106 root@sklepas:~# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
Continue reading...Iptables flush
iptables -F iptables -X iptables -t nat -F iptables -t nat -X iptables -t mangle -F iptables -t mangle -X iptables -P INPUT ACCEPT iptables -P FORWARD ACCEPT iptables -P OUTPUT ACCEPT
Continue reading...
Recent Comments