I have a cable Internet connection. Behind this cable modem is my LinkSys E4500 router. Any computer plugged into the LAN on this router can get online no problem. I have a second router in the bedroom where my computers are. It's a D-Link DIR-615. So we have the routers connected from LAN to LAN. Nothing's in the WAN of the D-Link.

E-4500
10.0.0.2 /24
DHCP

D-Link
10.0.0.1 /24
No DHCP

I can log into the E-4500 no problem with any computer in the bedroom that's plugged into the D-Link, but I can't get online. The computers attached to the LAN of the D-Link can ssh into one another so we have connectivity in this respect. Just no Internet access. We have DHCP reservation on the E-4500, and I can confirm that the MACs on the computers in the bedroom attached to the D-Link exactly match the IP addresses in this table. ifconfig shows exactly that. Subnet mask is /24 as well.

Any suggestions would be appreciated.

11-12-2012

atreyu

Hello,

Do you have DNS servers assigned to the clients attaching to the DLink router? Also, do you have a default gateway assigned to them?

On one of these clients (attached to the DLink but not on the 'net), do:

Code:

# show routing table - display gw, if there
route -n

Code:

# show DNS settings
cat /etc/resolv.conf

I am guessing that the default gw should be the ip address of the Linksys, but not sure. you can check by running the route command above on one of its clients. to add it temporarily to test, on a DLink client, as root do:

Code:

route add default gw 10.1.1.1

or whatever the router ip address should be. if that works, let us know and we'll tell you where to put it to make it permanent.

then populate the DNS settings file, /etc/resolv.conf. first get the DNS servers from a client on the Linksys clients - just look in /etc/resolv.conf on one of them. then create the file on the DLink clients, e.g.:

Code:

nameserver 1.2.3.4
nameserver 1.2.3.5

as to why the Linksys clients already have the right info, it is probably b/c DHCP is enabled and the Linksys is passing the default gw and DNS info to its clients properly. This is not happening on the DLink, I guess.

11-12-2012

Lazydog

Router to router or switch to switch connections require a cross-over cable.

11-12-2012

alexanderkmoore

atreyu, thanks for the reply. I'll check this out right after work today. D-Link is actually DD-WRT firmware and it's set to router mode, not gateway...however...Lazydog, so I need a crossover, even if it's LAN to LAN and the WAN port on the secondary router is not being used?

11-13-2012

atreyu

Quote:

Originally Posted by alexanderkmoore

D-Link is actually DD-WRT firmware and it's set to router mode, not gateway

I have absolutely no idea what that means. I would think either would work for getting clients onto the internet. Here's a question: can the Dlink itself get out onto the net? There is usually a way to test that from within the webpage of the router itself.

Keep us posted.

11-13-2012

Lazydog

Quote:

Originally Posted by alexanderkmoore

Lazydog, so I need a crossover, even if it's LAN to LAN and the WAN port on the secondary router is not being used?

Correct. LAN to LAN is the same as PC to PC. Both require a crossover cable.

11-15-2012

alexanderkmoore

I wasn't feeling well for the past couple of days.
I didn't even play Halo 4. Imagine that.
Well, all is good now.

I added the default gateway as you suggested
Also I noticed that three nameservers were populated in the /etc/resolv.conf of my laptop that is wireless to the LinkSys (and online) so I added those to the resolv.conf on one of my machines behind the D-Link. All is good now!
I now have a new entry in the routing table (the 10.0.0.1) which is the D-Link:

Could you clarify something, tell me if there's a flaw in my logic here. I'm just trying to understand the reason why this works.
How does the D-Link know to forward the request (let's say an HTTP request) to the LinkSys?
The LinkSys, my Xbox and another computer are wired into the LAN ports of the D-Link.
When a computer A on the D-Link sends out an HTTP request or whatever, it first hits the D-Link
The D-Link broadcasts this request to all ports because they're in the same broadcast and collision domain (as the D-Link is basically being used just as a switch)
Computer B and the Xbox (both also on the D-Link) both ignore this as it's not for them
But the LinkSys, being attached also to the LAN of the D-Link will accept this request and forward it out to the Internet
So it appears that I don't need to mess around with configuring routing tables at all (or even manually configuring a route at all) on the D-Link to tell it how to find the LinkSys

And lazydog, I suppose newer equipment must be able to autodetect this difference in pinout and adapt.

11-16-2012

atreyu

Quote:

Originally Posted by alexanderkmoore

I didn't even play Halo 4. Imagine that.

so is it as good as the original Halo when that came out?

Quote:

I now have a new entry in the routing table (the 10.0.0.1) which is the D-Link:

You should not need two gateways. I'd remove the DLink one, and then make sure you can still get out.

As root:

Code:

route del default gw 10.0.0.1

(assuming the DLink is 10.0.0.1, I think it is).

What is your distro? You need to make your default gw permanent in a distro-specific config file, so that it be there next time you reboot, or restart networking.

Quote:

Could you clarify something, tell me if there's a flaw in my logic here. I'm just trying to understand the reason why this works.
How does the D-Link know to forward the request (let's say an HTTP request) to the LinkSys?

Think of the DLink as a dumb hub, it is just letting traffic go through it. If it had a WAN connection to the internet, and you supplied the DLink ip address as a gateway, the in-bound traffic destined for the internet would just use its WAN port and it would never see the LinkSys (unless you had but one default gw and it pointed to the LinkSys). But you're not using the DLink WAN port, so traffic is getting thru to the LinkSys. You're also specifying the LinkSys as a default gw (I think), which makes packets want to go thru that device anyway.

Quote:

The LinkSys, my Xbox and another computer are wired into the LAN ports of the D-Link.
When a computer A on the D-Link sends out an HTTP request or whatever, it first hits the D-Link
The D-Link broadcasts this request to all ports because they're in the same broadcast and collision domain (as the D-Link is basically being used just as a switch)
Computer B and the Xbox (both also on the D-Link) both ignore this as it's not for them
But the LinkSys, being attached also to the LAN of the D-Link will accept this request and forward it out to the Internet

pretty much, yes.

Quote:

So it appears that I don't need to mess around with configuring routing tables at all (or even manually configuring a route at all) on the D-Link to tell it how to find the LinkSys

You should not need to do any configuration on the DLink to forward traffic to the LinkSys, correct. But I believe you DO need to make the LinkSys your default gw on all your clients.

11-16-2012

alexanderkmoore

I hear the original Halo was a pretty big hit when it came out. Not sure what the reception is for this game but considering they sold 220 million copies the first day, I'd say people love it. Graphics are twice as sharp it seems as they were in Halo: Reach. It's epic. Play it on Legendary lol

Ok cool so I'll blow away that old route when I get home in a few.

I'm on SuSE 12. something.

And thanks for clarifying all that for me. Can't wait to try this out when I get home.

11-16-2012

atreyu

Quote:

Originally Posted by alexanderkmoore

I hear the original Halo was a pretty big hit when it came out. Not sure what the reception is for this game but considering they sold 220 million copies the first day, I'd say people love it. Graphics are twice as sharp it seems as they were in Halo: Reach. It's epic. Play it on Legendary lol

i haven't bought a game since Halo 3 so Halo 4 will probably wind up in my X-mas stocking...

Quote:

I'm on SuSE 12. something.

I'm not too familiar with SuSE, but I know it uses YaST to do network configuration. I think there is also a netconfig script. See this bit of SuSE documentation.

And there is always modifying files by hand, which is fun. Check for these files: