2

Good afternoon, I'm learning how to build a network, and I'm trying to add a DHCP server for all VLAN's, but I don´t understand how to make it work for all hosts regardless of whether they are on the other router.

My network topology is:

Network

Any ideas or guidelines I can use.

  • 1
    Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can provide and accept your own answer. – Ron Maupin Feb 19 '18 at 17:56
1

If you're using Cisco devices, you can configure a single DHCP server for all vlans. On the vlan interface, add the command

Ip helper-address a.b.c.d

Where a.b.c.d is the dhcp server. Then you configure scopes for each vlan.

3

Each VLAN is a broadcast domain, so essentially you have to put a DHCP server on each VLAN.

There are three possibilities:

  1. Put a dedicated DHCP server in each VLAN.

  2. Connect a central (multi-homed) DHCP server to each VLAN.

  3. Put a DHCP relay agent on each VLAN (most often a configuration option in a switch or a router) and have it relay requests to the central DHCP server.

These methods can also be mixed.

3

HP Procurve uses the same command, IP helper-address 111.222.333.444 as Ron mentioned is used for Cisco IoS. Cisco SMB switches like the SG300 use ip dhcp relay address 111.222.333.444. The list is endless really. That's not my purpose. I just wanted to add the "why" you need to use this command if you want to use one DHCP server for multiple VLANs/subnets.

Since a layer 2 network is broadcast domain the DHCP request from a computer normally will stay within its VLAN because it's a UDP broadcast. Broadcast, as you may know, can't traverse a layer 3 boundary (a router or layer 3 switches). By adding the IP helper-address command at the gateway the layer 3 device can forward the UDP request from the computer for DHCP to the server (and other protocols such as TFTP(port 69), DNS (port 53), BOOTP (port 67, 68), TACACS (port 49), the older Time service (port 37, not NTP), NetBIOS (port 137, 138).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.