VMware Workstation Virtual Machine network connection note, configure a fixed IP address for a Windows Virtual Machine

Source: Internet
Author: User

After installing VMware, two NICs are added to the Network connection: VMware Network Adapter VMnet1 and VMware Network Adapter VMnet8.

VMnet1 is the host Nic used to connect to the network in the host mode. VMnet8 is a NAT Nic used to connect to the network in NAT mode.

These two NICs have fixed IP addresses, which are automatically generated, such:

The two NICs belong to different network segments. The default gateway and DNS server are empty by default.

 

Three major connection modes of VMware: Bridged, NAT, and Host-Only)

1. Use bridged networking (using a bridge network)

Note: If you use A VMnet0 vswitch, the virtual machine has an independent IP address, which is equivalent to an independent computer and host on the network. As shown in network topology 1,, a1, A2, and B can communicate with each other.

Figure 1 topology diagram of Bridging Mode

2. Use network address translation (NAT) Description: When a Vmnet8 vswitch is used, the virtual machine can access other workstations on the one-way network of the host, and other workstations cannot access the virtual machine. As shown in network topology 2, A1 and A2 can access B in NAT mode, but B cannot access A1 and A2. However, A, A1, and A2 can communicate with each other.

Figure 2 topology of NAT Mode

3. Use Host-Only networking (using the Host network)

Note: when using the Vmnet1 vswitch, the virtual machine can only communicate with the Virtual Machine and host. That is, you cannot access the Internet. As shown in Network Topology 3, you can access A, A1, and A2 in the Host mode. However, A1 and A2 cannot access B or B.

Figure 3 host network topology

The above content from: http://blog.chinaunix.net/space.php? Uid = 20653907 & do = blog & id = 1590716

 

Note:

By default, NAT is selected for both XP and 2008 virtual machines. After a virtual machine is created, the IP address can be automatically obtained and the IP address can be logged on to the Internet. After entering the 2008 Vm, "Start-run-cmd-ipconfig/all". The result is as follows:

The automatically obtained IP address is 192.168.174.136, And the DHCP service is provided by the host. You can see it in the host service, as shown in:

Therefore, do not use tools such as 360 for boot optimization or anything. disabling the VMware DHCP Service will cause virtual machines to be unable to obtain IP addresses, or access to the Internet and other network problems.

Because an application must be installed in the 2008 System, the application must have a fixed IP address and cannot use an automatically obtained IP address.

The first thought of the bridging method is to access the network like the host, but the virtual machine is in the notebook and runs with the notebook export, and the IP network segment of the VM is always changing, this method won't work.

In the second case, use NAT to set a fixed IP Address: 192.168.174.150 in the network connection to distinguish the previously obtained IP address, for example:

Confirm and then re-Identify the network. after a short period of "Network disconnection", re-connect to the Internet. The Ip address information after configuration is as follows:

The third type of Host-Only cannot be connected to the Internet, so do not consider it.

So far, the virtual machine's fixed IP address has been configured.

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.