View virtual networks in VMware
VMware Software -> Edit -> Virtual Network Editor
Setting up Windows Virtual Network Connections
Control Panel -> Network and Internet -> Network Connections
Note that the set IP, GATEWAY, and DNS must be consistent with the configuration of the virtual machine
Setting up Linux network configuration
Use the root user to edit the file, the command is as follows
vim /etc/sysconfig/network-scripts/ifcfg-eth0
Make relevant edits (red is the modified content)
DEVICE=eth0
HWADDR=00:0C:29:8C:70:55
TYPE=Ethernet
UUID=48a8c55d-584d-4b99-8d37-77dba97a1fb2
ONBOOT= yes
NM_CONTROLLED=yes
BOOTPROTO= static
IPADDR=192.168.80.101
GATEWAY=192.168.80.2
NETMASK=255.255.255.0
DNS1=192.168.80.2
HWADDR=00:0C:29:8C:70:55
TYPE=Ethernet
UUID=48a8c55d-584d-4b99-8d37-77dba97a1fb2
ONBOOT= yes
NM_CONTROLLED=yes
BOOTPROTO= static
IPADDR=192.168.80.101
GATEWAY=192.168.80.2
NETMASK=255.255.255.0
DNS1=192.168.80.2
After editing, save and exit: wq
Then restart the network service to communicate between windows and linux
service network restart