Home > Linux > Ubuntu 11.10 and Realtek RTL8111/8168B network problems

Ubuntu 11.10 and Realtek RTL8111/8168B network problems

I was big fan of Ubuntu distro, since 8x versions, but since 11.04 and Unity interface, I had to remove it from my home pc because my graphic card was old and I couldn’t run Unity or Gnome 3. So, in the meanwhile, I got brand new pc, and I installed Ubuntu 11.10 a few days ago.

First thing that i noticed was that  i got disconnected from the Internet every few minutes. Also, connection was really really slow. It is really annoying of course. So whats’ the solution for this problem?

First, check the model number of your ethernet controller, run from the console

lspci | grep Realtek
02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 06)

Check the driver your kernel is loading(actually this is the problem, it loads 8169 instead of 8168).

lsmod | grep r816*
r8169                  52788  0

I downloaded the driver with the command

wget http://r8168.googlecode.com/files/r8168-8.026.00.tar.bz2

Next, run these commands

cd ~/Downloads
tar vjxf r8168-8.026.00.tar.gz cd r8168-8.026.00
sudo ./autorun.sh

And if you are using kernel 3.0.x, you should pay attention that /src/Makefile has a bug, so file r8168.o is installed instead of r8168.ko. When autorun.sh finishes, run command

sudo cp src/r8168.ko   /lib/modules/3.x(your current kernel path)/kernel/drivers/net/

sudo depmod

sudo modprobe r8168

And that’s it, after this tweak, my network is flying, without breaking every few minutes. I really don’t get it how this bug has been around so long?

 

Categories: Linux
  1. No comments yet.
  1. No trackbacks yet.

Leave a comment