networkingIT support

Stands for: Dynamic Host Configuration Protocol

The protocol that gives an IPv4 host its address and settings, such as mask, router and DNS servers, usually on a time-limited lease.

RFC 2131 states its aim plainly: clients should require no manual configuration. The first lease takes four messages, known as DORA from Microsoft's guides, and a Windows client that gets no valid address is likely to fall back to an APIPA address in 169.254.0.0/16.

RFC 2131 (March 1997) defines three allocations: automatic (permanent), manual (an administrator's choice, conveyed by DHCP) and dynamic, a lease for a limited time, the only one that lets addresses be reused. Client messages go to UDP port 67 and server messages to port 68. RFC 2132 options carry the settings, among them 1 (subnet mask), 3 (router), 6 (DNS servers), 51 (lease time) and 53 (message type).

Lease times are seconds, read against the client's own clock. At T1, by default half the lease, the client unicasts a DHCPREQUEST to its server to renew; at T2, 87.5% by default, it broadcasts to any server; if the lease expires first, it must stop using the address and start again. A client that cannot reach a server may keep its address until the lease runs out, which is why a short server outage often goes unnoticed.

Across subnets a relay agent, which Microsoft also calls an IP Helper, passes the client's broadcast to a configured server and fills giaddr with the address of the interface it arrived on, and the server picks the pool from it. Microsoft's checklist for clients without an address covers the server service, the relay agents on routers or VLAN switches, a firewall blocking UDP 67 and 68 and an exhausted scope. DHCP has no authentication, so a rogue server on the segment is the other classic fault, the one DHCP snooping blocks.

Also known as: dynamic host configuration protocol, dhcpv4, dhcp server, dhcp client

← All glossary entries