# Network is unreachable!

## mikkime23

My network has suddenly become unreachable when I try and establish a connection. I have pinged my HUB and it says:

```
connect: network is unreachable
```

but the thing is, it was fine when i was in my live CD (universal)

----------

## omriil

seems like a routing problem

what's your computer's & hub's IP addresses?

----------

## mikkime23

my computers ip address is 192.168.1.166 and my router is 192.168.1.254.

----------

## omriil

try to do the following command as root:

```
route add -net 192.168.1.0 netmask 255.255.255.0 dev eth0
```

----------

## mikkime23

I got this error:

```
SIOCADDRT: no such device
```

----------

## omriil

Are you sure your network is configured correctly?

what's the output of

```
ifconfig eth0
```

----------

## mikkime23

Yet again it returned an error!

```
eth0: error fetching interface information. device not found
```

----------

## omriil

your NIC is not configured right, that's another issue.

1. what's the output of lspci?

2. did you compile support for your NIC when configuring your kernel? if compiled as module, did you load it?

3. did it work before? (both in other OS's and\or dists, current gentoo installation)

----------

## mikkime23

the output of lspci didnt work, there was a bash error. It does work on other O/S's, coz i am on XP now. switching back and forth. what do to mean NIC. If thats my ethernet card, i think so.

----------

## baal

After omriil: 

have you done any changes to your kernel lately?

if it worked before, what have you been doing lately? 

The most probable solution is to recompile your kernel with the support for your NIC...

Then try 

```
# /sbin/ifconfig eth0 192.168.1.166 up
```

and

```

# route add -net 192.168.1.0 netmask 255.255.0 dev eth0

# route add default gw 192.168.1.254
```

----------

## davidc

 *mikkime23 wrote:*   

> the output of lspci didnt work, there was a bash error.

 

You most likely do not have the package "pciutils" installed.  To be able to use lspci, first run:

```
# emerge pciutils
```

 *Quote:*   

>  It does work on other O/S's, coz i am on XP now. switching back and forth. what do to mean NIC. If thats my ethernet card, i think so.

 

If this is a fresh installation of Gentoo, did you remember to compile the correct drivers for your network card into the kernel?  Did you use genkernel?  What kernel version are you using?  What make and model is your network card?

----------

## mikkime23

the make and model of my network card is a VIA Compatable Fast Ethernet Adapter, i have been using gentoo-sources (i think u me 2.4.26-gentoo-r6 though) i have no idea what u mean when u say fresh install

----------

## mikkime23

here is my LSPCI output.

```

0000:00:00.0 Host bridge: VIA Technologies, INC P4M266 Host Bridge

0000:00:01.0 PCI: VIA Technologies, INC VT8633 [APOLLO PRO266 AGP]

0000:00:0b.0 Communications Controller: Lucent Electronics LT Win Modem

0000:00:10.0 USB Controller: VIA Technologies, INC. USB (rev80)

0000:00:10.1 USB Controller: VIA Technologies, INC. USB (rev80)

0000:00:10.2 USB Controller: VIA Technologies, INC. USB (rev80)

0000:00:10.3 USB Controller: VIA Technologies, INC. 2.0 (rev82)

0000:00:11.1 ISA Bridge: VIA Technologies, INC. VT82C589/B/686A/B PCI Bus Master IDE (rev06)

0000:00:11.5 Multimedia Audio Controller: VIA Technologies, INC. VT8233 AC97 Audio Controller (rev50)

0000:00:12.0 Ethernet Controller VIA Technologies, INC. VT6102 [Rhine-II] (rev74)

0000:01:00.0 VGA Compatible Controller: nVidia Corporation: Unknown Device 0322 (reva1)

```

----------

## mikkime23

-BUMP-

I really need some help here, i am buggered to know whats happening.

----------

## omriil

just have a look at the device section at make menuconfig, look for VIA ethernet card and enable it (make sure you load it if you compile it as a module)

----------

## mikkime23

I have enabled it , and, once again, it didnt work.

----------

## mikkime23

hey guys, my gentoo plainly cannot see my ethernet card. this is relly starting to piss me off. i HATE Windows and want to go to Gentoo, but i cant unless i have my internet working, and for that to occur, i will need my ethernet card to be read.

----------

## moocha

Compile it into the kernel, not as a module (press Y, not M, on the Via Rhine option).

----------

## travisau

when you enabled the ethernet card in the kernel did you actually rebuild the kernel and reinstall it?  Also you selected module did you do a make modules; make modules_install?

try typing in dmesg | more and looking through the output there for something related to your ethernet card.  Your problem is almost certainly somewhere in the kernel.

----------

## mikkime23

i have done that and it still doesnt work. i use this command after i configured it:

```
make dep && make bzImage modules modules_install

cp arch/i386boot/bzImage /boot; cp System.map /boot
```

is that what i am supposed to do?

----------

## Ateo

Actually, you'd want to run

```
make dep && made && make modules modules_install

mount /boot

cp arch/i386/boot/bzImage /boot
```

Also, if you compiled the your NIC driver as module, you'll need to add it to /etc/modules.autoload/kernel-2.4. I suggest just compiling it into your kernel for simplicities sake.

The bottom line is you don't have support for you NIC in your kernel.

P.S. You can't ping hubs.Last edited by Ateo on Mon Dec 27, 2004 10:21 am; edited 1 time in total

----------

## tumbak

 *mikkime23 wrote:*   

> i have done that and it still doesnt work. i use this command after i configured it:
> 
> ```
> make dep && make bzImage modules modules_install
> 
> ...

 

and your grub conf? are you loading the newly compiled kernel?

please post

```
#cat /boot/grub/grub.conf
```

```
#dmesg
```

```
#cat /usr/src/linux/.config
```

----------

## stm

are you sure you have the correct module compiled and loaded?

----------

## mikkime23

 *tumbak wrote:*   

> 
> 
> and your grub conf? are you loading the newly compiled kernel?
> 
> please post
> ...

 

I cant actually post that because i am using lilo.

----------

## moocha

OK, this is it. I have yet to see any Gentoo installation that failed when following the installation handbook step by step. I suggest you do that, and your troubles will just magically go away. Hm?

----------

## mikkime23

well mooch, i did follow the bloody handbook step by step so dont get smart with me. i am just trying to find some help.

----------

## etnoy

The handbook has all you need to get your card working. I see from your error that you obviously are missing your ethernet card drivers. Re-check your kernel configuration, or try 

```
modprobe via-rhine
```

 before ifconfig.

----------

## mikkime23

I appretiate everyones help, sorry for getting a little hot headed, but i have got my ethernet card working now, the only thing is, my adsl start command always times out. Here is the error.

```

/usr/sbin/adsl-start:  Line 199:  1583 Terminated                   $CONNECT  "$@" > /dev/null > 2/&1
```

I dont know what is going on here!

----------

## brendaniabbatis

There can definitely be something more than kernel drivers here, because this exact problem hit me today, and I have made no changes to my kernel. Something I emerged yesterday clobbered the network configuration and broke eth0.

----------

## mikkime23

could this have something to do with my dhcp???

----------

## brendaniabbatis

 *brendaniabbatis wrote:*   

> There can definitely be something more than kernel drivers here, because this exact problem hit me today, and I have made no changes to my kernel. Something I emerged yesterday clobbered the network configuration and broke eth0.

 

Yeah it was baselayout, and it was /etc/modules.autoload.d/* which I had overwritten with etc-update   :Embarassed: 

After loading the modules, run 

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

/etc/init.d/net.eth0 start
```

 and if that works, you are only missing the module in /etc/modules.autoload.d/Last edited by brendaniabbatis on Thu Jan 06, 2005 8:30 pm; edited 1 time in total

----------

## mikkime23

i dont get where you are coming from!

----------

## DarKRaveR

 *Ateo wrote:*   

> 
> 
> P.S. You can't ping hubs.

 

Sure you can ping some   :Wink:  .

----------

## brendaniabbatis

 *mikkime23 wrote:*   

> i dont get where you are coming from!

 

Uhh... I was still on eth0. I don't know how to work ADSL.

----------

