RedHat不能使用ifconfig命令

安装RedHat后,使用ifconfig命令,结果报错command not found,解决方法如下:

1.cat ~/.bash_profile     查看path

2.vi /etc/profile    编辑profile文件

3.在profile文件中添加以下内容:

   PATH=$PATH:sbin

   export PATH=$PATH:/sbin

   若profile不能修改,权限是只读,则用root用户先修改权限,再编辑

   

原文地址:https://www.cnblogs.com/Nefeltari/p/4112359.html