前言
CentOS7开始不再使用ifconfig,并不预装,而是采用ip addr指令查询网卡名称和IP地址
[root@yzz-test ~]# ifconfig
-bash: ifconfig: 未找到命令
[root@yzz-test ~]# yum search ifconfig
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
* base:
* epel:
* extras:
* updates:
======================================================== N/S matched: ifconfig ========================================================
python36-ifcfg.noarch : Python cross-platform network interface discovery (ifconfig/ipconfig/ip)
结果:安装之后,没有该指令,尝试采用search all
[root@yzz-test ~]# yum search all ifconfig
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
* base:
* epel:
* extras:
* updates:
=========================================================== 匹配:ifconfig ============================================================
python36-ifcfg.noarch : Python cross-platform network interface discovery (ifconfig/ipconfig/ip)
moreutils.x86_64 : Additional unix utilities
net-tools.x86_64 : Basic networking tools
python2-psutil.x86_64 : A process and system utilities module for Python
python34-psutil.x86_64 : A process and system utilities module for Python
python36-psutil.x86_64 : A process and system utilities module for Python
[root@yzz-test ~]# yum install net-tools