The error "Job for Network.service failed" occurs when you run the "/etc/init.d/network restart" command. See ' systemctl status Network.service ' and ' journalctl-xn ' for Deta', run 'cat/var/log/messages | grep NE Twork"command to view the network -related information thatappears in the log , the following output statements are found:
Nov 11:31:16 OpenStack network:bringing up Interface Eth0:Error:no device found for connection ' eth0 '.
Nov 11:31:16 OpenStack Network: [FAILED]
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Network:rtnetlink answers:file exists
Nov 11:31:16 OpenStack Systemd:network.service:control Process exited, code=exited Status=1
Nov 11:31:16 OpenStack systemd:failed to start lsb:bring up/down networking.
Nov 11:31:16 OpenStack Systemd:unit Network.service entered failed state.
from error "error: no device found for connection ' eth0 ' " can be determined to be configuration file eth0 /etc/ Sysconfig/network-scripts/ifcfg-eth0 file found in the mac address ifconfig command output mac address is different, as follows:
[Email protected] ~]# Cat/etc/sysconfig/network-scripts/ifcfg-eth0
hwaddr= 1a:e9:47:a5:75:c8
Type=ethernet
Bootproto=static
Defroute=yes
Peerdns=yes
Peerroutes=yes
Ipv4_failure_fatal=no
Ipv6init=yes
Ipv6_autoconf=yes
Ipv6_defroute=yes
Ipv6_peerdns=yes
Ipv6_peerroutes=yes
Ipv6_failure_fatal=no
ipaddr=192.168.1.79
Prefix=24
gateway=192.168.1.1
dns1=192.168.1.1
dns2=8.8.8.8
Name=eth0
Uuid=ba670f0c-201a-483b-8379-c8c72c03ab27
Onboot=yes
[Email protected] ~]# ifconfig
Eth0:flags=4163<up,broadcast,running,multicast> MTU 1500
inet 192.168.1.79 netmask 255.255.255.0 broadcast 192.168.1.255
Inet6 fe80::8081:a6ff:fe9d:5887 Prefixlen ScopeID 0x20<link>
ether 82:81:a6:9d:58:87 Txqueuelen (Ethernet)
RX packets 3426 Bytes 394042 (384.8 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX Packets bytes 9578 (9.3 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
So just change the value of the HWADDR variable in the ifcfg-eth0 to the MAC shown in the ifconfig command. address can be.
Job for Network.service failed