CentOS 7 ifconfig: command not found
# ifcon
-bash: ifconfig: command not found
谷歌了一下,整理了一下解决思路
查看ifconfig命令是否存在
查看 /sbin/ifconfig是否存在
如果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
CentOS 7 ifconfig: command not found的更多相关文章
- ifconfig: command not found(CentOS专版,其他的可以参考)
ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) echo $PATH 解决方案1:先看看是不是 ...
- Linux系统ifconfig命令找不到,centos ifconfig Command not found
centos ifconfig Command not found,Linux系统ifconfig命令找不到 >>>>>>>>>>>& ...
- CentOS 7.0下解决ifconfig: command not found的方法
在CentOS7.0中输入ifconfig命令会遇到-bash: ifconfig: command not found. 在CentOS最小安装时是没有附带ifconfig,我们进入sbin目录下可 ...
- ifconfig: command not found(CentOS 7,其他的可以参考)
ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) 1 echo $PATH 解决方案1:先看看是 ...
- CentOS 7.6 最小安装 ifconfig command not found 及 yum 不可用的解决办法
问题描述 下载的是 CentOS 7.6 Everything 版本,在 VMware 12 上安装时软件选择“最小安装”后,输入 ifconfig 命令提示: bash ifconfig comma ...
- ifconfig: command not found 如何解决?
ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) 1 echo $PATH 解决方案1:先看看是 ...
- ifconfig出现bash: ifconfig:command not found解决办法之解决连环问题
Centos7中没有安装ifconfig命令的解决方法 在这之前,centos7最小化安装默认是不能联网的,首先必须切换到root用户,再解决网络问题 一. 切换到root用户 二. ...
- CentOS7 下ifconfig command not found解决办法
今天尝鲜用VMWare安装了CentOS7,选择了最小安装包模式,安装完毕之后想查看一下本机的ip地址,发现报错 # ifcon -bash: ifconfig: command not found ...
- bash: ifconfig: command not found解决方法
1.问题: #ifconfig bash: ifconfig: command not found 2.原因:非root用户的path中没有/sbin/ifconfig ,其它的命令也可以出现这种情况 ...
随机推荐
- Firefox的缓存问题
使用Firefox调试代码时,JS或CSS文件修改后,怎么刷新都不生效.原来是Firefox缓存的问题.但Firefox没有像IE一样有个每次读取最新的设置. 设置Firefox不缓存页面: 新建标签 ...
- LInux 分割合并文件
有两种方式, 第一种使用dd命令 第二种使用split dd命令是linux下一个非常有用的磁盘命令.它可以将指定大小的块拷贝成一个文件,并在拷贝的同时执行指定的转换.UNIX已经提供了文件切割功能, ...
- tornado 多进程模式
https://www.douban.com/note/217901726/ 官方文档的helloworld实例中的启动方法: if __name__ == "__main__": ...
- 极客技术专题【011期】:EasyUI初级教程
来源:GBin1.com 技术专题:EasyUI初级教程 分享人:极客标签技术编辑 - html580(请站内关注分享人) 资深Web前端工程师,HTML580创始人,目前就职于广州一间软件公司.多年 ...
- [android ndk] -android studio中编译生成so文件
1.android.useDeprecatedNdk=true Error:Execution failed for task ':app:compileDebugNdk'.> Error: N ...
- Android Exception 7(attempt to re-open an already-closed object )
07-23 18:16:17.641: W/SQLiteConnectionPool(28390): A SQLiteConnection object for database '/storage/ ...
- fwrite和fread函数的用法小结(转)
fwrite和fread是以记录为单位的I/O函数,fread和fwrite函数一般用于二进制文件的输入输出. #include <stdio.h> size_t fread(void * ...
- Struts2的国际化入门
Struts2的国际化入门 Struts2国际化是建立在Java国际化的基础上的,一样是通过提供不同国家/语言环境的消息资源,然后通过ResourceBundle加载指定Locale对应的资源文件,再 ...
- 解析Linux特殊文件【转】
您有Dos和Windows经验,就大概知道系统存在若干类型的文件,如系统文件.只读文件.隐含文件等.在Linux下用ls –l 命令来判断文件类型,可以依据第一列中的10个字符来判断.-rw-r—r— ...
- Eclipse项目上红叉
整个项目可以编译通过并且运行都没问题,但是项目上有个红叉,这个问题一般是有两个原因: 1.查看项目是不是有的引用包报错 解决办法:在项目的build path 中删除不可用引用或者修正 2.项目的编译 ...