On the centos server, configure a NIC configuration (linux and automatic Nic startup). The NIC configuration file is stored in the directory:/etc/sysconfig/network-scripts/specific configuration file: ifcfg-xxx; for example, eth0 is a ifcfg-eth0, lo is ifcfg-lo # Intel Corporation 82545EM Gigabit Ethernet Controller (Copper) TYPE = Ethernet # network adapter type device = eth0 # network adapter Interface Name ONBOOT = yes # Whether to automatically load when the system starts. yes, it is automatically loaded when the system starts, no boot does not load BOOTPROTO = static # enable address protocol -- static: static protocol -- bootp protocol -- dhcp protocol IPADDR = 172.16.13.3 # Nic IP address, write your own information. NETMASK = 255.255.0.0 # Nic network address GATEWAY = 172.16.254.254 # Nic gateway address DNS1 = 172.16.254.254 # Nic DNS address HWADDR = 00: 0C: 29: 13: 5D: 74 # Nic device MAC address BROADCAST = 192.168.1.255 # Nic BROADCAST address command:/etc/init. d/network reload Nic interface disable and activate ifdown eth0 # disable network ifup eth0 # Start and disable network services Method 1: service network start | stop | status | restart | reload | force-reload Method 2:/etc/init. d/network start | stop | status | restart | reload | force-reload start: View All Nic information. The information displayed includes the enabled nic and all NICs. For example, [root @ reage etc] # service network status Configured devices: lo eth0 eth1 Currently active devices: lo eth0 restart: restart the NIC service. The NIC service is disabled first. Then, when the NIC information reload is Enabled: reload the NIC configuration file. After the NIC configuration file is modified and saved, it does not take effect. You need to load it To the memory in this way, start, stop, and status only load the memory configuration information force-reloal: Unknown Function temporary Nic configuration information, no need to restart. [Root @ reage ~] # Ifconfig eth0 172.16.13.3 netmask 255.255.0.0 additional topic: view the MAC of the VM Nic Source: http://blog.csdn.net/rentiansheng/article/details/8877367