본문 바로가기
HPC/RHEL7

iptable nat outgoing

by mirhenge 2018. 7. 1.

IP NAT

[root@mgt31 ~]#vi /etc/sysctl.conf 로 net.ipv4.ip_forward = 1 로 변경
[root@mgt31 ~]#iptables -t nat -A POSTROUTING -o eno2 -j MASQUERADE
[root@mgt31 ~]# iptables -t nat -A POSTROUTING -s 172.20.10.16 -o eno5 -j SNAT --to 192.168.50.166

172.20.10.16 서버의 Gateway 를 "192.168.50.166" 의 172.20.10.1 로 설정후 DNS 서버 설정


NAT Forward Ingoing

iptables -t nat -A PREROUTING -p tcp -m tcp --dport 16001 -j DNAT --to-destination 10.10.10.199:3389

'HPC > RHEL7' 카테고리의 다른 글

Ubuntu 14 server 설치 후 Desktop 설치  (0) 2019.10.07
SAP HANA resource 넘어가는 순서  (0) 2019.01.21
SAP HANA system replication in pacemaker cluster  (0) 2019.01.21
Redhat 용어 정리  (0) 2018.05.18
멜트다운,스텍터  (0) 2018.05.18