1. Install vmware workstation.
2. Install the guest system. Here, I installed Red Hat Linux9. During the installation process, make sure that the network connection is in the NAT mode. Of course, you can modify it after installation.
3. Check all network connections in Windows XP. In addition to the original Nic, you should find that there are more vmnet1 and vmnet8. Vmnet1 is the hostonly interface, while vmnet8 is the NAT Network Interface we want to use.
4. Use ipconfig on the win host to view the vmnet8 IP address, which is 192.168.x.1/255.255.255.0. At this time, the vmnet8 setting should be to automatically obtain the IP address and change it to a static IP address, enter the IP address in vmnet8 without a gateway.
5. Check vmnet8 In the NAT entry in the VM network settings. Generally, the address 192.168.x.2/255.255.255.0 is vmnet8 and the NAT gateway.
6. Now, in Linux, set the nic ip address to the IP address of one network segment (192.168.x.z/255.255.255.0) of vmnet8)
7. Set the gateway to the IP address 192.168.x. 2 you just viewed.
8. DNS is the same as your host.
9. After the configuration is complete, restart the Linux network service.
Linux commands
Netconfig
Ifconfig View
Reboot restart
Services Network restart (restart the network)