# absolutely no network connection [solved]

## derbrain

Hello,

I'm getting some weird networking problems on my laptop (acer travelmate 292). First, everything worked fine using ifplugd. But since a couple of weeks (I don't remember if I made some updates or anything) I'm not able to connect to the network with linux. So I had to use Windows :ewww:

I tried two different Knoppix live cds and my old gentoo installation disk. And I am never able to get an IP address (dhcpcd gets a timeout). The LEDs near the plug don't blink, so it seems that the network card is just not working.

the only output of 

```
dmesg | grep eth0
```

 that seems like an error message is "NETDEV WATCHDOG: eth0: transmit timed out". What does this mean? And why does it work on Windows?

I've gone through tons of forum pages, but didn't find any solution. I've tried net-setup, i've tried setting it up manually (without dhcp), I've tried disabling apic... Does anyone have another suggestion?Last edited by derbrain on Mon Dec 19, 2005 2:57 pm; edited 1 time in total

----------

## alienjon

What does lspci show? (or is it a pcmcia card?)

----------

## derbrain

 *alienjon wrote:*   

> What does lspci show? (or is it a pcmcia card?)

 

No, it's an onboard chip. This is what lspci says about network cards (as I have to type it down, I report only that. Tell me if there should be other important things):

```
0000:02:01.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)

0000:02:02.0 Network controller: Intel Corporation PRO/Wireless 2200BG (rev 5)
```

----------

## thasheep

To me it sounds like you don't have the right kernel driver installed

In the latest version of gentoo-sources, there are two drivers that look like they support your card - 8139cp and 8139too.

You can configure them by going (in make menuconfig of the kernel source) - Device Driver -> Network Device Driver -> Ethernet (10 or 100Mbit) and selecting all of (as modules or compiled in) Ethernet (10 or 100Mbit), Generic Media Independent Interface device support, EISA VLB PCI and on board controllers, and then selecting both (as modules) the RealTek RTL-8139 C+ PCI Fast Ethernet Adapter support (EXPERIMENTAL) and RealTek RTL-8129/8130/8139 PCI Fast Ethernet Adapter support. I say do these as modules so you can test each and work out which is right.

```

# modprobe -r 8139cp && modprobe 8139too    # ensure 8139too is loaded and 8139cp isn't

# /etc/init.d/net.eth0 start   # assuming you've set up your network as per the gentoo handbook

# ping google.com       # (test network)

# /etc/init.d/net.eth0 stop

# modprobe -r 8139too && modprobe 8139cp

# /etc/ini.d/net.eth0 start

# ping google.com

```

If either or both modules work then you can now use your network. If you really want you can recompile the kernel and compile in the driver you like but that's not needed. (one of) The modules should be autoloaded anyway.

----------

## derbrain

That didn't work   :Crying or Very sad: 

```
# modprobe -r 8139cp && modprobe 8139too    # ensure 8139too is loaded and 8139cp isn't

# /etc/init.d/net.eth0 start   # assuming you've set up your network as per the gentoo handbook
```

This brings eth0 up, but dhcp ends in a timeout.

```
# /etc/init.d/net.eth0 stop

# modprobe -r 8139too && modprobe 8139cp

# /etc/ini.d/net.eth0 start
```

Here it says that eth0 does not exist. If i do a ifconfig, I see only lo. With the other driver i saw eth0, but there was that timeout.

----------

## thasheep

alright, stick with the 8139too driver.

Now, it looks like something's up with your network configuration, especially dhcp.

Check your /etc/resolv.conf (get values from windows network configuration)

try 'dhcpd eth0' and ping someone. If that doesn't work then try 'dhcpd -HD eth0' and ping.

If both of them fail, it looks like you'll have to configure manually.

Now, follow the instructions in the gentoo handbook here or here

You can get all the numbers you need by booting into windows and checking your network configuration. I forget what tab it's on but you should be able to find it.

If all else fails, post your /etc/conf.d/net, /etc/resolv.conf and the values you found from windows.

----------

## derbrain

I followed the instructions, but all settings have already been set correctly. It didn't work.

 *thasheep wrote:*   

> try 'dhcpd eth0' and ping someone. If that doesn't work then try 'dhcpd -HD eth0' and ping.

 

I don't have dhcpd. Do you mean dhcpcd? That gives me a timeout. If I try to ping, it says "connect: Network is unreachable". And the LEDs are still not flickering.

This is my /etc/resolv.conf:

```
domain chello.at

nameserver 192.34.133.13

nameserver 192.34.133.20
```

I have exactly the same resolv.conf on my desktop PC which is on the same network. They are both connected to a d-link router.

In Windows, it says it's a "Realtek RTL8139/810x Family Fast Ethernet NIC". IP- and DNS-address are received automatically.

In /etc/conf.d/net, the uncommented lines are:

```
config_eth0=( "dhcp" )

dhcpcd_eth0="-t 5"
```

----------

## thasheep

Sorry, I did mean dhcpcd.

Remove the 'dhcpcd_eth0="-t 5"' line from /etc/conf.d/net. It tells dhcpcd to timeout after 5 seconds. Maybe that isn't long enough.

If that still doesn't work, have a go at setting it up as a static ip.

Mine is something like this

```

config_eth0=( "my.ip.addre.ss netmask 255.255.255.192 broadcast x.y.z.255" )

routes_eth0=( "default gw x.y.z.193" )

```

I got those values because that was what the network configuration (using dhcp) under windows said.

----------

## derbrain

You mentioned that one of the modules should be loaded automatically, but it isn't. I had to run modprobe manually.

 *thasheep wrote:*   

> Remove the 'dhcpcd_eth0="-t 5"' line from /etc/conf.d/net. It tells dhcpcd to timeout after 5 seconds. Maybe that isn't long enough.

 I know what that parameter means. I inserted it because I don't want to wait so long at booting time when the cable is not connected. Anyways, removing that line has no effect (except that the timeout comes later, of course).

And when the LEDs don't blink (which means that there is no data transmitted) it's clear that there is a timeout. I think it's a driver problem rather than an IP/dhcp-related problem.

 *thasheep wrote:*   

> If that still doesn't work, have a go at setting it up as a static ip.

 I tried it out with your config (I changed the subnet mask and the broadcast of course). When I start /etc/init.d/eth0, "Bringing up eth0" gives an "OK", but "Adding routes" gives me "!!". Ifconfig lists eth0 with the correct IP, but pinging says "Destination Host Unreachable". The LEDs are still dark.

----------

## thasheep

If you can remember what kernel (and kernel config) you were using before when it worked, see if you can use that again.

Or, check out http://www.scyld.com/rtl8139.html and see if that's any help

----------

## derbrain

Aaaaaaaaargh, I hate Windows and that non-standard acpi-BIOSes...

I never shut down my system in Windows, I use hibernate. But yesterday I made some updates and had to shut it down. Today I started linux and saw that the transfer-LEDs were on. So I modprobed 8139too, started net.eth0, and everything works fine.

It seems that in hibernation Windows turns the network card off in a strange way, and Linux can't turn it on. I had similar problems with pugging in/out the AC cable. I don't know if it works if I use Winsdows' hibernation mode again, but at least I know what I have to do when it happens again. Maybe a BIOS update would help, too.

Next time I'll buy a more standard-conform notebook...

----------

## thasheep

Good to hear it's solved

The problem to which you're referring is known as 'having windows'. I can normally be fixed by executing the following commands:

```
su

cp -r /mnt/windows/Documents\ and\ Settings ~/

umount /dev/hda1

mke2fs -j /dev/hda1

echo /dev/hda1 /mnt/lotsofspacewherewindowsusedtobe ext3 noatime 0 0 >>/etc/fstab

mount /dev/hda1

```

This'll give you much more useful hard drive space too.

Sorry if you actually rely on windows but it pisses me off and I need to relieve some stress after an exam.

----------

