1. Description: virtual machine configuration IP restart network card: service network restart error message:
The error information is as follows:
[root@localhost network-scripts]# vim ifcfg-eth0 [root@localhost network-scripts]# [root@localhost network-scripts]# service network restart Shutting down loopback interface: [ OK ] Bringing up loopback interface: [ OK ] Bringing up interface eth0: Error: No suitable device found: no device found for connection 'System eth0'. [FAILED]
2. This problem occurs because the network card actually assigned to the virtual machine does not match the network card information in the configuration file
1. The actual network card information allocated to the virtual machine is: [hwaddr 00:0c: 29:7f: B6: FF]
root@localhost /]# ifconfig eth1 Link encap:Ethernet HWaddr 00:0C:29:7F:B6:FF inet6 addr: fe80::20c:29ff:fe7f:b6ff/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:68 errors:0 dropped:0 overruns:0 frame:0 TX packets:14 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:7028 (6.8 KiB) TX bytes:1620 (1.5 KiB) Interrupt:19 Base address:0x2024 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:48 errors:0 dropped:0 overruns:0 frame:0 TX packets:48 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:3760 (3.6 KiB) TX bytes:3760 (3.6 KiB)
2. The network card information in the configuration file is:
vim /etc/sysconfig/network-script/ifcfg-eth0
DEVICE="eth0" BOOTPROTO="static" IPV4_FAILURE_FATAL="yes" BOOTPROTO="dhcp" HWADDR="00:0C:29:7F:B6:8A" IPV6INIT="yes" NM_CONTROLLED="yes" ONBOOT="yes" TYPE="Ethernet" UUID="5c4e89fb-eced-4d66-962a-e5f6e565ec26" IPADDR="192.168.25.135" NETMASK="255.255.255.0" GATEWAY="192.168.25.1" DNS1="192.168.25.1"
3. Modification method: the above configuration files are configured according to the network card actually allocated to the virtual machine, that is:
HWADDR="00:0C:29:7F:B6:8A" Modify to HWADDR="00:0C:29:7F:B6:FF" Save the pair to exit: restart the NIC: service network restart Correct