1. Modify the VM Internet mode to host only
2. Start the virtual machine
3.rm-rf/etc/udev/rules.d/70-persistent-net.rules
4. Modify the network configuration of the virtual machine:
(1) Vi/etc/sysconfig/network-scripts/ifcfg-eth0
(2) Modify the device value to eth0
(3) Delete hwaddr line
(4) Comment out Bootproto=dhcp
(5) Added: ipaddr=192.168.0.10x
netmask=255.255.255.0
gateway=192.168.0.1
7.vi/etc/resolv.conf, will nameserver 192.168.0.1
10. Turn off the firewall:
Service Iptables Stop
Permanently closed: Chkconfig iptables off
Check if shutdown: Service iptables status
11. Turn off SELinux
Vi/etc/selinux/config
Comment out selinux=enforcing
selinux=targeted
Increase selinux=disabled
5. In the native network configuration, the VMware networks Adapter Vmnet1,ip is changed to 192.168.0.1, Subnet mask 255.255.255.0
6. Share the native Internet network adapter to the VMware network Adapter VMnet1
8. Restart the virtual machine
9.ping native, network, native ping virtual machine
Copy to Google TranslateTranslation Results
CentOS specified IP in virtual machine