natcfg.sh, port forwarding based on iptables, features support for domain names, ddns, udp, IP, etc. It is simpler to set up an intranet IP in NAT VPS. The disadvantage is that port segments are not supported. 1. Prerequisite operations are not necessary 1. Uninstall firewalld and ufw apt remove firewalld ufw or yum remove firewalld ufw Then reboot. 2. Install iptables yum install -y iptables yum update iptables yum install iptables-services iptables configuration file: /etc/sysconfig/iptables 3. Enable the forwarding function echo -e "net.ipv4.ip_forward=1" >> /etc/sysctl.conf sysctl -p 4. Set up the iptable automatic loading rules function at startup CentOS systems: service iptables save systemctl enable iptables.service Debian/Ubuntu systems: iptables-save > /etc/iptables.up.rules echo -e '#!/bin/bash\n/sbin/iptables-restore < /etc/iptables.up.rules' > /etc/network/if-pre-up.d/iptables chmod +x /etc/network/if-pre-up.d/iptables 2. Forwarding using natcfg.sh Under SSH: wget --no-check-certificate -qO natcfg.sh https://zhujiwiki.com/wp-content/uploads/2020/11/natcfg/natcfg.sh && bash natcfg.sh To continue setting, execute bash natcfg.sh 3. Uninstall natcfg.sh wget --no-check-certificate -qO natcfg.sh https://zhujiwiki.com/wp-content/uploads/2020/11/natcfg/dnat-uninstall.sh && bash dnat-uninstall.sh 4. Configuration File /etc/dnat/conf The project has been open source: https://github.com/arloor/iptablesUtils |
<<: Kuai Che Dao: Double 11 discount, Taiwan HiNet fixed/floating IP all 58 off, plus 1C1G for free
WindowsVPS is an American hosting company that wa...
Haha, you don’t need a discount code, just choose...
DeployNode, an Indian hosting provider, was estab...
Webtropia, owned by myLoc, has previously introdu...
What is YZPanel(YZHCP)? YZPanel (YZHCP) is based ...
CoalCloud, a Chinese merchant and a formal compan...
DataWagon, an American hosting provider, has its ...
Hostkoi has launched several servers with data ce...
vpsdime, which has been introduced before, is a v...
Sentris, has two special priced servers in Seattl...
Buana is a foreign merchant that mainly provides ...
Half Moon Bay is a legal business registered and ...
C38, claims to have 15 years of experience in the...
hotlineservers, a foreign merchant, mainly provid...
Half Moon Bay is a legal business registered and ...