# 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的更多相关文章

  1. ifconfig: command not found(CentOS专版,其他的可以参考)

    ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) echo $PATH 解决方案1:先看看是不是 ...

  2. Linux系统ifconfig命令找不到,centos ifconfig Command not found

    centos ifconfig Command not found,Linux系统ifconfig命令找不到 >>>>>>>>>>>& ...

  3. CentOS 7.0下解决ifconfig: command not found的方法

    在CentOS7.0中输入ifconfig命令会遇到-bash: ifconfig: command not found. 在CentOS最小安装时是没有附带ifconfig,我们进入sbin目录下可 ...

  4. ifconfig: command not found(CentOS 7,其他的可以参考)

    ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) 1 echo $PATH 解决方案1:先看看是 ...

  5. CentOS 7.6 最小安装 ifconfig command not found 及 yum 不可用的解决办法

    问题描述 下载的是 CentOS 7.6 Everything 版本,在 VMware 12 上安装时软件选择“最小安装”后,输入 ifconfig 命令提示: bash ifconfig comma ...

  6. ifconfig: command not found 如何解决?

    ifconfig: command not found 查看path配置(echo相当于c中的printf,C#中的Console.WriteLine) 1 echo $PATH 解决方案1:先看看是 ...

  7. ifconfig出现bash: ifconfig:command not found解决办法之解决连环问题

    Centos7中没有安装ifconfig命令的解决方法 在这之前,centos7最小化安装默认是不能联网的,首先必须切换到root用户,再解决网络问题 一.      切换到root用户 二.     ...

  8. CentOS7 下ifconfig command not found解决办法

    今天尝鲜用VMWare安装了CentOS7,选择了最小安装包模式,安装完毕之后想查看一下本机的ip地址,发现报错 # ifcon -bash: ifconfig: command not found ...

  9. bash: ifconfig: command not found解决方法

    1.问题: #ifconfig bash: ifconfig: command not found 2.原因:非root用户的path中没有/sbin/ifconfig ,其它的命令也可以出现这种情况 ...

随机推荐

  1. NormalMap 贴图 【转】

    转载: http://www.zwqxin.com/archives/shaderglsl/review-normal-map-bump-map.html   说起Normal Map(法线贴图),就 ...

  2. 【云计算】OpenShift容器服务参考

    https://docs.openshift.com/enterprise/latest/using_images/db_images/mysql.html 红帽发布OpenShift Dedicat ...

  3. windows Visual Studio 2017 编译 HEVC cmake-3.8.1-win64-x64.msi 下载

    ttps://github.com/OpenHEVC/openHEVC 下载一 直接下载源码(可选)或下载源码包,我这里下载的是源码 打开 Visual Studio () 去 github 找到源码 ...

  4. MYSQL 问题

    MYSQL 问题 (1)mysql server has gone away 导数据时,如果脚本太大,会执行中断,这时需要修改最大允许包的大小: set global max_allowed_pack ...

  5. 总结this指向问题

    在全局上下文中,this指向全局. 在函数内部,this的值取决于函数被调用的方式. 当函数简单调用时(函数在全局上下文中),this指向window(严格模式下指向undefined) call 或 ...

  6. 【Firefly API文档】—— Package Distributed

    http://bbs.gameres.com/forum.php?mod=viewthread&tid=219654 package distributed 这个包中主要封装了各个服务进程间进 ...

  7. Loadrunner关于页面检查的几个函数详解

    环境:Loadrunner版本:8.0自建一个test.html文件:<html><head><meta name="google1" content ...

  8. 在Docker里使用(支持镜像继承的)supervisor管理进程(转)

    这篇文章是受 dockboard 之托帮忙翻译的与 docker 有关的技术文章.译自 Using Supervisor with Docker to manage processes (suppor ...

  9. ElasticSearch「1」本地安裝Elasticsearch 6.0.1 + Elasticsearch-head插件

    # 下載包 https://www.elastic.co/downloads/past-releases/elasticsearch-6-0-1 https://github.com/mobz/ela ...

  10. Git 工作区、暂存区和版本库

    基本概念 我们等来理解下Git工作区.暂存区和版本库概念 工作区:就是你在电脑里能看到的目录 强烈推荐git新手阅读 暂存区:英文叫stage,或index.一般存放在igt 目录下的index文件( ...