Router behind Comcast Router--does network address of Router make a difference?

GOBB409

Distinguished
Jun 9, 2011
17
0
18,510
To clarify, I am connecting a D-Link DIR-615 router to one of Comcast's current modem/routers. I want to keep the networks separate--at least I don't want computers connected to the Comcast to be able to "see" computers connected to the DIR-615. (I would leave the Comcast available to "guests". I know I need to therefore connect the WAN port of the 2nd router to a LAN port on the first with an ethernet cable. I also know that the addresses of the two routers cannot be identical. I believe I understand correctly that I should leave NAT on in the 2nd router, as well as DHCP--or I can turn DHCP off and specify static IP addresses that are within the subnet of the 2nd router for the computers I want connected there.

Here is what I am unclear about and need knowledgeable advice on:

The Comcast router is natively addressed at 10.0.0.1. D-link router default is 192.168.0.1, though I have often changed the 3rd field. The typical subnet mask, 255.255.255.0, is the same for both routers.

1) Does it make any difference what address I use for this 2nd router, so long as it is not the same as the address for the Comcast router (natively 10.0.0.1)?
2) Is there any benefit at all in having the first two fields of the two routers be the same? For example, 10.0.X.X.
3) Is there any benefit in making the address of the second router within the local DHCP address range of the first router? For example, 10.0.0.1 (1st) and 10.0.0.2 (2nd router), if the Comcast router's DHCP address range for clients is 10.0.0.2-100? If I do that, does this allow devices on either router to see those connected to the other router?
4) Do any of these choice provide for better speed or greater reliability while keeping the second router's lan isolated and unseen by those with the local network of the 1st router?

Sorry if this seems complicated, but as I said, I am looking for replies from those knowledgable about this.

Thanks for taking the time.

Michael
 
Solution
Lots in your post but you are correct in most of your assumptions.

The reason people use static address on the second router wan port and maybe even the lan on the second router is for port mapping. Say I needed some machine on the internet to access a device behind the second router. You would in the main router map the port to the second router and then on the second router map the port to the actual machine. You need all static IP to do this port mapping. In your case you do not have that requirement so you might as well use DHCP because then you don't have to worry.

The DNS you can set to anything you like. Some people set them to the router and let the router proxy it. I tend to give the end user machine actual internet...

GOBB409

Distinguished
Jun 9, 2011
17
0
18,510
Note: Reading again what I wrote before, I realize that my #3 above may have confused a LAN to WAN connection with a LAN to LAN connection. Since I created an address for the 2nd router that is inside the local LAN addresses of the 1st router, does this put both routers on the same LAN? Can this happen if I connect through the 2nd router's WAN port? Would it work if I provided Router #2 DHCP or static IP addresses that were not in Router #1's DHCP range? Would this allow computers behind #2 to "see" the computers behind #1?

Thanks,
Michael
 
It really makes no difference what IPs you choose as long as the wan and the lan on the second router are not in the same subnet. Generally it will not let you configure it incorrectly. You can run either DHCP or static it makes no difference.

No matter what you select the computers behind the second router will be able to access the computers behind the primary router. To them this is the internet and home routers to not enforce any rules related to private network block so if the ip is not local it is sent to the wan. No computers in the primary network will be able to access computers behind router 2 because of NAT, pretty much for the same reasons nobody on the internet can access a device in a local lan without port mapping
 

GOBB409

Distinguished
Jun 9, 2011
17
0
18,510
Thanks, that is a *very clear* answer. I just want to make sure I got it, as I have been trying to understand this part of routing for about 10 years now! This is not the easiest stuff to grok.

It sounds like there is no difference to a router how fast or how well it will route the data based on the structure of the subnets. --With the exception that if I were to use the same subnet, it simply won't work at all unless I use the 2nd router as a switch and go LAN port to LAN port--in which case everything is on the same network. In addition, this is the ONLY way I can do that (and then #2's IP address has to be within the subnet of #1.)

In the case of using the WAN port on#2 and *different* subnets, it won't affect speed or anything else if I used, say, 10.0.0.1 on router #1 and 10.0.2.1 to address #2 (which seems to involve "less translation" in NAT--that's my "apparent" logic); versus using 10.0.0.1 in #1 and 192.168.0.1 in #2. You are saying the routers will treat each of these the same way, right? (BTW, in all cases, the subnet mask remains 255.255.255.0)

You said choosing DHCP or Static makes no difference. I am confused about choosing a *Static* IP address for #2's WAN. My Router #2 has, under *Internet Connection Type* these choices:

"My Internet Connection Is:

Static IP
Dynamic IP (DHCP)
PPoE (Username/Password)
Etc...."

When I had DSL, I always used PPoE--that is what the provider required. Switching to cable and using the DIR615 as Router #2, I initially chose Dynamic IP (DHCP). But I am confused about whether this DHCP is the same as or different than the DHCP settings on the Network Settings page of the DIR615.

Is there any benefit at all to using *Static IP* for the Internet connection? If so, in #2 I am asked to set IP Address, Subnet Mask, Default Gateway, Primary DNS Server and Secondary DNS Server separately. --Or would Router #1 be taking care of the last two of these, the DNS? Otherwise, wouldn't I set IP Address as #2's WAN port, Subnet Mask as 255.255.255.0, and Default Gateway as #1's IP address?

I guess that using Dynamic IP is simpler, which is why I asked what benefit would it be to choose Static IP.

Finally, for a computer behind the 2nd router to access a computer behind the primary router, would I not need to know that computer's IP address? Those computers do not appear in "Network", right? Because they are not broadcasting their addresses into the 2nd router's LAN; but can be accessed through their IP address. If I understand you, a computer behind the 1st router cannot initiate contact to one behind the 2nd router even knowing the IP address of that computer.

If I can understand what's above, I think I can put this to rest!

Thanks again,
Michael
 
Lots in your post but you are correct in most of your assumptions.

The reason people use static address on the second router wan port and maybe even the lan on the second router is for port mapping. Say I needed some machine on the internet to access a device behind the second router. You would in the main router map the port to the second router and then on the second router map the port to the actual machine. You need all static IP to do this port mapping. In your case you do not have that requirement so you might as well use DHCP because then you don't have to worry.

The DNS you can set to anything you like. Some people set them to the router and let the router proxy it. I tend to give the end user machine actual internet DNS servers and let them directly access it. If your ISP did not tell you the one to use you can use 8.8.8.8 or 4.2.2.2

Nat is very stupid especially in a home router. It will take all ip in the lan and translate it into the single WAN ip. It really has no concept of subnet it pretty much just takes any packet it gets and translates the address. In a commercial router where you can have multiple wan and lan interfaces you can define much more complex nat rules as to what translates to what. You can for example translate each address in subnets 10.1.20.x to 10.100.20.x. In a home router the nat function will not delay the packets any more or any less based on the subnets you choose.
 
Solution

GOBB409

Distinguished
Jun 9, 2011
17
0
18,510
Thanks again! I really appreciate your answers.

Regarding the DNS thing--that is something I've just begun to look into. I don't see any indication in the cable router that Comcast provided me with of what DNS addresses they use, so I couldn't change it there (and I can't change the modem because I'm also using their telephone service.) If I set a Static IP address for my #2 router, the D-link, I can set DNS addresses there. It looks to me like most people make these alterations in the operating system's Internet Properties setup. Where would it be better to make any changes--in the router #2 that comes after the comcast modem/router, or in the OS's IP setup?

Michael
 
You likely get the DNS via DHCP from the ISP.

You can in most routers also give it to the PCs the same way. You can set the DNS to a fixed value or set it to the router/gateway address.

It is mostly a personnel preference. I tend to manually set it because I tend to not trust the ISP DNS and use the google one of 8.8.8.8