linux网络重启失败

2 篇文章 0 订阅
1 篇文章 0 订阅

问题:网络重启失败

如下:

[root@localhost ~]# systemctl restart network
Job for network.service failed because the control process exited with error code.
See "systemctl status network.service" and "journalctl -xe" for details.

根据提示,执行:

[root@localhost ~]# systemctl status network
● network.service - LSB: Bring up/down networking
   Loaded: loaded (/etc/rc.d/init.d/network; generated)
   Active: failed (Result: exit-code) since Tue 2020-01-14 10:49:23 CST; 43min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 5688 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=1/FAILURE)
      CPU: 1.190s

1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain network[5688]: RTNETLINK answers: File exists
1月 14 10:49:23 localhost.localdomain systemd[1]: network.service: Control process exited, code=exited, status=1/FAILURE
1月 14 10:49:23 localhost.localdomain systemd[1]: network.service: Failed with result 'exit-code'.
1月 14 10:49:23 localhost.localdomain systemd[1]: Failed to start LSB: Bring up/down networking.
1月 14 10:49:23 localhost.localdomain systemd[1]: network.service: Consumed 1.190s CPU time.

思路整理:

网络服务异常可能原因:

1.网络配置出错;

2.  /etc/sysconfig/network-scripts路径下统一网卡,出现多个配置文件,干扰网络

3. NM服务影响(network服务启动会优先通过NM管理,其次走ip a)

排查下来,本次发现我的 /etc/sysconfig/network-scripts路径下一个网卡有多个配置文件,删除后,重新建立配置文件

重新建立:

1). 可以命令配置文件:(以下是我的网卡)

[root@localhost network-scripts]# cat ifcfg-eth0
HWADDR=00:0E:C6:54:0A:BF
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=none
IPADDR=10.2.30.91
PREFIX=16
GATEWAY=10.2.0.2
DNS1=223.5.5.5
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=eth0
UUID=3c0b2360-d585-4209-8aba-66ac59ff4645
ONBOOT=yes

2).  图形配置:

先删除图形存在的网络配置信息,重新建立(类似win,不多说)

3.  最后,重启网络,成功。

[root@localhost ~]# systemctl restart network
[root@localhost ~]#

 

 

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值