centos6.0网卡问题总结

简介:
eth0不见了的处理方法
 
1.刚开始运行ifconfig eth0发现网卡不见了。
[root@localhost ~]# ifconfig eth0
eth0: error fetching interface information: Device not found //但是network-scripts里的配置文件全部是eth0的,为什么获取不到也不知道为什么?
处理解决方法只能用eth1替换eth0了,自己创建modprobe.conf文件里面alias eth0 e1000e但是不能识别。
 
2.[root@localhost network-scripts]# mii-tool //查看网卡连接状态
   eth1: negotiated 100baseTx-FD, link ok
 
3.[root@localhost network-scripts]# ifconfig eth1//能发现eth1网卡
 
4.[root@localhost network-scripts]# mv ifcfg-eth0 ifcfg-eth1//修改eth0为eth1
 
5.[root@localhost network-scripts]# vi ifcfg-eth1
DEVICE=eth1//把eth1修改为eth0
ONBOOT=yes//启动激活
TYPE=Ethernet
BOOTPROTO=static//静态ip
IPADDR=192.168.xx.40
NETMASK=255.255.255.0
GATEWAY=192.168.xx.254
 
6.[root@localhost ~]# cd /etc/sysconfig/networking/ //进入networking目录
[root@localhost networking]# ls//里面有两个文件把里面的设备修改为ifcfg-eth1即可。
devices  profiles
 
7.[root@localhost devices]# /etc/rc.d/init.d/network restart //重新启动network守护进程。
Shutting down interface eth1:                              [  OK  ]
Shutting down loopback interface:                          [  OK  ]
Bringing up loopback interface:                            [  OK  ]
Bringing up interface eth1:                                [  OK  sss]
 
8.[root@localhost devices]# ping  www.baidu.com //最后ping 百度通了
PING  www.a.shifen.com (220.181.111.148) 56(84) bytes of data.
64 bytes from 220.181.111.148: icmp_seq=1 ttl=52 time=33.1 ms
64 bytes from 220.181.111.148: icmp_seq=2 ttl=52 time=33.3 ms
64 bytes from 220.181.111.148: icmp_seq=3 ttl=52 time=33.4 ms
 
遇到的问题:
刚开始因为以为驱动问题,lsmod看了一下加载的驱动为e1000e,所以在 /etc/modprobe.d/里添加了modprobe.conf文件可是还是不行。
dmesg查看启动信息查看网卡信息为e1000: eth1 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: None
后来查看/lib/modules/2.6.32-71.el6.i686/modules.alias 添加alias eth0 e1000e 还是不行,只能用eth1代替eth0
 


本文转自zh888 51CTO博客,原文链接:http://blog.51cto.com/zh888/775447,如需转载请自行联系原作者

相关文章
|
数据可视化 Linux
Linux centos7.x系统 下没有ens33 网卡的解决方案
此时还没有enp0s31f6网卡相关的配置信息 , 所以我们需要配置enp0s31f6网卡相关的信息
1669 0
|
负载均衡 Linux
配置Centos7网卡聚合链路
配置Centos7网卡聚合链路
1237 0
配置Centos7网卡聚合链路
|
Linux 虚拟化
VMware workstation 中centos7虚拟机在nat模式下怎么配置网卡,指定我想要的IP并且可以联网
https://blog.csdn.net/2302_78534730/article/details/132825156?spm=1001.2014.3001.5502
792 0
|
Ubuntu 网络协议 Linux
liunx各大发行版(centos,rocky,ubuntu,国产麒麟kylinos)网卡配置和包管理方面的区别
本文对比了Linux主要发行版CentOS、Rocky Linux、Ubuntu及国产Kylin在网卡配置与包管理上的差异。
756 1
|
Ubuntu 网络协议 Linux
liunx各大发行版(centos,rocky,ubuntu,国产麒麟kylinos)网卡配置和包管理方面的区别
liunx各大发行版(centos,rocky,ubuntu,国产麒麟kylinos)网卡配置和包管理方面的区别
552 0
|
Linux
Linux——Centos8虚拟机添加网卡未显示
Linux——Centos8虚拟机添加网卡未显示
359 0
|
网络协议 Linux
Linux——Centos8.2如何重启网卡服务
Linux——Centos8.2如何重启网卡服务
455 0
|
网络协议
centos8 网卡 Nmcli(是network的简写 Nmcli)配置网络
centos8 网卡 Nmcli(是network的简写 Nmcli)配置网络
564 0
|
Linux
VMware15更新后克隆Centos7发现网卡起不来了
VMware15更新后克隆Centos7发现网卡起不来了
155 0
|
Linux
CentOS7下修改默认网卡名为eth0的方法
CentOS7下修改默认网卡名为eth0的方法
425 0