# eth0 not working

## TeknoMan

hello, 

my eth0 not working since i've emerged kde on my gentoo linux machine.

i've specified the following lines on /etc/conf.d/net:

config_eth0=("192.168.0.2 netmask 255.255.255.0")

routes_eth0=("default gw 192.168.0.1")

config_eth0=("dhcp")

dhcp_eth0="nodns nontp nonis"

How can i do?

thanks a lot! bye  :Wink: 

----------

## frostschutz

get rid of the syntax errors?

----------

## NeddySeagoon

TeknoMan,

Its probably not related to your KDE install. As frostschutz said, the format of your net file is not correct, welll, not unless you have a very old install.

Look in the /etc/conf.d/net.example file to see what it should look like.

If your eth0 has never worked when you boot your own install, you may have other problems too.

----------

## TeknoMan

there are no syntax errors, when the system init there are the following lines:

* Starting eth0

*    Bringing up eth0

*       192.168.0.2

*    Adding routes

*       default gw 192.168.0.1 ...

but when i ping an internet site, there is a 100% of packet loss and the network doesn't work

thanks & bye

----------

## NeddySeagoon

TeknoMan,

What do you have in your /etc/resolv file?

You need at least 

```
nameserver <IP of nameserver>
```

Your router probably runs a caching nameserver, so thats a good choice.

Run ifconfig -a  How many eth interfaces do you have ?

Run lsmod.  Is eth1394 listed ?

Run lspci, post the line(s) that describe your Ethernet interfaces.

Can you ping by number e.g. ping 216.239.57.99 (thats google.com) ?

----------

## TeknoMan

the /etc/resolv file is empty

i have 2 eth interfaces, eth0 and lo

eth1394 is not listed

lspci: command not found!

and i can't ping google, i've tried to ping google since this morning!

what can i do? thank 1000 4 helping me!

bye

----------

## NeddySeagoon

TeknoMan,

Boot the liveCD to run lspci.  You need to

```
emerge pciutils
```

to have the command in your own install.

When your network is working while you run the liveCD, make a note of the content of /etc/resolv.conf (sorry I got the name wrong in my last post). It needs to have the same content when you boot your own install.

How many Ethernet ports do you have on your system?

If you have more than one, they can change names between booting the liveCD and booting your own install.

Did you use genkernel to make your kernel?

Do you have firewire?

----------

## TeknoMan

i have 1 ethernet port, i have firewire and i didn't use genkernel, i have manually compiled the kernel.

i have noticed one thing....i've tried to emerge pciutils directly from my pc and the result is that my PC can't connect to HTTP (The server answer with error: 403 Forbidden) but with FTP the ethernet working!  :Shocked: 

have you any idea?  :Question: 

bye

----------

## NeddySeagoon

TeknoMan,

The mirror you are trying to use is down. In /etc/make.conf you have an entry 

```
GENTOO_MIRRORS=
```

Try changing it to 

```
GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/\

                http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/ \

                http://gentoo.inode.at/ \

                http://ftp.easynet.nl/mirror/gentoo/ \

                http://ftp.heanet.ie/pub/gentoo/ "
```

which gives you a choice of 5 european morrors.

You don't need your own install of lspci to get the information I'm after. The lspci on the liveCD is OK.

----------

## TeknoMan

output of lspci:

0000:02:08.0 Ethernet controller: Intel Corporation 82801CAM (ICH3) PRO/100 VE (LOM) Ethernet controller (rev 42)

thank 4 your support  :Very Happy: 

----------

## NeddySeagoon

TeknoMan,

You have a choce of drivers for that Ethernet interface. Lets check you kernel

Boot Gentoo and do the following

```
cd /usr/src/linux

grep ETH1394 .config

grep E100 .config

grep EEPRO .config
```

what do you get for each grep ?

----------

## TeknoMan

For ETH1394: # CONFIG _IEEE1394_ETH1394 is not set

For E100: CONFIG_E100=y; # CONFIG_E1000 is not set

For EEPRO: # CONFIG_EEPRO100 is not set

thx 1000 4 your interesting   :Smile: 

bye

----------

## NeddySeagoon

TeknoMan,

Thats good, one of the drivers for your Ethernet is built into your kernel.

Lets check your route now. What does 

```
route -n
```

 say ?

----------

## TeknoMan

output of route:

Destination: 192.168.0.0 Gateway: 0.0.0.0 Genmask: 255.255.255.0 Flags: U Metric = Ref = Use = 0 Iface eth0

Destination: 127.0.0.0 Gateway: 127.0.0.1 Genmask: 255.0.0.0 Flags: UG Metric = Ref = Use = 0 Iface lo

Destination: 0.0.0.0 Gateway: 192.168.0.1 Genmask: 0.0.0.0 Flags: UG Metric = Ref = Use = 0 Iface eth0

----------

## NeddySeagoon

TeknoMan,

Thats right too. Your interface is up, the routing table is right. All thats left is that some other device has been assigned eth0, so its not on the interface you think it is. These other things include another RJ-45 port, Ethernet over firewire, both of which we have already ruled out.

What about a built in wireless device or any oth form of networking that provides ethX stye logical interfaces ?

----------

