ifconfig: command not found 如何解决?
ifconfig: command not found
查看path配置(echo相当于c中的printf,C#中的Console.WriteLine)
1
|
echo $PATH |
解决方案1:先看看是不是root用户,如果不是就 su 切换到root用户
su
解决方案2:(如果没看见 /sbin)【我们这显然不是这个问题】
这个一般都是因为配置没弄好,永久解决:
打开/etc/profile文件,在其中输入export PATH=$PATH:/sbin
解决方案3:(CentOS后来换指令了,看看我们是不是【ipconfig==>ip】)
在 /(根目录)里面查找 name(名字)是 ifconfig 的东东
说明ipconfig真的换了,淡定
看看信息
1
|
ip addr |
发现木有(看 2:eth0 没有ipv4)
跳转到 /etc/sysconfig/network-scripts 目录
1
|
cd /etc/sysconfig/network-scripts |
用vi打开 ifcfg-eth0 (你的可能是eth1,或者其他,不是每个电脑都是这个的)【如果想改成这个可以参考:http://jingyan.baidu.com/article/7f41ecec1b022e593d095c1e.html】
按 i 进去编辑模式 ,修改箭头处,然后按 esc 退回命令模式,输入:wq 并回车
重启一下
1
|
reboot |
用root用户登陆后 输入
1
|
ip addr |
成功!!
解决方案4:(网络)
http://blog.sina.com.cn/s/blog_946cb2b70100wx2j.html
yum install setuptool安装setup,不过安装后使用运行setup只有Authentication configuration可用。
如想配置IP,安装system-config-network-tui即可。
yum install system-config-firewall-tui安装图形化Firewall配置工具。
yum list system-config* 全部安装
ifconfig: command not found 如何解决?的更多相关文章
- 出现bash: ifconfig:command not found的解决办法,即安装ifconfig命令(亲测有效)
初装centos 7时,运行config报 command not found 错误, ifconfig命令是设置或显示网络接口的程序,可以显示出我们机器的网卡信息,可是有些时候最小化安装CentOS ...
- centos 7 ifcnfig提示:bash: ifconfig: command not found的解决方法
接着上一篇,配置完IP地址之后因为ip addr命令不符合我们的习惯,需要添加ifconfig命令 输入命令 yum -y install net-tools 即可解决
- Centos7 Minni 安装 执行ifconfig命令出现 -bash ifconfig command not found 的解决方法
1) have a root privilege shell or be on the sudo list. 2a) At a root shell prompt (#) yum install ne ...
- 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 ,其它的命令也可以出现这种情况 ...
- linux安装报错之:ifconfig command not found解决
问题描述: 用虚拟机VMware安装linux系统(镜像文件是从官网下载的CentOS-7.0-1406-x86_64-DVD.iso), 在安装完成之后,输入ifconfig命令报错:ifconfi ...
- 【转载】bash: ifconfig: command not found 解决办法
原本使用ifconfig 可以使用,今天是怎么了,可能安装软件修改了,百度~~ [oracle@localhost /]$ ifconfig 提示:“bash: ifconfig: command n ...
- CentOS 7.6 最小安装 ifconfig command not found 及 yum 不可用的解决办法
问题描述 下载的是 CentOS 7.6 Everything 版本,在 VMware 12 上安装时软件选择“最小安装”后,输入 ifconfig 命令提示: bash ifconfig comma ...
- ifconfig出现bash: ifconfig:command not found解决办法之解决连环问题
Centos7中没有安装ifconfig命令的解决方法 在这之前,centos7最小化安装默认是不能联网的,首先必须切换到root用户,再解决网络问题 一. 切换到root用户 二. ...
随机推荐
- Python字符串输入输出简述
字符串输入 Python用到的输入一般有两种方式,input() 和 raw_input() ,区别是,前者只能输入数字,后者输入的是字符串,使用如下: In [226]: help(input) H ...
- thinkphp 命名空间
什么是命名空间?从广义上来说,命名空间是一种封装事物的方法.在很多地方都可以见到这种抽象概念.例如,在操作系统中目录用来将相关文件分组,对于目录中的文件来说,它就扮演了命名空间的角色.具体举个例子,文 ...
- 记一次WinForm中屏蔽空格键对按钮的作用
事件的起因是在做一个项目功能时,添加快捷键关闭声音,这个键最终选择了空格键,但是当按下空格键时,会把窗体中获取焦点的控件(比如按钮,文本框等)的单击事件触发,所以要屏蔽这个现象. 开始使用各种方法,在 ...
- Git 总结
详情请参考:https://git-scm.com/book/zh/v2 注意事项:#1. 多提交(相当于多保存,多^S): 在Git中任何已提交的东西几乎总是可以恢复的. 甚至那些被删除的分支中的提 ...
- EasyPusher应用
转自https://github.com/EasyDarwin/EasyPusher 本文仅实际体验一下demo,分析一下如何应用. 1)EasyPusher框图预览 2) EasyPusher应用实 ...
- 手动安装Oracle的Maven依赖
由于Oracle授权问题,Maven3不提供Oracle JDBC driver,为了在Maven项目中应用Oracle JDBC driver,必须手动添加到本地仓库. 环境:win7 + Orac ...
- throttle和debounce简单实现
function debounce(delay,fn){ var timer; return function(){ var ctx = this,args = arguments; clearTim ...
- mysql 主主复制搭建用的命令
# mysql 容器的启动docker run -d -p 3306:3306 -v /database_files/products/data:/var/lib/mysql -v /database ...
- 一张图告诉你,只会Node.JS还不够!
一本nodejs代码段.
- vue DatePicker vue2.0的日期插件
一个用vue2.0写的日期控件,可以支持简单的年月日选择.地址:https://github.com/Stevenzwzhai/vue-datepicker. 首先是关于日期对象的使用,基本就是日期的 ...