What's new

Advice on setting up 2 routers

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

You are wrong. DHCP broadcasts at OSI layer 2. DHCP may be an application layer but it broadcasts at layer 2 the switch layer which is important for this thread. This means you need to break the broadcast domains between DHCP servers as stated above.

PS
I am talking in a general sense the client actually requests an IP from a DHCP server. It is the client that starts the broadcast at layer 2 not the DHCP server. Sorry if I was confusing. The DHCP server receives all DHCP broadcast from the client within a broadcast domain and will respond based on a OSI layer 2 client request. If you have 2 DHCP servers in the same broadcast domain they will both receive the DHCP broadcast for an IP from the client and will respond accordantly. The client will respond to the first request that it receives from the first DHCP server that responds. So you need to divide the domains so only one DHCP server responds. DHCP requests start as a broadcast and not directed traffic.
 
Last edited:
DHCP is not a layer 2 protocol. The device sending the DCHP request uses the IP 255.255.255.255 with a source of 0.0.0.0 to the subnet it is in.

http://searchnetworking.techtarget.com/definition/DHCP




I don't see how a switch at layer 2 would affect a broadcast domain. Switches separate collision domains not broadcast.[/QUOTE

I sometimes use VLANs to control broadcast domains. All my VLANs are assigned networks. So in the above when I mentioned VLAN I mean a VLAN with an assigned network. I guess this could cause confusion. It is just automatic with me.

If you plug 2 routers with DHCP server installed into 1 switch. Then both networks from the routers are running on the switch at the same time. When a client requests a DHCP IP address it is a broadcast because the client has no IP, the broadcast is send to both router DHCP servers since a broadcast is non-directed traffic it flows to both router's DHCP servers. They both respond with different IPs because each router has a different network defined to it. The client accepts the first DHCP offer. So clients will randomly receive different IP networks when you have multiple routers plugged into the same switch. So if you do not limit the broadcast domain then your clients will randomly be assigned IPs from different networks. There is no control over what IP or network the client will be in.

So do you see how why I recommend a VLAN between routers? If you split the router's broadcast domain you can control which network and IP a client will be assigned because there is only one DHCP server per broadcast domain.
 
Last edited:
Of course it has to go through layer 2 because it doesn't know the MAC of the DHCP server and sends out a broadcast on that layer so the frame gets forwarded. That doesn't mean it is a layer 2 protocol. Switches don't dpo
You are wrong.

I guess that settles it then.

Anyway, of course the DHCP will have to traverse layer 2 just like any other application layer protocol. It doesn't mean for instance HTTP is layer 2 because it must go through layer 2.

If you plug 2 routers with DHCP server installed into 1 switch. Then both networks from the routers are running on the switch at the same time.

DHCP works on the LAN side of a router, unless your router supports a helper address for remote DHCP. It will not be broadcasted to the WAN side.

As much as this has been entertaining to say the least, I think we are derailing this thread now.
 
Of course it has to go through layer 2 because it doesn't know the MAC of the DHCP server and sends out a broadcast on that layer so the frame gets forwarded. That doesn't mean it is a layer 2 protocol. Switches don't dpo
dpo? not sure
Anyway, of course the DHCP will have to traverse layer 2 just like any other application layer protocol. It doesn't mean for instance HTTP is layer 2 because it must go through layer 2.
HTTP does not broadcast at layer 2. It is a directed traffic. So it is not relevant either to network design.

DHCP works on the LAN side of a router, unless your router supports a helper address for remote DHCP. It will not be broadcasted to the WAN side.
I agree and stated above. Not relevant to this thread. The broadcast domain is key to the design of the network which is layer 2. My 2 router scenario explains why. Do you agree? I feel like you are missing this.
I don't think the WAN side plays into this not in my thinking. Both routers are connecting on the LAN side to the switch. WAN is WAN and yes I agree it will not be broadcast to the WAN side. More than likely routers on this site have firewalls including NAT. So if you stack routers you will doing double NAT which I recommend against. People still do it.

As far as DHCP, the network needs to be designed for layer 2 which is relevant to this thread. DHCP at application layer does not matter because it is not driving the network design.

As far as your design I can not read it when it expands because it is too small so I do not where you are coming from.

Where in theory of this am I wrong? Maybe I glossed over a bunch of facts but I tried to hit key points. I can fill in where needed.
 
Last edited:
So we are all on the same page.

This is one of many ideas.
My idea with 2 routers with different WAN IPs from the ISP. You will need a small switch at the modem. It will provide a place to plug in both routers on the WAN connection so they can get an IP from the ISP.
The routers will each connect to a switch in separate broadcast domains because you have 2 DHCP servers. Since there is no load balancing, devices on one router will use that router as their default gateway. The only way to split the load is by physical separation, router1 or router2. Clients need to be placed under each router's network. If you use static IP addressing and turn off DHCP it would mean you would need to config each client with a separate IP and maintain them which I find to be a real problem. So I would never create a network without DHCP unless it was a non-client network, point-to-point network, etc.

If you want to share resources then there needs to be a network between routers with each router pointing at each other. This can be a route statement or a routing protocol.

You can use 1 switch with multiple VLANs for all. Remember I always assign a network IP to every VLAN.

You could also use 1 router with dual WAN ports which would have load balancing. It might be a better solution. Plus only 1 DHCP server to manage.

I would use a layer 3 switch which would change the way DHCP works since I use DHCP on the switch not in the router.

This is very expandable. As long as you have ISP IP addresses you can add more routers. For each router added you will need a VLAN.
 
Last edited:

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top