VMwareNAT port ing Configuration

Source: Internet
Author: User
Article Title: VMwareNAT port ing configuration. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.

Linux is installed on the Virtual Machine VMware. To enable the host to access web services running in Linux on the virtual machine, the VMware NAT port ing configuration is required. The details are as follows:

1. For Linux Host (the Host is Linux, no matter what the virtual machine is, because it is outside the Host's physical Nic listener .)

Modify the/etc/vmware/vmnet8/nat. conf file

Add

[Incomingtcp]

8889 = 192.168.0.128: 22

Save and exit.

Restart service/usr/lib/vmware/net-services.sh restart

Test on Host:

Ssh-p 8889 root @ localhost

2. For Windows Host

The Hidden Port ing in NAT indicates the environment. By using the VMnet8 network connection, the WEB server of win2003 is set up in the virtual machine to use the default port 80 on the WEB, and the IP address is 192.168.10.4, the real host winxp system has two IP addresses, which are connected to 192.168.10.1 and the IP address on the internet is 221.196.193.220. Other computers on the Internet can access win2003 WEB by accessing my real host 221.196.193.220.

First, let's talk about the principle. Because the WEB Service uses port 80, a WEB service is established on Win2003, and port 80 is automatically opened because Win03 is an intranet ip address (192.168.10.4 ), the Internet cannot access this address to find my web service, but I can access my XP system through the Internet address (221.196.193.220), and XP can connect to Win2003, so it is possible to map 80 to my Winxp system!

Now, let's talk about the actual operation. Open the -- edit -- virtual network settings -- NAT tab, as shown in

Select edit and enable NAT settings. Keep the default settings here. If you are familiar with your network, you can change the gateway and other items.

Directly enable port forwarding. Here the NAT port ing is configured. I used the instance's WEB service as an example. Because the WEB is a TCP connection, I have done both TCP and UDP, click Add

Host port: Fill in the real host port to be converted. Here I use FTP for another example and set up the FTP service on the real host 1021, in this way, you need to add ":" After the ip address, for example, ftp: // 192.168.1.1: 1021, the host port is still 80 because I have no web service on XP.

Virtual Machine IP address. Enter the IP address of the Intranet virtual machine. This is the IP address of Win2003, the Service port. The port corresponding to the service is filled in. You can refer to other articles, commonly used ports.

Description. It doesn't matter. Just write something you can understand. It's okay if you can ~

In this way, your friend can enter http: // 221.196.193.220/in IE to access the WEB service under Win2003 in your virtual machine. What? Not yet? The access is successful by myself, but not by anyone else?

Well, don't worry. If you are a WINXP SP2 system, check your firewall settings and add ports. Don't say it. For security, add both TCP and UDP to the exception ~

PS: 1. Configure IIS and dynamic domain name resolution software in the Virtual Machine

2. If your host is in the Intranet, set port ing on the vro. If the host is directly connected to the Internet, skip this step.

Related Article

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.