IPTABLES port ing in LINUX

Source: Internet
Author: User
Linux iptables port ing-Linux Enterprise Application-Linux server application information. For details, see the following section. Iptables-a forward-s 0/0-p tcp -- dport 80-j ACCEPT

Iptables-t nat-a prerouting-p tcp-d 218.18.103.114 -- dport 80-j DNAT -- to 192.168.10.100: 80

The preceding command indicates:
For example:
The public IP address of the current Gateway is 218.18.103.114.
The Intranet CIDR block is 192.168.10.0.
There is a WEB server in the Intranet with the IP address 192.168.10.110
So that others can access the WEB server directly through the Internet. Operation Method:
Run the above two lines on the gateway.
When accessing your website, you only need to enter http: // 218.18.103.114/in the address bar to open your internal WEB server and access your webpage.
Other servers and so on:
80 is the WEB server port
21 is the FTP server port
25 is the mail server port
22 is the SSH port
27015 is the CS server port

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.