100%
GRIMOIRE
GrimoireDindon CorpusSynthesis VolumesThe Foundation of Iron
FRENAR
RATIO
THE FOUNDATION OF IRON · COURSE MATERIAL · WEEK 20
◆◆◆
DHCP
ON THE ACQUIRED NETWORK BASE
Week 20 of 26 · Block 7 — DHCP and DNS
8h theory · 27h practice
◆ WEEKLY LEARNING OBJECTIVES

1. Understand the DHCP protocol operation (DORA)
2. Install and configure a DHCP server on Linux
3. Manage address leases and exclusion ranges
4. Configure inter-VLAN DHCP relay
5. Diagnose common address assignment problems

◆◆◆
⚠ WARNING — SHELF LIFE OF VERSIONS REFERENCED HERE

This material references isc-dhcp-server. Other DHCP implementations exist (dnsmasq, Kea DHCP). The instructor adapts the configuration to the implementation actually available and maintained at the time of delivery.

Amine RAITI · Infrastructure Architect & SRE
Public document · CC BY-NC-SA 4.0 · AI Powered by Amine
Opération Dindon
RATIO
COURSE OUTLINE · 8H
THEORY GUIDING THREAD — DHCP
20.1 · DHCP protocol — DORA exchange3h
— DORA: Discover (client broadcast looking for a server), Offer (server proposes an address), Request (client confirms), Acknowledge (server confirms the assignment)
— Lease concept: the duration for which the address is reserved for the client
— Parameters distributed with the address: mask, gateway, DNS servers (direct link with Week 19 and Week 21)
20.2 · DHCP server configuration2h
— Structure of a DHCP configuration file: subnet, range, options
— Static reservations: always assign the same address to a machine identified by its MAC address
— Exclusion ranges: exclude addresses from the pool (for fixed-IP devices)
20.3 · Inter-VLAN DHCP relay3h
— Problem: DHCP Discover is a broadcast that does not cross VLAN/router boundaries
— Solution: the DHCP relay (DHCP helper) on the router/layer-3 switch forwards the Discover as unicast to the centralised DHCP server
— Relay configuration: the DHCP server's IP address is configured on each VLAN interface of the router — direct link with Week 18 (VLANs) and Week 19 (routing)
RATIO
EXERCISE 1 · DHCP SERVER INSTALLATION AND CONFIGURATION · 14H

Equipment: already-configured Linux VM (DHCP server), client VMs (Linux and Windows), the Week 18 VLAN topology.

(2h) Installing the DHCP server on the Linux VM, configuring a first simple pool for a single subnet (address range, mask, gateway, lease duration).
(3h) Testing automatic assignment on a client VM: verify the VM receives an address from the configured range, check the DHCP server logs to see the DORA exchange.
(3h) Configuring a static reservation for a VM identified by its MAC address, verifying this VM always receives the same address.
(3h) Extending to 3 DHCP pools corresponding to the 3 VLANs from Week 18, configuring ranges and VLAN-specific options (different gateways per VLAN).
(3h) Configuring the DHCP relay on the router (each VLAN interface pointing to the centralised DHCP server), testing assignment from a client in each VLAN.
SOLUTION — EXERCISE 1

DHCP relay verification: a client in VLAN 20 must receive an address from the VLAN 20 pool configured on the DHCP server, even if the DHCP server is physically in VLAN 10 — the relay forwards the Discover across the VLAN boundary.

Common mistake: forgetting to configure the gateway (routers option) in the DHCP pool — the client receives an address but cannot communicate beyond its subnet.

RATIO
EXERCISE 2 · DIAGNOSIS AND ADVANCED ADMINISTRATION · 13H

Equipment: the DHCP system configured in Exercise 1, Wireshark.

(3h) Capturing the full DORA exchange with Wireshark: identify each packet (Discover, Offer, Request, Ack), read the key fields (CHADDR, siaddr, yiaddr, options).
(3h) DHCP failure simulation: pool saturation (all addresses assigned), client receiving a wrong configuration (wrong gateway), DHCP server unreachable from a VLAN — diagnosis and fix.
(4h) Lease administration: view the list of active leases, manually revoke a lease, observe the client's re-request.
(3h) Writing a DHCP configuration reference document covering the 3 pools, reservations, and diagnostic procedures.
SOLUTION — EXERCISE 2

DHCP fields to identify in Wireshark: CHADDR = client's MAC address, yiaddr = proposed/assigned IP address, siaddr = server's IP address, option 3 = gateway, option 6 = DNS servers, option 51 = lease duration.

◆ SUMMARY SHEET — WEEK 20 SELF-ASSESSMENT
1. I can describe the DORA exchange and the role of each message.
2. I can configure a DHCP server with pool, mask and options.
3. I can configure a static reservation by MAC address.
4. I can explain why the Discover does not cross VLAN boundaries.
5. I can configure an inter-VLAN DHCP relay.
6. I can capture and analyse a DORA exchange with Wireshark.
7. I can diagnose a DHCP address assignment failure.
8. I can administer the active leases of a DHCP server.