bash: ifconfig: command not found的解决

bash: ifconfig: command not found的解决

su root

bash: ifconfig: command not found

提示命令没找到

[[email protected] ~]# ifconfig
bash: chkconfig: command not found
[[email protected] ~]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/gtl/bin

添加/sbin的环境变量

[[email protected] ~]# PATH="$PATH":/sbin
[[email protected] ~]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/gtl/bin:/sbin