首页 > Web开发 > 详细

redhat8重启网卡服务Failed to restart network.service: Unit network.service not found.

时间:2021-06-26 16:42:09      阅读:70      评论:0      收藏:0      [点我收藏+]

1、问题

[root@localhost ~]# systemctl restart network
Failed to restart network.service: Unit network.service not found.

 

2、查看iP

[root@localhost ~]# ifconfig | head
ens160: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500  //网卡名称
        ether 00:0c:29:b2:81:9a  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>

 

3、重启网卡

[root@localhost ~]# nmcli c up ens160     //重启网卡
Connection successfully activated (D-Bus active path: /org/freedesktop/NetworkMa
[root@localhost ~]# ifconfig | head -n 5
ens160: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 162.168.10.10  netmask 255.255.255.0  broadcast 162.168.10.255
        inet6 fe80::87a8:d6e:7639:1b9  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:29:b2:81:9a  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)

 

redhat8重启网卡服务Failed to restart network.service: Unit network.service not found.

原文:https://www.cnblogs.com/liujiaxin2018/p/14934120.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!