linux上网络配置不生效的怪异现象处理
2016-11-18 14:03
513 查看
1、在Linux上,在ifcfg-eth0上设置IP地址等信息
详细配置信息如下已
[root@rac01 Desktop]#more/etc/sysconfig/network-scripts/ifcfg-eth0
2、IP地址不生效的情况
(1)ifconfig查看eth0网卡信息,发现IP地址并没有生效
问题比较鬼异,明明在ifcfg-eth0文件中设置有IP地址192.168.171.150的,为什么会系统却获不到IP地址呢。
(2)ping别的IP地址报如下错误:
[root@rac01Desktop]# ping 192.168.171.180
connect:Network is unreachable
(3)重启网络服务提示网卡没有活动
3、问题分析
从第2节中的3点信息来判断,基本确定为网卡没有启动所致。
4、处理解决
到此,网卡已经正常工作。
详细配置信息如下已
[root@rac01 Desktop]#more/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0 BOOTPROTO=none NM_CONTROLLED=yes ONBOOT=no TYPE=Ethernet UUID=3d5f18d5-73e0-48db-acbb-67d3ee8b332f IPADDR=192.168.171.150 PREFIX=24 |
(1)ifconfig查看eth0网卡信息,发现IP地址并没有生效
[root@rac01 Desktop]# ifconfig eth0 eth0 Link encap:Ethernet HWaddr 00:0C:29:84:F2:24 inet6 addr: fe80::20c:29ff:fe84:f224/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:6 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 b) TX bytes:468 (468.0 b) |
(2)ping别的IP地址报如下错误:
[root@rac01Desktop]# ping 192.168.171.180
connect:Network is unreachable
(3)重启网络服务提示网卡没有活动
[root@rac01 network-scripts]# service network restart Shutting down interface eth0: Error: Device 'eth0' (/org/freedesktop/NetworkManager/Devices/0) disconnecting failed: This device is not active [FAILED] Shutting down loopback interface: [ OK ] Bringing up loopback interface: [ OK ] |
从第2节中的3点信息来判断,基本确定为网卡没有启动所致。
4、处理解决
[root@rac01 Desktop]# ifup ifcfg-eth0 Active connection state: activated Active connection path: /org/freedesktop/NetworkManager/ActiveConnection/1 [root@rac01 Desktop]# ifconfig eth0 eth0 Link encap:Ethernet HWaddr 00:0C:29:84:F2:24 inet addr:192.168.171.150 Bcast:192.168.171.255 Mask:255.255.255.0 inet6 addr: fe80::20c:29ff:fe84:f224/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1 errors:0 dropped:0 overruns:0 frame:0 TX packets:44 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:82 (82.0 b) TX bytes:7277 (7.1 KiB) |
相关文章推荐
- linux上网络配置不生效的怪异现象处理
- linux上网络配置不生效的怪异现象处理
- linux上网络配置不生效现象处理
- Linux下setup网络配置Ip不生效的解决方法
- Linux企业级项目实践之网络爬虫(5)——处理配置文件
- Linux系统的初化始配置(包括配置网络,修改主机名,关闭firewalld与selinux的生效)
- Linux企业级项目实践之网络爬虫(5)——处理配置文件
- Red Hat Enterprise Linux 7.0的网络配置(附加常见网络问题处理)
- Linux网络服务器配置基础
- Linux网络服务器配置基础详解
- Linux网络服务器配置基础
- Linux网络服务器配置入门(一)
- Linux网络服务器配置基础(上) network inetd
- 手动配置linux网络
- linux 网络配置
- linux 网络配置
- linux redhat 中的网络配置
- Linux 网络接口配置文件及相关工具
- Linux网络管理员手册(6) 第六章 名字服务和解析器配置 DNS 解析器库 host.conf nslookup
- Linux网络管理员手册(19) 第十九章 Newsreader的配置