# This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). source /etc/network/interfaces.d/* # The loopback network interface auto lo iface lo inet loopback auto eno1 iface eno1 inet dhcp # USB-ethernet auto usb_eth0 #iface usb0 inet dhcp iface usb_eth0 inet static address 192.168.0.1 netmask 255.255.255.0 broadcast 192.168.0.255 # port forwarding GSI-LAN -> ESR_LAN # # telnet # PowerNode1 - [ESR-LAN: 192.168.0.20:23 - GSI-LAN: atpnuc004:9920] post-up iptables-legacy -t nat -A PREROUTING -i eno1 -p tcp --dport 9920 -j DNAT --to-destination 192.168.0.20:23 post-up iptables-legacy -A FORWARD -p tcp -d 192.168.0.20 --dport 23 -j ACCEPT post-up iptables-legacy -A POSTROUTING -t nat -s 192.168.0.20 -o eno1 -j MASQUERADE # PowerNode2 - [ESR-LAN: 192.168.0.21:23 - GSI-LAN: atpnuc004:9921] post-up iptables-legacy -t nat -A PREROUTING -i eno1 -p tcp --dport 9921 -j DNAT --to-destination 192.168.0.21:23 post-up iptables-legacy -A FORWARD -p tcp -d 192.168.0.21 --dport 23 -j ACCEPT post-up iptables-legacy -A POSTROUTING -t nat -s 192.168.0.21 -o eno1 -j MASQUERADE # PowerNode3 - [ESR-LAN: 192.168.0.22:23 - GSI-LAN: atpnuc004:9922] post-up iptables-legacy -t nat -A PREROUTING -i eno1 -p tcp --dport 9922 -j DNAT --to-destination 192.168.0.22:23 post-up iptables-legacy -A FORWARD -p tcp -d 192.168.0.22 --dport 23 -j ACCEPT post-up iptables-legacy -A POSTROUTING -t nat -s 192.168.0.22 -o eno1 -j MASQUERADE # PowerNode4 - [ESR-LAN: 192.168.0.23:23 - GSI-LAN: atpnuc004:9923] post-up iptables-legacy -t nat -A PREROUTING -i eno1 -p tcp --dport 9923 -j DNAT --to-destination 192.168.0.23:23 post-up iptables-legacy -A FORWARD -p tcp -d 192.168.0.23 --dport 23 -j ACCEPT post-up iptables-legacy -A POSTROUTING -t nat -s 192.168.0.23 -o eno1 -j MASQUERADE