Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm using Mint 10 with 2.6.35-32-generic

The PC has two Wired Ethernet cards. They're both the same. One is built into the motherboard, the other is a PCI-E card. I'm using the built in one, but neither are working anymore. The only change I've recently made to my system until my Ethernet stopped working was to install Mint KDE 12.04 64bit as a dual boot. The strange thing is, that the built in Ethernet card works fine in that every time. That kernel is a 3.2 one.

So all of a sudden, Ifconfig tells me that there's no eth0 showing.

dmesg | grep r816 gives me nothing.

I've checked out just about every launchpad/ask ubuntu/ubuntu forum link I can find and the best results I get are from here:

I've even tried the $(uname -r) option & the blacklist of the r8169 was already there from a couple of years ago, when I had a similar issue on this machine. Build-essentials is installed.

Attached is a copy of my Terminal commands for my latest attempt to get this working. I have no other way to connect to the internet on this machine so I had to copy and paste this into a new text file and transfer it to my laptop via USB.

root@DesktopBlack:~$ cd r8168-8.031.00/
root@DesktopBlack:~/r8168-8.031.00$ make clean modules
make -C src/ clean
make[1]: Entering directory `/home/badcam/r8168-8.031.00/src'
make -C /lib/modules/2.6.35-32-generic/build SUBDIRS=/home/badcam/r8168-8.031.00/src clean
make[2]: Entering directory `/usr/src/linux-headers-2.6.35-32-generic'
  CLEAN   /home/badcam/r8168-8.031.00/src/.tmp_versions
  CLEAN   /home/badcam/r8168-8.031.00/src/Module.symvers /home/badcam/r8168-8.031.00/src/modules.order
make[2]: Leaving directory `/usr/src/linux-headers-2.6.35-32-generic'
make[1]: Leaving directory `/home/badcam/r8168-8.031.00/src'
make -C src/ modules
make[1]: Entering directory `/home/badcam/r8168-8.031.00/src'
make -C /lib/modules/2.6.35-32-generic/build SUBDIRS=/home/badcam/r8168-8.031.00/src modules
make[2]: Entering directory `/usr/src/linux-headers-2.6.35-32-generic'
  CC [M]  /home/badcam/r8168-8.031.00/src/r8168_n.o
  CC [M]  /home/badcam/r8168-8.031.00/src/r8168_asf.o
  CC [M]  /home/badcam/r8168-8.031.00/src/rtl_eeprom.o
  CC [M]  /home/badcam/r8168-8.031.00/src/rtltool.o
  LD [M]  /home/badcam/r8168-8.031.00/src/r8168.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /home/badcam/r8168-8.031.00/src/r8168.mod.o
  LD [M]  /home/badcam/r8168-8.031.00/src/r8168.ko
make[2]: Leaving directory `/usr/src/linux-headers-2.6.35-32-generic'
make[1]: Leaving directory `/home/badcam/r8168-8.031.00/src'
root@DesktopBlack:~/r8168-8.031.00$ make install
make -C src/ install
make[1]: Entering directory `/home/badcam/r8168-8.031.00/src'
make -C /lib/modules/2.6.35-32-generic/build SUBDIRS=/home/badcam/r8168-8.031.00/src INSTALL_MOD_DIR=kernel/drivers/net modules_install
make[2]: Entering directory `/usr/src/linux-headers-2.6.35-32-generic'
  INSTALL /home/badcam/r8168-8.031.00/src/r8168.ko
  DEPMOD  2.6.35-32-generic
make[2]: Leaving directory `/usr/src/linux-headers-2.6.35-32-generic'
make[1]: Leaving directory `/home/badcam/r8168-8.031.00/src'
root@DesktopBlack:~/r8168-8.031.00$ insmod ./src/r8168.ko 
root@DesktopBlack:~/r8168-8.031.00$ mkinitramfs -o /boot/initrd.img-$(uname -r) $(uname -r)
Warning: No support for locale: en_NZ.utf8



root@DesktopBlack:~/r8168-8.031.00$ lspci -v
00:00.0 Host bridge: Advanced Micro Devices [AMD] RS780 Host Bridge Alternate
    Subsystem: Advanced Micro Devices [AMD] RS780 Host Bridge Alternate
    Flags: bus master, 66MHz, medium devsel, latency 32
    Memory at <ignored> (64-bit, non-prefetchable)
    Capabilities: [c4] HyperTransport: Slave or Primary Interface
    Capabilities: [54] HyperTransport: UnitID Clumping
    Capabilities: [40] HyperTransport: Retry Mode
    Capabilities: [9c] HyperTransport: #1a
    Capabilities: [f8] HyperTransport: #1c



03:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 03)
    Subsystem: Giga-byte Technology GA-EP45-DS5 Motherboard
    Flags: bus master, fast devsel, latency 0, IRQ 45
    I/O ports at ce00 [size=256]
    Memory at fdfff000 (64-bit, prefetchable) [size=4K]
    Memory at fdff8000 (64-bit, prefetchable) [size=16K]
    [virtual] Expansion ROM at fdf00000 [disabled] [size=128K]
    Capabilities: [40] Power Management version 3
    Capabilities: [50] MSI: Enable+ Count=1/1 Maskable- 64bit+
    Capabilities: [70] Express Endpoint, MSI 01
    Capabilities: [ac] MSI-X: Enable- Count=4 Masked-
    Capabilities: [cc] Vital Product Data
    Capabilities: [100] Advanced Error Reporting
    Capabilities: [140] Virtual Channel
    Capabilities: [160] Device Serial Number 03-00-00-00-68-4c-e0-00
    Kernel driver in use: r8168
    Kernel modules: r8169


root@DesktopBlack:~/r8168-8.031.00$ lsmod | grep r816
r8168                 237114  0 




root@DesktopBlack:~/r8168-8.031.00$ sudo ethtool eth0
Settings for eth0:
    Supported ports: [ TP ]
    Supported link modes:   10baseT/Half 10baseT/Full 
                            100baseT/Half 100baseT/Full 
                            1000baseT/Full 
    Supports auto-negotiation: Yes
    Advertised link modes:  10baseT/Half 10baseT/Full 
                            100baseT/Half 100baseT/Full 
                            1000baseT/Full 
    Advertised pause frame use: Symmetric Receive-only
    Advertised auto-negotiation: Yes
    Speed: 1000Mb/s
    Duplex: Full
    Port: Twisted Pair
    PHYAD: 0
    Transceiver: internal
    Auto-negotiation: on
    MDI-X: Unknown
    Supports Wake-on: pumbg
    Wake-on: g
    Current message level: 0x00000033 (51)
    Link detected: yes
root@DesktopBlack:~/r8168-8.031.00$ dmesg | grep r816
[ 1527.700515] r8168 Gigabit Ethernet driver 8.031.00-NAPI loaded
[ 1527.700568] r8168 0000:03:00.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18
[ 1527.700597] r8168 0000:03:00.0: setting latency timer to 64
[ 1527.700731] r8168 0000:03:00.0: irq 45 for MSI/MSI-X
[ 1527.769143] r8168: This product is covered by one or more of the following patents: US5,307,459, US5,434,872, US5,732,094, US6,570,884, US6,115,776, and US6,327,625.
[ 1527.769148] r8168  Copyright (C) 2012  Realtek NIC software team <[email protected]> 



root@DesktopBlack:~/r8168-8.031.00$ sudo ifconfig eth0 up



root@DesktopBlack:~/r8168-8.031.00$ sudo ifconfig -a
eth0      Link encap:Ethernet  HWaddr 1c:6f:65:21:68:98  
          inet6 addr: fe80::1e6f:65ff:fe21:6898/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:16 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:240 (240.0 B)  TX bytes:3213 (3.2 KB)
          Interrupt:45 Base address:0xe000 

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:38307 errors:0 dropped:0 overruns:0 frame:0
          TX packets:38307 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:1111719 (1.1 MB)  TX bytes:1111719 (1.1 MB)

tap0      Link encap:Ethernet  HWaddr de:ba:fd:35:c8:bf  
          inet addr:10.0.1.1  Bcast:10.255.255.255  Mask:255.0.0.0
          inet6 addr: fe80::dcba:fdff:fe35:c8bf/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:35 overruns:0 carrier:0
          collisions:0 txqueuelen:500 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

vboxnet0  Link encap:Ethernet  HWaddr 0a:00:27:00:00:00  
          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)

root@DesktopBlack:~/r8168-8.031.00$ nano /etc/network/interfaces


auto lo
iface lo inet loopback

#auto eth0
#iface eth0 inet dhcp

iface eth0 inet static
address 192.168.1.2
netmask 255.255.255.0
pre-up /usr/sbin/ethtools -S eth0 speed 1000 autoneg off
gateway 192.168.1.1
network 192.168.1.0
broadcast 192.168.1.255

#auto eth1
#iface eth1 inet dhcp

#iface eth1 inet static
#address 192.168.1.10
#netmask 255.255.255.0
#gateway 192.168.1.1
#network 192.168.1.0
#broadcast 192.168.1.255

#sudo ifdown eth0
#sudo ifup eth0

#sudo ifdown eth1
#sudo ifup eth1

So, everything (to me) looks as if it should be working. But, it's not. As soon as I restart (I've tried the power off completely method many times as well) I lose everything, and am back to square one.

I'm stuck.

Could the two cards be conflicting with each other? I might try removing one while I wait for an answer here.

Why would Kubuntu KDE 12.04 work (the kernel I assume) and not my old trusted Mint 10 anymore? Is one possible solution to upgrade the Kernel? Or, is that a really bad thing to do? Can I reverse that if needed?


I found this post and this command actually gets my Eth0 working.

Then I tried

sudo service network-manager stop

followed by

sudo dhclient3 eth0

But, with a restart, I lose everything again. I note that even with

sudo dhclient3 eth0

My Gnome Panel Network Manager still shows no Ethernet connection, and a left-click displays

Network Manager is not running

So, that led me to this Launchpad bug report

and the solution described in there gets the Network Manager Applet working correctly.

service network-manager stop
rm /var/lib/NetworkManager/NetworkManager.state
service network-manager start

I also added to NetworkManager.state [main]:

NetworkingEnabled=true

This means that as soon as I reinstall the driver, the ethernet is back up and running, but I still lose the driver on restart. So now, I'm guessing that all I need now is for my Ethernet driver to not disappear upon restart.

share|improve this question
    
please post your solution as an answer, not as an edit –  Sathya Jul 29 '12 at 4:57

1 Answer 1

Self answer by OP

This is what I did to get the driver settings to stick:

sudo -s
nano /etc/initramfs-tools/modules --- added r8168 (saved)
update-initramfs -v -u -k `uname -r`

...and that was it. I've restarted several times now and even with a full power-off.

I got that information from Ubuntuforums.org

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.