CentOS 7 ifconfig命令无法使用提示command not found
2016-08-17 13:36
676 查看
CentOS 7 运行 ifconfig 提示 -bash: ifconfig: command not found
VMWare安装了CentOS7,选择了最小安装包模式,安装完毕之后想查看一下本机的ip地址,发现报错
查看 /sbin/ifconfig是否存在 2.如果ifconfig命令存在,查看环境变量设置
#echo $PATH
如果环境变量中没有包含ifconfig命令的路径临时修改环境变量:在shell中输入
永久修改PATH变量使之包含/sbin路径: 打开/etc/profile文件,在其中输入export PATH=$PATH:/sbin,保存并重启即可,这样一来,PATH路径永久修改成功,以后任何时候只输入ifconfig命令即可 3. 如果ifconfig命令不存在
转载自:http://my.oschina.net/u/1428349/blog/288708
VMWare安装了CentOS7,选择了最小安装包模式,安装完毕之后想查看一下本机的ip地址,发现报错
#ifconfig -bash: ifconfig: command not found谷歌了一下,整理了一下解决思路 查看ifconfig命令是否存在
查看 /sbin/ifconfig是否存在 2.如果ifconfig命令存在,查看环境变量设置
#echo $PATH
如果环境变量中没有包含ifconfig命令的路径临时修改环境变量:在shell中输入
$export PATH = $PATH:/sbin然后再输入ifconfig命令即可,但是这只是临时更改了shell中的PATH,如果关闭shell,则修改消失,下次还需要重复如上操作
永久修改PATH变量使之包含/sbin路径: 打开/etc/profile文件,在其中输入export PATH=$PATH:/sbin,保存并重启即可,这样一来,PATH路径永久修改成功,以后任何时候只输入ifconfig命令即可 3. 如果ifconfig命令不存在
yum upgrade
yum install net-tools
转载自:http://my.oschina.net/u/1428349/blog/288708
相关文章推荐
- ifconfig命令无法找到,提示bash: ifconfig: command not found
- CentOS中无法使用setup命令 -bash:setup: command not found
- CentOS中无法使用setup命令 -bash:setup: command not found
- CentOS中无法使用setup命令 -bash:setup: command not found
- CentOS 5中无法使用make,make install 命令 make: command not found
- Centos中无法使用make,make install,命令 make: command not found
- ifconfig命令无法找到,提示bash: ifconfig: command not found
- ifconfig命令无法找到,提示bash: ifconfig: command not found
- ifconfig命令无法找到,提示bash: ifconfig: command not found
- Centos中无法使用make,make install,命令 make: command not found
- Centos中无法使用make,make install,命令 make: command not found
- centos 6.5 tree命令提示:bash: tree:command not found
- CentOS执行ftp命令提示ftp:command not found解决方法
- 全新安装的CENTOS 7终端执行ifconfig -a,提示 Command not found
- CentOS7执行ifconfig Command not found 未找到命令
- CentOS 运行ifconfig等命令, 提示command not foun
- Mac的控制台命令无法使用command not found
- CentOS 7无法使用ifconfig命令修复
- CentOS最小安装无法使用ifconfig命令
- CentOS执行ftp命令提示ftp:command not found解决方法