# SOLVED: LAN but no WAN

## Jeffro-Tull

Just got my Gentoo install fully operational (only took 3.5 attempts.  Not bad for a Gentoo n00b, I think), and was looking forward to emerging some bells and whistles overnight while I slept, but I guess not.

The compy:

k7 with a VIA VT8x motherboard, and an ADMTek NC100 ethernet controller running tulip.o and dhcpcd

the router:

Linksys WRT54G

Firmware Version 2.02.7

the modem:

Motorola Surfboard, though Roadrunner

the problem:

Mandriva 2006 (laptop over wifi) and 2006 (other desktop over cat5), and Windows XP Pro (both scenarios) have no problem with any of the network functionality.  At all.  My new Gentoo box, on the other hand, can only seem to do stuff over the LAN.  I ran ifconfig and got an IP address from the router.  I pinged my laptop with no problems at all.  I tried to ping www.gentoo.org and I got the following:

# ping www.gentoo.org

ping: unknown host www.gentoo.org

when I tried to emerge links I couldn't connect to any of the mirrors, either.  Any ideas?  like I said, I was kind of hoping to get kde installed overnight.  *sigh*Last edited by Jeffro-Tull on Sat Dec 16, 2006 6:46 am; edited 1 time in total

----------

## Zepp

What is the contents of /etc/resolv.conf?

----------

## Jeffro-Tull

uhhh... hmmm. only the following line:

# Generated by net-scripts for interface lo

domain tuxnet

now, I won't pretend to know much about networking, but it definitely seems like that configuration file is a bit lacking.  Don't I want stuff for interface eth0?   For what it's worth, /etc/resolv.conf on my laptop (mdv2007 on a Centrino Duo) has the following:

nameserver 24.92.226.9

nameserver 24.92.226.102

----------

## defenderBG

what about default gateway...?

show your ifconfig as well

(ping the 2 nameservers as well...)

----------

## Jeffro-Tull

# ping 24.92.226.9

--- 24.92.226.9 ping statistics ---

8 packets transmitted, 8 recieved, 0% packet loss, time 7007ms

rtt min/avg/max/mdev = 7.063/7.902/8.993/0.608 ms

#ping 24.92.226.102

--- 24.92.226.102 ping statistics ---

26 packets transmitted, 26 recieved, 0% packet loss, time 25006ms

rtt min/avg/max/mdev = 6.927/9.536/11.718/1.166 ms

#if config eth0

Link encap:Ethernet HWaddr 00:04:5A:51:58:27

inet addr:192.168.1.107 Bcast:192.168.1.255 Mask:255.255.255.0

UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU:1500 Metric:1

RX packets:2948 errors:0 dropped:0 overruns:0 frame:0

TX packets:76 errors:0 dropped:0 overruns:0 carrier:0

collisions:0 txqueuelen:1000

RX bytes:489448 (477.9 Kb) TX bytes:8360 (8.1 Kb)

Interrupt:10 Base address:0x2000

The gateway... that's the IP of the router, right?  Sorry, like I said, networking isn't my strong point.

192.168.1.1

----------

## iluxa

 *Jeffro-Tull wrote:*   

> # ping 24.92.226.9
> 
> The gateway... that's the IP of the router, right?  Sorry, like I said, networking isn't my strong point.
> 
> 192.168.1.1

 

We need output of 

```
/sbin/route -n
```

 command.

Also, copy "nameserver" lines from resolv.conf on your MDK machine to you Gentoo box.

----------

## Jeffro-Tull

I don't know if it'll help, but here's my dhcpd-eth0.info

IPADDR=192.168.1.107

NETMASK=255.255.255.0

NETWORK=192.168.1.0

BROADCAST=192.168.1.255

GATEWAY=192.168.1.1

DNS=24.92.226.9,24.92.226.102

DHCPSID=192.168.1.1

DHCPGIADDR=0.0.0.0

DHCPSIADDR=0.0.0.0

DHCPCHADDR=00:04:5A:51:58:27

DHCPSHADDR=00:0F:66:42:3F:A1

DHCPSNAME=''

LEASETIME=86400

RENEWALTIME=43200

REBINDTIME=75600

INTERFACE='eth0'

CLASSID='Linux 2.6.18-gentoo-r3 i686'

CLIENTID=00:04:5A:51:58:27

everything I understand in that looks right.

----------

## Jeffro-Tull

# /sbin/route -n

Kernel IP routing table

Destination        Gateway                Genmask                    Flags Metric Ref         Use   Iface

192.168.1.0       0.0.0.0                    255.255.255.0           U        0          0                 0   eth0

127.0.0.0            0.0.0.0                    255.0.0.0                    U        0          0                 0   lo

0.0.0.0                0.0.0.0                     0.0.0.0                        UG      0          0                0    eth0

copied the nameserver fields into gentoo's /etc/resolv.conf   still no dice.

----------

## Jeffro-Tull

just a thought.... I didn't install anything for PPPoE, because I don't know if I need it or not.  Is there a way to find out if it's necessary?

also, I can connect to the internet just fine when the install cd boots up.  Can I use that to download and emerge any packages I might be lacking that might be causing this problem?

----------

## microtechno

You could use the live cd but it would require a lot of effort, chrooting and all that (as i understand)

from the output of 

```
# /sbin/route -n 

Kernel IP routing table 

Destination Gateway Genmask Flags Metric Ref Use Iface 

192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 

127.0.0.0 0.0.0.0 255.0.0.0 U 0 0 0 lo 

0.0.0.0 0.0.0.0 0.0.0.0 UG 0 0 0 eth0 

```

The last line 0.0.0.0 should be sent to the gatway to the internet (your router).

what is inside 

```
/etc/conf.d/net
```

If you have set up your card using dhcp this file needs to know, otherwise it needs to be set staticly.

----------

## Jeffro-Tull

so, the last line of the output from /sbin/route -n should show the information of the gateway?  I'll have to look into this.

Too bad it'll be so long.  I just came back to school.  No room for a tower and monitor for that thing in the dorm.  I was hoping the at least get the thing networked so I could tackle anything else though ssh once I got here.  oh well.  I'll let you guys know how I make out once I get back.  Thanks for the help thus far.

----------

## lamberss

I have been having trouble with my ADMtek NC100 cards as well.  For some reason, I have to manually restart dhcpcd in order for DNS to work correctly.

```
ps -AL | grep dhcpcd 

kill #input number from above command here

dhcpcd eth1
```

I'm trying to figure out why I have to do this, because it makes maintaining some of the nodes in my cluster a real pain.

----------

## microtechno

"lamberss" have a look at this post.

Hope that it helps. (Sorry i dont know the exact answer)

https://forums.gentoo.org/viewtopic-t-408870-highlight-admtek+nc100.html

----------

## lamberss

 *microtechno wrote:*   

> "lamberss" have a look at this post.
> 
> Hope that it helps. (Sorry i dont know the exact answer)
> 
> https://forums.gentoo.org/viewtopic-t-408870-highlight-admtek+nc100.html

 

Thanks for the info.  I'll check to see if that works the next time one of the boxes is not busy.

I mainly wanted to put this up in case that was Jeffro-Tull's problem.  I can do things on my LAN all day but I can't talk to the WAN without killing dhcpcd and restarting it.  Hopefully the link you sent provides the answer to both our troubles.

----------

## lamberss

 *lamberss wrote:*   

>  *microtechno wrote:*   "lamberss" have a look at this post.
> 
> Hope that it helps. (Sorry i dont know the exact answer)
> 
> https://forums.gentoo.org/viewtopic-t-408870-highlight-admtek+nc100.html 
> ...

 

Well, that didn't help me fix it.

----------

## microtechno

sorry i dont know the answer to that one.

I had a problem a month or so ago, My server wouldnt work so I reinstalled gentoo. (I had some really big problems though, it was trying to install Xorg onto the box).

hope that you find something here on the forum.

----------

## Jeffro-Tull

Thanks for all the ideas.  After installing Gentoo on my laptop, I decided to come back to FrankenCompy and figure out what was wrong.  Turns out that when I installed it, I never copied the auto-generated /etc/resolv.conf file over.  So my compy never looked for the nameserver.

----------

