centos7:Failed to start LSB: Bring up/down networking | 张恒镭的博客

centos7:Failed to start LSB: Bring up/down networking

时间:15-11-20 栏目:openstack 作者:longteng 评论:0 点击: 5,553 次

出现情况:vmware复制出来的虚机,系统为centos7

1、执行 service network restart 出现以下错误

Restarting network (via systemctl):  Job for network.service failed. See 'systemctl status network.service' and 'journalctl -xn' for details.

2、根据上面的提示,执行“systemctl status network.service”输出以下的类似信息:

[root@localhost ~]# systemctl status network.service

network.service - LSB: Bring up/down networking

   Loaded: loaded (/etc/rc.d/init.d/network)

   Active: failed (Result: exit-code) since 三 2014-11-05 15:30:10 CST; 1min 5s ago

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain network[2920]: RTNETLINK answers: File exists

11月 05 15:30:10 localhost.localdomain systemd[1]: network.service: control process exited, code=exited status=1

11月 05 15:30:10 localhost.localdomain systemd[1]: Failed to start LSB: Bring up/down networking.

11月 05 15:30:10 localhost.localdomain systemd[1]: Unit network.service entered failed state.

3、针对上面的提示信息,如何进行修正,接下来进行了一系列的查找(此处省略2000字+无数的绝望+无数的泪),最后还是google给力(其他的搜索浪费时间),找到解决的办法,其实很简单(由于centos7中没有70-persistent-net.rules这个文件,复制出来的虚拟机(vmware)需要修改mac地址),就是修改mac地址。

4、如何查看centos7复制出来的虚拟机的mac地址,需要执行 “ip addr”,输出如下的类似信息:

[root@localhost ~]# ip addr

1: lo:

    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00

    inet 127.0.0.1/8 scope host lo

       valid_lft forever preferred_lft forever

    inet6 ::1/128 scope host

       valid_lft forever preferred_lft forever

2: eno16777736:

    link/ether 00:0f:19:10:12:f1 brd ff:ff:ff:ff:ff:ff

    inet 192.168.38.135/24 brd 192.168.38.255 scope global dynamic eno16777736

       valid_lft 1681sec preferred_lft 1681sec

    inet6 fe80::20c:11aa:ae11:4fe4/64 scope link

       valid_lft forever preferred_lft forever

注意上面加粗加红的字,这就是新的mac地址。

接下来就剩下修改ifcfg-XXX文件了,只修改HWADDR 和上面保持一致就可以了。接下来执行service network restart 就正常了。

声明: 本文由( longteng )原创编译,转载请保留链接: centos7:Failed to start LSB: Bring up/down networking

centos7:Failed to start LSB: Bring up/down networking:等您坐沙发呢!

发表评论




------====== 本站公告 ======------
欢迎关注我的博客。

其他