Skip to main content

Short note: DHCP

Short answer

DHCP automatically assigns IP addresses and network settings using DORA (Discover, Offer, Request, Ack) over UDP ports 67 and 68. It supports dynamic, automatic, and manual allocation with lease renewal.

Write a short note on DHCP.

Dynamic Host Configuration Protocol (DHCP) is an application layer protocol (RFC 2131) that automatically gives a host its network configuration: IP address, subnet mask, default gateway, DNS server addresses and lease time. It removes manual configuration and reduces address conflicts. It is a client/server protocol using UDP: server port 67, client port 68.

Four-step process (DORA)

  1. DHCP Discover: the new client broadcasts to 255.255.255.255 looking for a server.
  2. DHCP Offer: the server offers an unused IP address, mask, lease time (broadcast or unicast).
  3. DHCP Request: the client broadcasts the chosen offer (so other servers know).
  4. DHCP Ack: the server confirms and the client starts using the address.
 Client                         DHCP Server
   |---- Discover (broadcast) ----->|
   |<------- Offer -----------------|
   |---- Request ------------------>|
   |<------- Ack -------------------|

Features

  • Address allocation: dynamic (leased from a pool), automatic (permanent) and manual (fixed by MAC address, reservation).
  • Leases are renewed at 50% (T1) of the lease time; the address returns to the pool when released or expired.
  • A DHCP relay agent forwards requests across routers so one server can serve many subnets.
  • Useful in intranets, Wi-Fi, ISPs and laptops that move between networks.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Internet and Intranet chapter 3 questions →