Articles

IPv6 in practice: address families, neighbour discovery and dual stack

Three mechanisms, three failures: address scopes, neighbour discovery and dual stack.

Reading: 5 minNetworking

Article cover: IPv6 in practice: address families, neighbour discovery and dual stack

IPv6 is three changes carried by one protocol, and they fail separately. A host holds several addresses of different scopes; it can configure itself from a router advertisement rather than from a server; and a dual-stack host must choose which address a connection uses when a name resolves to both families. Those are three separate documents, and treating them as one is why a rollout can look finished while half its traffic fails.

The address families a host actually uses

An IPv6 interface normally holds more than one address, and scope decides what each can reach. Global unicast addresses carry a routing prefix, a subnet ID and an interface ID (rfc4291.txt lines 490–500); except for prefixes beginning with binary 000 that interface ID is 64 bits — “have a 64-bit interface ID field (i.e., n + m = 64)” (lines 511–512), the source of the /64 link convention. Unique local addresses, fc00::/7, are “not expected to be routable on the global Internet” (rfc4193.txt lines 30–33). Link-local addresses, fe80::/10, are what a host has before anything is configured: every interface must have one (rfc4291.txt line 151), and routers do not forward them off the link (lines 591–592).

what a host holds                 who fills it                      mechanism
-------------------               ----------------------------      ------------------------
link-local address (fe80::/10)    the host, when the link comes up  RFC 4862 / RFC 4291
global address (or ULA)           a router advertisement            SLAAC, RFC 4862
                                  or a DHCPv6 server                RFC 8415
default router list               router advertisements             RFC 4861
DNS and other options             router advertisement (O flag)     RFC 4861 / RFC 8415
                                  or DHCPv6

Router advertisements: what a host is told, and by whom

A host with no configuration still has a link-local address and the all-nodes multicast group. Routers “advertise their presence together with various link and Internet parameters either periodically, or in response to a Router Solicitation message” (rfc4861.txt lines 604–607), and one advertisement can carry a prefix, a default-router lifetime and a link MTU.

The trust model is the operational part: the document states there is “no mechanism to determine which neighbors are authorized to send a particular type of message (e.g., Router Advertisements)”, so any neighbour on the link can advertise itself as a router — even with authentication in place — and cause denial of service (lines 4464–4467). A host keeps whatever routers advertise, whether or not they belong to the network (lines 637–638); the hop limit of 255 only confines this to the local link (lines 865–866).

Stateless and stateful configuration are two design choices

SLAAC and DHCPv6 are not versions of each other: “DHCPv6 can operate either in place of or in addition to stateless address autoconfiguration (SLAAC)” (rfc8415.txt lines 33–34). Stateless configuration “requires no manual configuration of hosts, minimal (if any) configuration of routers, and no additional servers” (rfc4862.txt lines 128–130): form a link-local address, form global addresses from advertised prefixes, verify uniqueness (lines 123–126), the last through Duplicate Address Detection on a “tentative” address (line 271). Stateful DHCPv6 keeps the record, clients on UDP 546 and servers and relays on 547 (rfc8415.txt lines 1301–1302), and the router picks between them with the “Managed” and “Other configuration” flags (rfc4861.txt lines 1090–1092, 1099–1100).

Dual stack is address selection, not two networks

Running both families on one interface does not make them one path. When a name resolves to both an AAAA and an A record, something must order the candidates, and that something is a rule set rather than a preference for the newer protocol. RFC 6724 defines that ordering, including “Rule 9: Use longest matching prefix” (rfc6724.txt line 847) and a policy table that “gives IPv6 addresses higher precedence than IPv4 addresses” (line 1095). When the IPv6 path is silently broken, the ordering becomes the failure; RFC 8305 removes the wait by racing both and cancelling the losers once a connection succeeds (rfc8305.txt lines 352–354).

What changes for the filter and the log behind the host

Three properties change the tools. ICMPv6 is part of the base: the base protocol “MUST be fully implemented by every IPv6 node” (rfc4443.txt lines 130–132), so a filter that discards it wholesale breaks Neighbour Discovery. A packet “may carry zero, one, or more extension headers, each identified by the Next Header field” (rfc8200.txt lines 399–400), so a rule that reads only the fixed header is reading a header that need not describe the transport. With no translation at the edge, the address a filter matches and a log records is the host’s own — and it has several legitimate spellings, which is why a canonical text form exists (rfc5952.txt lines 23, 322–323).

Limits and the common mistake

  • A host believes any router on the link — nothing in the base protocol authenticates an advertisement (rfc4861.txt lines 4464–4467).
  • Nobody necessarily owns the address — stateful assignment leaves a record; stateless assignment does not.
  • Renumbering is not a relabel — advertised lifetimes retire an old prefix.
  • An IPv4 policy is not an IPv6 policy — a rule written for one family says nothing about the other.
  • The MTU failure is silent — a link below the 1280-octet floor (rfc8200.txt lines 1378–1379).

The common mistake is reading an enabled IPv6 stack as a working IPv6 path: the preferred family may be dead and nothing races it.

Level and prerequisites

L4 — architecture and design. It assumes the L1 vocabulary of prefixes, subnets and the default gateway, and the L1 account of resolution. The address plan belongs to the address-space design sheet, and the egress consequence of an untranslated address to the egress sheet.

Where to go next

References

  • RFC 8200, Internet Protocol, Version 6 (IPv6) Specification — Standards Track, July 2017. Extension headers and the Next Header chain (lines 399–400); the IPv6 minimum link MTU (lines 1378–1379); Path MTU Discovery (lines 1393–1394).
  • RFC 4291, IP Version 6 Addressing Architecture — Standards Track, February 2006. Addresses assigned to interfaces (line 146); no broadcast, superseded by multicast (lines 130–131); the required link-local address (line 151); the global unicast format and the 64-bit interface ID (lines 490–512); link-local scope and the router-forwarding prohibition (lines 578, 591–592).
  • RFC 4193, Unique Local IPv6 Unicast Addresses — Standards Track, October 2005. “not expected to be routable on the global Internet” (lines 30–33).
  • RFC 4861, Neighbor Discovery for IP version 6 (IPv6) — Standards Track, September 2007. Router Solicitation and Advertisement (lines 604–607); advertised prefixes and the stateless hint (lines 645–646, 657); the default router list (lines 637–638); the M and O flags (lines 1090–1092, 1099–1100); the Hop Limit 255 bound (lines 865–866); the threat list and the absence of authorisation (lines 4411–4413, 4464–4467).
  • RFC 4862, IPv6 Stateless Address Autoconfiguration — Standards Track, September 2007. The three-step process (lines 123–126); no manual configuration and no servers (lines 128–130); the tentative address (line 271).
  • RFC 8415, Dynamic Host Configuration Protocol for IPv6 (DHCPv6) — Standards Track, November 2018. DHCPv6 in place of or in addition to SLAAC (lines 33–34); the client and server UDP ports (lines 1301–1302).
  • RFC 6724, Default Address Selection for IPv6 — Standards Track, September 2012. Destination selection rule 9 (line 847); the default policy table’s IPv6 precedence (line 1095).
  • RFC 8305, Happy Eyeballs Version 2: Better Connectivity Using Concurrency — Standards Track, December 2017. Racing the two families and cancelling the losing connection attempts once one succeeds (lines 352–354).
  • RFC 4443, Internet Control Message Protocol (ICMPv6) for the Internet Protocol Version 6 (IPv6) Specification — Standards Track, March 2006. ICMPv6 as an integral part of IPv6, fully implemented by every node (lines 130–132).
  • RFC 5952, A Recommendation for IPv6 Address Text Representation — Standards Track, August 2010. The canonical textual representation (line 23); the failed search across spellings (lines 322–323).
Nodrius Field Kit — cover

Get the Nodrius Field Kit

Enter your email and we'll send you the complete Field Kit: eight technical resources in one download.

Your email address is sent to Nodrius and used to deliver the Field Kit to you by email. Marketing messages are separate and optional: the checkbox does not affect your download, and you are only added to our updates list if you tick it. Privacy Policy.

Privacy & cookies

This site does not use cookies, analytics or tracking, and it does not profile you. There is nothing technical to switch off, so Accept and Reject change nothing about how the site works: either choice lets you browse everything normally.

The only difference is what your browser remembers: two entries in local storage — your choice here, so this notice is not shown again, and a marker that the Field Kit offer has already been made — so the offer is presented once and not on every page. They contain no identifier, they are not shared with anyone, and the site sets no cookie for either.

What we do with your data
How your email address is used when you ask for a Resource, how long it is kept and which rights you have — in the Privacy Policy.
What the site stores in your browser
Two entries in local storage — your choice on this notice and whether the Field Kit offer has been shown — and no cookies, no session storage, no third-party content: in the Cookie Policy.