Page 1 of 3

Posted: Sun Oct 08, 2006 12:12 am
by Gandalf2
Where I live, there is a D-Link router, connected to the internet via PPPoA. There are two computers connected to this router, one is WindowsPC which is quite happy with ther internet, the other is LinuxPC. I cannot get the internet to work on LinuxPC (Mandrake v9 i think) no matter what settings I change. I can connect to the router by typing in 192.168.1.1 in my browser, but nothing else works. Though, bizzarely, sometimes one website works (http://news.bbc.co.uk) but I've yet to see any other works.

And, in a move of confusion, WindowsPC can ping router & LinuxPC, the router can ping WindowsPC and LinuxPC, BUT LinuxPC cant ping anything!!! /mad.gif" style="vertical-align:middle" emoid=":mad:" border="0" alt="mad.gif" />

Posted: Sun Oct 08, 2006 12:22 am
by FreeBeer
My guess is that the setting for the gateway address, or perhaps DNS address, isn't set on the Linux box properly. My Linux box (Fedora 5) never had a problem with the router, so I didn't have to tinker with its settings, so I can't tell you how, specifically. (I'm a Linux noob.)

Posted: Sun Oct 08, 2006 12:39 am
by Gandalf2
I've tried putting the IP address of the router into every last darn input box I can find and it still won't work /mad.gif" style="vertical-align:middle" emoid=":mad:" border="0" alt="mad.gif" /> Currently I've given it a manual IP address of 192.168.1.22, which as I say, WindowsPC and the router are quite happy with, but linu isn't. Using DHCP produces no better results.

Posted: Sun Oct 08, 2006 3:40 am
by Next
Maybe the wireless/ethernet card driver you are using for Linux isn't correct/very good. See if you can find a better driver?

Posted: Sun Oct 08, 2006 10:14 pm
by Gandalf2
Tried that - it's an ancient inbuilt thing, which intel stopped supporting long ago. /doh.gif" style="vertical-align:middle" emoid=":doh:" border="0" alt="doh.gif" />

Posted: Sun Oct 08, 2006 11:12 pm
by beauty
What does 'netstat' report?
Do you have a 'default' route that goes through the router?
Can you ping external addresses by IP Address? (e.g. 4.2.2.1)

I suspect you are just missing a default route.

You may need to add the default route to your network card as well with 'ifconfig' ...

Posted: Mon Oct 09, 2006 2:41 pm
by SaiSoma
you're on mandrake 9. login as root, type setup. i'm fairly certain that was the command for mandrake then.

setup your network again. if the command isn't setup, maybe it was draknet? i highly recommend using dhcp if your dlink has it turned on. if it doesn't, then make sure you set your gateway AND dns server to use your router ip.

Posted: Tue Oct 10, 2006 6:08 pm
by Gandalf2
SaiSoma - thanks for your help but niehter of those commands worked - all the setup I've done has been through the GUI. the gateway and DNS server are set up to be the router's IP, though it insists on the primary DNS server being 127.0.0.0 (or was that 127.0.0.1??) with the secondary DNS server being the router's IP.

I reset everything up again, with DHCP and leavking a few other things blank, and the internet still doesn't work, BUT now I can ping the router, WindowsPC and the internet! /huh.gif" style="vertical-align:middle" emoid=":huh:" border="0" alt="huh.gif" /> /ninja.gif" style="vertical-align:middle" emoid=":ninja:" border="0" alt="ninja.gif" />

Beauty - netstat produced pages & pages of info... I typed "info netstat" and from that, did netstat -r, which I hope is useful....
Destination Gateway Genmask Flags Window irtt Iface
192.168.1.0 * 255.255.255.0 U 0 0 eth0
127.0.0.0 * 255.0.0.0 U 0 0 lo
default mygateway.ar7 0.0.0.0 UG 0 0 eth0

The router IP address is 192.168.1.1.

Any more help would be appriciated....!

Posted: Wed Oct 11, 2006 9:50 pm
by Dogbones
dhcp should set things up correctly for you, but obviously it isn't.

On the windows machine
-open a cmd window
-type 'ipconfig'
-type 'nslookup'

Post the output of those two

Now on the linux machine you already posted the output of 'netstat -r', now post the output of 'netstat -rn'
The -rn will resolve mygateway.ar7 into an ip address you can check against the output of ipconfig above.
Also post the output of '/sbin/ifconfig' (you can leave out the block for 'lo')

Now type 'nslookup' on the linux machine and then type freeallegiance.org after the >

Code: Select all

You should get something like
> freeallegiance.org
Server:         192.168.1.2
Address:        192.168.1.2#53

Non-authoritative answer:
Name:   freeallegiance.org
Address: 205.134.242.91
>
Is the Server reported by nslookup on the linux box the same as that reported by windows? It should be. I am guessing it is not. You need to re-setup your dns on the linux box. One of the problem's with linux is there are 20 different ways to do things and only 2 or 3 will actually work, it all makes perfect sense if you know what you are doing. What specific version of linux are you running? and what tool/utility are you using to setup the network? (this may be dependent on what window manager you are running, etc, so you'll need to tell us which one you are using).

Posted: Thu Oct 12, 2006 3:15 am
by beauty
If you can ping the internet then the problem is only DNS.

You can manually edit a file /etc/resolv.conf
It should look something like:

nameserver 204.xxx.yyy.1
nameserver 204.xxx.yyy.2

Set the IP addresses to the correct DNS servers that you want to use (Pull them off of your Windows box or ask your ISP what to put in there)

After that I think you should be good...