1. Menu bar:--"Edit –" Virtual network editor
2. Virtual machine settings
3. Start the virtual machine
3.1 Open File Ifcfg-eth0
The command is as follows:
Vi/etc/sysconfig/network-scripts/ifcfg-eth0
Setting parameters
Device=eth0 #物理设备名
bootproto= "Static" #[none|static|bootp|dhcp] (No protocol at boot | static Assignment | BOOTP protocol | DHCP protocol)
Onboot= "Yes" # [Yes|no] (whether device is activated at boot)
Userctl=no #[yes|no] (whether the device can be controlled by a non-root user)
IPADDR=192.168.6.100 #IP地址 IP address is the same as in the first 3 of the host, the following section of the custom
gateway=192.168.6.1 #网关地址 Gateway must be the same as the host
netmask=255.255.254.0 #掩码值 Subnet mask is the same as a host
3.2 Configure network card DNS:
Open File resolv.conf
The command is as follows:
Vi/etc/resolv.conf
Then set the DNS settings
dns1=202.96.209.5
dns2=202.96.209.133
Quad Restart Network
Command:/etc/init.d/network Restart or service network restart
Network (bridging mode) static IP settings in the CentOS system in VMware12