TTR Networks

What is DUID?

DHCP Unique Identifier

A DUID (DHCP Unique Identifier) is the identifier a DHCPv6 client or server uses to identify itself, playing the role a MAC address plays in DHCP for IPv4.

In DHCPv4 the server mostly recognises a client by its hardware address. DHCPv6 (RFC 8415) instead has every client and server carry a DUID, a variable-length value that is meant to stay the same across reboots and even across network interface changes. There are several types: DUID-LLT is built from a link-layer address plus a timestamp, DUID-EN from a vendor's enterprise number plus an identifier the vendor chooses, DUID-LL from a link-layer address alone, and DUID-UUID from a UUID (RFC 6355). Alongside the DUID, a client uses an IAID (Identity Association Identifier) to tell apart the separate requests it makes, for example one per interface, so a server identifies each lease by the pair of DUID and IAID.

DUIDs matter most with DHCPv6-PD, where an ISP or upstream router delegates a whole prefix, such as a /56 from 2001:db8::/32, to a customer router. The server ties the delegation to the client's DUID, so a stable DUID means you keep the same prefix, and every address on your LAN stays put. If the DUID changes, perhaps after reinstalling the router, replacing hardware or cloning a virtual machine, the server sees a new client and may hand out a different prefix, renumbering your whole network. That is why many routers let you set the DUID by hand, and why server-side reservations are usually written against the DUID rather than a MAC address. Cloned VMs sharing one DUID is a common cause of two clients fighting over the same lease. The IPv6 on VyOS lesson uses DHCPv6 prefix delegation between two routers.

Lessons that use DUID

  • IPv6 on VyOS: setup and routingBeginner · 55 min

    Number a site from an ISP's /48 on VyOS: WAN and blackhole routes, SLAAC with Router Advertisements, handing a /56 to a downstream router statically and with DHCPv6 prefix delegation, and the forward firewall IPv6 needs because there's no NAT. Every output comes from a real two-router VyOS lab.

  • Building a network lab on an Apple Silicon MacBeginner · 45 min

    Run real network labs on an M-series Mac: native FRR and Linux containers, x86-only images through Rosetta, and full x86 VyOS VMs under QEMU in Docker, with the pitfalls that stop most people and a starter lab that mixes all three.

Related terms