解决CentOS初装后ifconfig命令无法使用

记录原因:

        本地安装CentOS虚拟机后想要查看IP,提示ifconfig :command not found。

原因办法:

        环境中没有安装命令,环境变量未配置。解决办法就是,装一个。

解决步骤:

一、使用Root用户查看确认是环境中是否已安装

ls /sbin | grep ifconfig

二、使用yum搜索ifconfig在哪里

yum search ifconfig

三、直接安装上一步的搜索结果

yum install net-tools.x86_64

四、使用一下

ifconfig

五、搞定收工

猜你喜欢

转载自blog.csdn.net/weixin_41195886/article/details/127119670