在centos下 ifconfig 无报错但无输出结果?ifconfig不能用?

在centos下 ifconfig 无报错但无输出结果?ifconfig不能用?
[root@xwx~]# ifconfig
[root@xwx~]# 

如果已安装则卸载载安装就好了

#卸载net-tools
yum remove net-tools

#安装net-tools
yum install net-tools

执行过程效果:

[root@localhost ~]# yum remove net-tools
已加载插件:fastestmirror
正在解决依赖关系
--> 正在检查事务
---> 软件包 net-tools.x86_64.0.2.0-0.25.20131004git.el7 将被 删除
--> 解决依赖关系完成

依赖关系解决

====================================================================================
 Package           架构           版本                             源          大小
====================================================================================
正在删除:
 net-tools         x86_64         2.0-0.25.20131004git.el7         @/         917 k

事务概要
====================================================================================
移除  1 软件包

安装大小:917 k
是否继续?[y/N]:y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  正在删除    : net-tools-2.0-0.25.20131004git.el7.x86_64                       1/1 
警告:文件 /sbin/ifconfig: 移除失败: 没有那个文件或目录
  验证中      : net-tools-2.0-0.25.20131004git.el7.x86_64                       1/1 

删除:
  net-tools.x86_64 0:2.0-0.25.20131004git.el7                                       

完毕!


======================================================================================


[root@localhost ~]# yum install net-tools
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirrors.163.com
 * extras: mirrors.163.com
 * updates: mirrors.aliyun.com
正在解决依赖关系
--> 正在检查事务
---> 软件包 net-tools.x86_64.0.2.0-0.25.20131004git.el7 将被 安装
--> 解决依赖关系完成

依赖关系解决

====================================================================================
 Package          架构          版本                              源           大小
====================================================================================
正在安装:
 net-tools        x86_64        2.0-0.25.20131004git.el7          base        306 k

事务概要
====================================================================================
安装  1 软件包

总下载量:306 k
安装大小:917 k
Is this ok [y/d/N]: y
Downloading packages:
net-tools-2.0-0.25.20131004git.el7.x86_64.rpm                | 306 kB  00:00:00     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  正在安装    : net-tools-2.0-0.25.20131004git.el7.x86_64                       1/1 
  验证中      : net-tools-2.0-0.25.20131004git.el7.x86_64                       1/1 

已安装:
  net-tools.x86_64 0:2.0-0.25.20131004git.el7                                       

完毕!


===================================================================================


[root@localhost ~]# ifconfig
ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.10  netmask 255.255.255.0  broadcast 192.168.1.255
        inet6 fe70::20c:29ee:fe65:b6f2  prefixlen 64  scopeid 0x20<link>
        ether 00:0c:30:65:a4:e2  txqueuelen 1000  (Ethernet)
        RX packets 9427  bytes 10752810 (10.2 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 2101  bytes 186230 (181.8 KiB)
        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>
        loop  txqueuelen 1000  (Local Loopback)
        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

[root@localhost ~]# 

 

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值