嗨,当我将我的电脑升级到 ubuntu 11.10 时,我无法连接到有线连接!它甚至找不到我的设备 MAC 地址!!我该怎么办?
ifconfig -a
eth0 Link encap:Ethernet HWaddr ff:ff:ff:ff:ff:ff
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:44 Base address:0x2000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:6647 errors:0 dropped:0 overruns:0 frame:0
TX packets:6647 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1333687 (1.3 MB) TX bytes:1333687 (1.3 MB)
Run Code Online (Sandbox Code Playgroud)
etc/network/interfaces的答案
auto lo
iface lo inet loopback
sudo lshw -class network
*-network
description: Ethernet interface
product: RTL8111/8168B PCI Express Gigabit Ethernet controller
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:04:00.0
logical name: eth0
version: 02
serial: ff:ff:ff:ff:ff:ff
size: 1Gbit/s
capacity: 1Gbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix vpd bus_master cap_list rom ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=full firmware=N/A latency=0 link=no multicast=yes port=MII speed=1Gbit/s
resources: irq:44 ioport:c000(size=256) memory:cff20000-cff20fff memory:cff00000-cff0ffff memory:cff10000-cff1ffff
lspci
00:00.0 Host bridge: Intel Corporation 4 Series Chipset DRAM Controller (rev 03)
00:01.0 PCI bridge: Intel Corporation 4 Series Chipset PCI Express Root Port (rev 03)
00:1a.0 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #4
00:1a.1 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #5
00:1a.2 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #6
00:1a.7 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB2 EHCI Controller #2
00:1b.0 Audio device: Intel Corporation 82801JI (ICH10 Family) HD Audio Controller
00:1c.0 PCI bridge: Intel Corporation 82801JI (ICH10 Family) PCI Express Root Port 1
00:1c.4 PCI bridge: Intel Corporation 82801JI (ICH10 Family) PCI Express Root Port 5
00:1c.5 PCI bridge: Intel Corporation 82801JI (ICH10 Family) PCI Express Root Port 6
00:1d.0 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #1
00:1d.1 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #2
00:1d.2 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB UHCI Controller #3
00:1d.7 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB2 EHCI Controller #1
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev 90)
00:1f.0 ISA bridge: Intel Corporation 82801JIB (ICH10) LPC Interface Controller
00:1f.2 IDE interface: Intel Corporation 82801JI (ICH10 Family) 4 port SATA IDE Controller #1
00:1f.3 SMBus: Intel Corporation 82801JI (ICH10 Family) SMBus Controller
00:1f.5 IDE interface: Intel Corporation 82801JI (ICH10 Family) 2 port SATA IDE Controller #2
01:00.0 VGA compatible controller: nVidia Corporation G92 [GeForce 9600 GSO] (rev a2)
03:00.0 IDE interface: JMicron Technology Corp. JMB368 IDE controller
04:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 02)
05:00.0 Memory controller: Conexant Systems, Inc. Device 2d00 (rev 01)
uname -a
Linux mahdiar-EP45-UD3L 3.0.0-15-generic #26-Ubuntu SMP Fri Jan 20 17:23:00 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
Run Code Online (Sandbox Code Playgroud)
内核错误地将此 NIC 与 r8169 内核模块匹配。这由lshw显示 NIC 已禁用的跟踪显示。
根据这篇文章,网卡应该与r8168内核模块相关联。使用不正确的内核模块,您要么速度变慢,要么根本无法连接。
根据 Launchpad - 这也是 Oneiric 的一个公认错误 - 但是,由于 Precise 使用更新的内核 (v3.2),它似乎已在 12.04 中得到解决
首先,让我们排除 NIC 硬件故障 - NIC 可能会损坏(固件/ROM) - 这表明 MAC 地址被识别为FF:FF:FF:FF:FF
如果您上次使用 Natty(或以前的 Ubuntu 版本)使用 NIC - 然后使用 LiveUSB/LiveCD 启动您的 PC。
测试您的有线连接 - 重新运行sudo lshw -class network。查找 MAC 地址。还要看看它是否仍然说禁用。
如果它仍然无法通过实时 USB/CD 与它上次使用的 ubuntu 版本连接,那么你有一个强烈的硬件故障迹象。
排除硬件问题后,让我们专注于可能的软件解决方案。
对于下面的解决方案,您仍然需要有效的互联网连接...
如果您有非此型号的备用 NIC 卡,我会将其插入您的 PC 并通过有线连接连接到互联网。如果您可以通过无线连接 - 这样做。否则,您可能需要将硬盘驱动器移至另一台计算机以执行以下操作,然后将其传输回原始 PC。
首先 - 使用 Clonezilla 等良好的备份工具备份您的系统
建议修复 1
根据启动板错误报告,如果您在软件源中启用建议的存储库并安装软件包,则可能会修复此问题 linux-backports-modules-3.0.0
建议修复 2
您可以下载 Precise 内核 (v3.2) 并安装它。
从启动板的主线内核区域:
下载 amd64 headers.deb、headers_all.deb 和 image_amd64.deb 文件
然后使用以下语法安装内核:
sudo dpkg -i [package_name].deb
Run Code Online (Sandbox Code Playgroud)
建议修复 3
您可以通过下载 realtek 驱动程序并自行编译来解决此问题。
下载Linux 源代码- 在撰写本文时它是 v8.028.00
解压压缩包:
tar vjxf r8168*.tar.bz2
Run Code Online (Sandbox Code Playgroud)
切换到目录:
cd r8168-8*
Run Code Online (Sandbox Code Playgroud)
编译:
sudo ./autorun.sh
Run Code Online (Sandbox Code Playgroud)
您可以使用以下命令检查驱动程序是否已加载。
lsmod | grep r8168
ifconfig -a
Run Code Online (Sandbox Code Playgroud)
如果显示器上显示设备名称 ethX,则 linux 驱动程序已加载。然后,您可以使用以下命令激活 ethX。
ifconfig ethX up
Run Code Online (Sandbox Code Playgroud)
最后将r8169驱动加入黑名单添加以下内容 /etc/modprobe.d/blacklist.conf
#blacklist r8169 driver
blacklist r8169
Run Code Online (Sandbox Code Playgroud)
一个类似的错误报告提到了旧内核上 r8169 内核模块的奇 MAC 地址,给出了一些建议的解决方法。
工作 1
启动后停止并启动内核模块:
sudo rmmod r8169 && sudo modprobe r8169
Run Code Online (Sandbox Code Playgroud)
工作 2
从您的 Natty live CD 启动 - 运行ifconfig -a并记录 eth0 的 MAC 地址。
启动进入 oneiric。检查您的 udev 持久规则并将正确的 MAC 地址映射到 eth0
sudo cp /etc/udev/rules.d/70-persistent-net.rules /
sudo nano /etc/udev/rules.d/70-persistent-net.rules
Run Code Online (Sandbox Code Playgroud)
更改 MAC 地址。如果有疑问 - 请在您的问题中添加规则文件的内容。
| 归档时间: |
|
| 查看次数: |
3512 次 |
| 最近记录: |