Questions? Call 1.800.716.8955

Chapter 9

IPv6 Addressing

Exam topics covered

1.8 Configure and verify IPv6 addressing and prefix

1.9 Describe IPv6 address types

  • 1.9.a Unicast (global, unique local, and link local)
  • 1.9.b Anycast
  • 1.9.c Multicast
  • 1.9.d Modified EUI-64

Foundation. IPv4 has carried the Internet for more than four decades, but its 32-bit address space ran out years ago. IPv6 is the long-term replacement: a 128-bit address space so large that every subnet in the world can have more host addresses than it could ever use. In this chapter you will learn how to read and write IPv6 addresses, how to shorten them correctly, how prefixes and /64 subnets work, the different address types (global unicast, unique local, link-local, multicast and anycast), and how hosts build their own addresses with modified EUI-64 and SLAAC. You will also meet the Neighbor Discovery Protocol, which replaces ARP, and finish by configuring and verifying IPv6 on Cisco routers. Expect several exam questions on address shortening, address-type recognition and EUI-64 calculation: they are quick points if you have practised them.

9.1 Why IPv6?

A 32-bit IPv4 address allows about 4.3 billion values. Phones, cloud servers and IoT devices consumed them, and IANA handed its last free /8 blocks to the Regional Internet Registries (RIRs) in 2011. The industry stretched IPv4 with VLSM, RFC 1918 private addressing and NAT/PAT, but NAT breaks end-to-end connectivity, complicates VoIP, peer-to-peer and some VPNs, and forces carriers into large carrier-grade NAT systems. IPv6 fixes the root problem with a vastly larger address space and several other improvements:

128-bit addresses (about 3.4 × 10

), so NAT is no longer needed to conserve space.

A simpler, fixed 40-byte header with no checksum; routers never fragment, and Hop Limit replaces TTL.

Autoconfiguration (SLAAC), so hosts can address themselves without a DHCP server. No broadcasts: targeted multicast is used instead, and ICMPv6 Neighbor Discovery replaces ARP.

IPv4 and IPv6 are not compatible on the wire, so most networks run dual stack, with both protocols enabled on every interface, during the long migration.

9.2 IPv6 Address Format

An IPv6 address is 128 bits long. Writing 128 ones and zeros would be impractical, so the address is written in hexadecimal. Each hex digit represents exactly four bits (a nibble), so 128 bits become 32 hex digits. The digits are written as eight groups of four separated by colons; each 16-bit group is informally called a hextet. Case does not matter: IOS displays upper case.

  • 8 hextets × 16 bits = 128 bits
  • 2001 0DB8 ACAD 0001 0000 0000 0000 0001
  • bits 1–16 17–32 33–48 49–64 65–80 81–96 97–112 113–128
  • 0000 1101 1011 1000
  • 0 D B 8
  • One hextet = 4 nibbles; each hex digit = 4 bits
  • 32 hex digits × 4 bits = 128 bits

Figure 9-1 Anatomy of an IPv6 address: eight 16-bit hextets, each made of four hexadecimal digits.

9.2.1 Hexadecimal refresher

You must convert between hex and binary quickly for EUI-64 and for prefixes that do not fall on a hextet boundary. Memorize Table 9-1.

Table 9-1 Hexadecimal digits and their 4-bit binary values

  • Hex Binary Hex Binary Hex Binary Hex Binary
  • 0 0000 4 0100 8 1000 C (12) 1100
  • 1 0001 5 0101 9 1001 D (13) 1101
  • 2 0010 6 0110 A (10) 1010 E (14) 1110
  • 3 0011 7 0111 B (11) 1011 F (15) 1111
  • 9.2.2 Rules for shortening IPv6 addresses

RFC 4291 allows two abbreviations, and RFC 5952 defines the one canonical way to write each address.

  • 1. Omit leading zeros in any hextet. 0DB8 becomes DB8 , 0001 becomes 1 , and 0000 becomes 0 . You may never remove trailing zeros: 2001 stays 2001 , because 2001 and 0201 are different values.
  • 2. Replace one run of consecutive all-zero hextets with a double colon ( :: ). The double colon may appear only once in an address; otherwise a reader could not tell how many zero hextets each :: represents.

RFC 5952 adds three conventions that the exam may test as “the correct” abbreviation: use :: on the longest run of zeros; if two runs are equally long, use it on the first (leftmost) one; and do not use :: to replace a single hextet of zeros (write :0: instead). Work through Table 9-2 before reading the answers. To expand an abbreviated address, count the hextets present and let :: fill in enough zero hextets to reach eight.

Table 9-2 Shortening and expanding practice

Full (preferred) form Shortest valid form

2001:0DB8:ACAD:0001:0000:0000:0000:0001 2001:DB8:ACAD:1::1

FE80:0000:0000:0000:0250:56FF:FEA1:2B3C FE80::250:56FF:FEA1:2B3C 2001:0DB8:0000:0001:0000:0000:0000:0000 2001:DB8:0:1::

  • 2001:0DB8:0000:0000:0001:0000:0000:0001 2001:DB8::1:0:0:1
  • 0000:0000:0000:0000:0000:0000:0000:0001 ::1 (loopback)
  • 2001:0DB8:00A0:0000:0BC0:0000:0000:000F 2001:DB8:A0:0:BC0::F

Exam alert

Watch for answer choices that drop trailing zeros ( 2001:DB8:AC:: for 2001:0DB8:AC00:: is wrong) or use :: twice. Both are classic distractors. When asked which addresses are valid abbreviations of a given address, expand each choice back to 32 digits and compare.

9.3 Prefixes and Subnetting

IPv6 does not use dotted-decimal subnet masks. Instead, the network part of an address is always shown with prefix-length notation, exactly like CIDR: 2001:DB8:ACAD:1::/64 means the first 64 bits identify the subnet (the prefix) and the remaining 64 bits identify the interface. Almost every LAN uses /64, because SLAAC and EUI-64 need exactly 64 interface-ID bits. Point-to-point links sometimes use /127, and a host route appears as /128.

9.3.1 Structure of a global unicast address

A typical global unicast address (GUA) has three parts, shown in Figure 9-2: Global routing prefix – the block an ISP or RIR assigns to an organization, commonly a /48 (sometimes a /56 for small sites or homes).

Subnet ID – the bits between the global routing prefix and the /64 boundary. The organization chooses these to number its own subnets. With a /48, there are 16 subnet bits, which gives 2

16 = 65,536 subnets.

Interface ID – the low-order 64 bits that identify one interface on the subnet, equivalent to the host portion of an IPv4 address.

  • 48 bits 16 bits 64 bits
  • Global Routing Prefix Subnet ID Interface ID
  • 2001:0DB8:ACAD :0001 :0000:0000:0000:0001
  • Prefix (subnet) = /64 Host portion

assigned by ISP / RIR chosen by you manual, EUI-64, random or DHCPv6

2001:db8:acad:1::1/64

Figure 9-2 The three parts of a global unicast address with a /48 global routing prefix.

9.3.2 Finding the prefix of an address

To find the subnet prefix of an address, keep the first n bits and set the rest to zero. When the prefix length is a multiple of 16 this is trivial: for /64 keep the first four hextets. When it is a multiple of 4 (a nibble boundary) you keep whole hex digits. Only prefixes that split a hex digit require binary.

2001:DB8:ACAD:1:20C:29FF:FE3A:1B2C/64 → prefix 2001:DB8:ACAD:1::/64 .

2001:DB8:ACAD:1234::99/56 → keep 56 bits = 14 hex digits: 2001:0DB8:ACAD:12 | 34 →

2001:db8:acad:1200::/56 .

2001:DB8:ACAD:F7::1/60 → keep 15 hex digits: 2001:0DB8:ACAD:00F | 7 →

2001:db8:acad:f0::/60 .

2001:DB8:CAFE:A5::1/62 → the 16th digit 5 ( 0101 ) keeps its top two bits ( 01 00 = 4) →

2001:db8:cafe:a4::/62 .

9.3.3 Subnetting a /48

Subnetting IPv6 is easier than IPv4 because every LAN gets a /64: you simply count up in the subnet-ID hextet. If your ISP assigns 2001:DB8:ACAD::/48 , your subnets are: 2001:DB8:ACAD:0000::/64 ! subnet 0 (often skipped)

  • 2001:DB8:ACAD:0001::/64 ! subnet 1 - users
  • 2001:DB8:ACAD:0002::/64 ! subnet 2 - servers
  • 2001:DB8:ACAD:0003::/64 ! subnet 3 - voice

...

2001:DB8:ACAD:FFFF::/64 ! subnet 65,535 (the last one)

Designers often encode meaning in the subnet ID, such as site 2, VLAN 10 = 2001:DB8:ACAD:2010::/64 . Figure 9-3 shows a small branch built from a /48.

Isp

delegates 2001:DB8:ACAD::/48

R1

Wan 2001:db8:ffff:12::2/64

  • G0/0
  • G0/1
  • G0/2
  • Users Servers Voice

2001:DB8:ACAD:1::/64 2001:DB8:ACAD:2::/64 2001:DB8:ACAD:3::/64 Subnet ID = 4th hextet

:0000 – :ffff

= 65,536 possible /64s

Figure 9-3 Subnetting the global routing prefix 2001:DB8:ACAD::/48 into /64 LANs.

Tip

The documentation prefix 2001:DB8::/32 (RFC 3849) is reserved for books and examples, just as 192.0.2.0/24 is for IPv4. You will see it throughout this book and on the exam; it is never routed on the Internet.

9.4 IPv6 Address Types

IPv6 has three families of addresses. A unicast address identifies one interface; a packet sent to it goes to that interface only. A multicast address identifies a group of interfaces; a packet sent to it goes to all members. An anycast address is assigned to several interfaces (usually on different devices); a packet sent to it is routed to the nearest one according to the routing protocol metric. There is no broadcast in IPv6: the all-nodes multicast group FF02::1 fulfils that role when it is really needed.

Table 9-3 Recognizing IPv6 address types by their first hex digits Type Prefix First hextet looks like Scope / use

GUAs are the IPv6 equivalent of public IPv4 addresses. IANA allocates them from 2000::/3 (first three bits 001 ), so every GUA today begins with hex 2 or 3. RIRs allocate to ISPs, which assign /48 or /56 prefixes to customers. With so much space there is no need for NAT; stateful firewalls provide security instead.

9.4.2 Unique local addresses

ULAs (RFC 4193) are the closest equivalent of RFC 1918 addresses. They use FC00::/7 , but the eighth (L) bit must be 1, so in practice every ULA starts with FD, followed by a 40-bit pseudo-random Global ID that makes collisions unlikely when companies merge. ULAs are routed inside an organization but never advertised to the Internet.

9.4.3 Link-local addresses

Every IPv6-enabled interface must have a link-local address from FE80::/10 (in practice FE80::/64 ). Routers never forward packets sourced from or destined to an LLA. LLAs are the source of NDP messages, the next hop in routes learned by OSPFv3 and EIGRPv6, and the default gateway hosts learn from RAs. IOS creates an LLA automatically with EUI-64 when IPv6 is enabled on an interface; because LLAs only need to be unique per link, you can configure the same FE80::1 on every interface of a router.

  • Unique local (FD00::/8)
  • FD Global ID (random) Subnet ID Interface ID
  • 8 bits 40 bits 16 bits 64 bits
  • Link-local (FE80::/10)
  • FE80 all zeros Interface ID (EUI-64, random or manual)
  • 10 bits 54 bits 64 bits

Figure 9-4 Format of unique local and link-local addresses (drawn to scale: 128 bits each).

9.4.4 Multicast addresses

Multicast addresses begin with FF . The next hex digit holds four flag bits (0 for permanent, well-known groups), and the fourth hex digit is the scope, which limits how far the packet may travel. The remaining 112 bits are the group ID. So FF02::1 is a well-known (flag 0), link-local scope (2) group with ID 1: all nodes on this link. The scope digit values you should recognise are 1 interface-local, 2 link-local, 5 site-local, 8 organization-local and E global. A packet sent to an FF02:: group never leaves the local link; an FF05:: group can be routed within a site.

Table 9-4 Well-known link-local multicast groups

  • Address Group IPv4 equivalent
  • FF02::1 All nodes on the link Broadcast / 224.0.0.1
  • FF02::2 All routers on the link 224.0.0.2
  • FF02::5 All OSPFv3 routers 224.0.0.5
  • FF02::6 OSPFv3 designated routers 224.0.0.6
  • FF02::A EIGRPv6 routers 224.0.0.10

FF02::1:2 All DHCPv6 servers and relay agents (DHCPv4 uses broadcast)

FF02::1:FF00:0/104 Solicited-node multicast range (ARP uses broadcast)

An IPv6 multicast packet is sent in a frame whose destination MAC is 33:33 plus the low 32 bits of the group, so FF02::1 maps to 33:33:00:00:00:01 .

9.4.5 Anycast addresses

An anycast address is an ordinary unicast address configured on more than one device; routing delivers each packet to the nearest one. Public DNS and CDNs use it heavily. On IOS, the anycast keyword stops the router running DAD against the other copies:

R1(config-if)# ipv6 address 2001:DB8:ACAD:99::53/64 anycast

Know the prefixes cold: GUA 2000::/3, ULA FC00::/7 (FD), link-local FE80::/10, multicast FF00::/8, solicited-node FF02::1:FF00:0/104. A common question shows an address such as FE80::2AA:FF:FE9A:4CA2 or FD12:3456::1 and asks for its type. Also remember that IPv6 has no broadcast address type.

9.5 Modified EUI-64

A 64-bit interface ID can be manual, random, assigned by DHCPv6, or derived from the 48-bit MAC address with modified EUI-64, which gives a unique ID with no configuration in three steps:

  • 1. Split the MAC address in half: the 24-bit OUI and the 24-bit device identifier.
  • 2. Insert FFFE in the middle, producing 64 bits.
  • 3. Invert (flip) the seventh bit from the left of the first byte, the universal/local (U/L) bit. In hex this changes the second digit: 0↔2, 1↔3, 4↔6, 5↔7, 8↔A, 9↔B, C↔E, D↔F. MAC address 0050.56A1.2B3C

64-bit interface ID (leading zero dropped: 250:56FF:FEA1:2B3C)

Prefix 2001:DB8:ACAD:1::/64 + interface ID =

2001:db8:acad:1:250:56ff:fea1:2b3c

Figure 9-5 Building a modified EUI-64 interface ID from MAC address 0050.56A1.2B3C. 9.5.1 More worked examples

Table 9-5 EUI-64 practice

MAC address After inserting FFFE First byte flipped Interface ID 0C58.A2F1.7B01 0C58:A2FF:FEF1:7B01 0C (0000 1100) → 0E E58:A2FF:FEF1:7B01 AABB.CCDD.EEFF AABB:CCFF:FEDD:EEFF AA (1010 1010) → A8 A8BB:CCFF:FEDD:EEFF F4CF.E2A0.0011 F4CF:E2FF:FEA0:0011 F4 (1111 0100) → F6 F6CF:E2FF:FEA0:11 0213.1957.88C2 0213:19FF:FE57:88C2 02 → 00 13:19FF:FE57:88C2

In the last example the U/L bit was already 1, so flipping makes it 0: always flip, never just “set to 1”. An xxFF:FExx pattern in hextets 6 and 7 is the giveaway of an EUI-64 address.

Watch out

EUI-64 embeds the MAC address, which lets a moving laptop be tracked, so modern host operating systems use random interface IDs for SLAAC. Cisco routers still use EUI-64 for automatic link-local addresses and the eui-64 keyword.

9.6 Neighbor Discovery Protocol

IPv6 has no ARP. Its job, and several new ones, belongs to the Neighbor Discovery Protocol (NDP), which uses five ICMPv6 messages. Blocking all ICMPv6 with an ACL therefore breaks IPv6.

Table 9-6 Neighbor Discovery messages

an immediate RA.

MTU, hop limit.

Neighbor

Solicitation (NS)

135 Any node → solicited-node multicastAsks for the MAC address of an IPv6 address (like an ARP request); also used

for DAD.

  • Neighbor
  • Advertisement (NA)
  • 136 Any node → requester
  • (unicast) or FF02::1
  • Answers an NS with the MAC address

(like an ARP reply).

Redirect 137 Router → host Informs a host of a better first hop.

9.6.1 Solicited-node multicast

ARP requests are broadcast and disturb every host. NDP instead sends a Neighbor Solicitation to a solicited-node multicast address that, in practice, only the target listens to. It is formed by appending the last 24 bits of the unicast address to FF02::1:FF00:0/104 , and every node joins the group for each of its unicast and anycast addresses.

Unicast address

2001:0db8:acad:0001:0000:0000:a1 b2:c3d4

  • last 24 bits
  • Solicited-node multicast
  • FF02:0000:0000:0000:0000:0001:FF B2:C3D4
  • fixed /104 prefix FF02::1:FF00:0/104

= ff02::1:ffb2:c3d4

Ethernet destination MAC: 33:33 + last 32 bits = 33:33:FF:B2:C3:D4

Figure 9-6 Deriving the solicited-node multicast address and its multicast MAC address.

9.6.2 Address resolution with NS and NA

Figure 9-7 shows PC1 resolving its gateway's MAC address. The result goes into the neighbor cache (on a router, show ipv6 neighbors ).

PC1

2001:db8:acad:1::10

  • R1 G0/0
  • 2001:DB8:ACAD:1::1 · MAC 0c58.a2f1.7b00
  • 1 Neighbor Solicitation (ICMPv6 135)

dst FF02::1:FF00:1 (MAC 33:33:FF:00:00:01) — target 2001:DB8:ACAD:1::1?

  • 2 Neighbor Advertisement (ICMPv6 136)
  • unicast to PC1 — “2001:DB8:ACAD:1::1 is at 0c58.a2f1.7b00”
  • 3 PC1 adds the entry to its neighbor cache (state REACHABLE)

and sends the data packet in a unicast frame to 0c58.a2f1.7b00

Figure 9-7 Address resolution: the IPv6 replacement for ARP uses NS to a solicited-node group and a unicast NA.

9.6.3 Router discovery and Duplicate Address Detection

Routers send RAs to FF02::1 every 200 seconds by default on IOS, and immediately in response to an RS. The RA carries the prefix and length, the router's link-local address (the hosts' default gateway), the router lifetime and the A (autonomous), M (managed) and O (other configuration) flags.

Before using any unicast address, a node performs Duplicate Address Detection (DAD): it sends an NS from :: to the address's solicited-node group. An NA reply means the address is a duplicate (IOS shows [DUP] ); silence for about a second means it is unique.

  • PC1 boots R1
  • 1 Build link-local FE80::<interface ID>
  • interface ID from EUI-64 or random
  • 2 DAD: NS from :: to solicited-node
  • no NA within ~1 s = address unique
  • 3 Router Solicitation (133) to FF02::2
  • 4 Router Advertisement (134) from FE80::1
  • prefix 2001:DB8:ACAD:1::/64, A=1, M=0, O=0, lifetime 1800 s
  • 5 Build GUA: prefix + interface ID
  • 2001:DB8:ACAD:1:<interface ID> — then DAD again
  • 6 Default gateway = FE80::1 (source of the RA)
  • host is ready to communicate beyond the link

Figure 9-8 SLAAC start-up sequence: link-local address, DAD, RS/RA exchange and global address creation.

9.7 Dynamic Address Assignment: SLAAC and DHCPv6

Hosts obtain addresses in three ways, and the router's RA flags tell them which to use.

9.7.1 slaac

Stateless Address Autoconfiguration needs no server: the host takes the /64 prefix from the RA, adds its own interface ID, runs DAD and starts working. No device records which host has which address. It is the IOS default once an interface has an IPv6 address and ipv6 unicast-routing is on. DNS servers can be learned from the RA's RDNSS option.

9.7.2 Stateless DHCPv6

Hosts still use SLAAC for the address but ask a DHCPv6 server for “other” information such as DNS servers and domain name. The server keeps no bindings. The router sets the O flag ( ipv6 nd other-config-flag ).

9.7.3 Stateful DHCPv6

The DHCPv6 server assigns the address and tracks bindings, like DHCPv4. The router sets the M flag ( ipv6 nd managed-config-flag ). DHCPv6 never provides a default gateway; hosts always learn it from the RA. Clients use UDP 546, servers UDP 547, and clients send SOLICIT, then REQUEST, to FF02::1:2; servers answer with ADVERTISE and REPLY. A router relays to a remote server with ipv6 dhcp relay destination .

Table 9-7 Comparing IPv6 address assignment methods

Slaac a=1, o=0,

Exam alert

Be able to match each method to its flags and sources. The key traps: SLAAC and stateless DHCPv6 both build the address on the host; only stateful DHCPv6 assigns addresses from a server; and in every case the default gateway is the router's link-local address learned from the RA.

9.8 Configuring and Verifying IPv6 on Cisco Routers

Giving an interface an IPv6 address lets the router send and receive IPv6 there; the global command ipv6 unicast-routing is what lets it forward IPv6 between interfaces and send RAs. Without it the router behaves like a host.

R1 below uses a manual GUA and LLA on G0/0, EUI-64 on G0/1, and only ipv6 enable on G0/2:

R1(config)# ipv6 unicast-routing
R1(config)# interface GigabitEthernet0/0
R1(config-if)# ipv6 address 2001:DB8:ACAD:1::1/64
R1(config-if)# ipv6 address FE80::1 link-local
R1(config-if)# no shutdown
R1(config-if)# interface GigabitEthernet0/1
R1(config-if)# ipv6 address 2001:DB8:ACAD:12::/64 eui-64 ! MAC 0c58.a2f1.7b01
R1(config-if)# no shutdown
R1(config-if)# interface GigabitEthernet0/2
R1(config-if)# ipv6 enable ! link-local only
R1(config-if)# no shutdown

Note

Device output in this chapter is illustrative of Cisco IOS 15 / IOS XE; minor formatting differs between releases and platforms.

Table 9-8 IPv6 interface configuration commands (summary)

Command Effect

ipv6 unicast-routing (global) Enable IPv6 routing and RAs. Disabled by default. ipv6 address 2001:DB8:ACAD:1::1/64 Static GUA/ULA with a manual interface ID. Also creates an EUI-64 link-local address.

  • ipv6 address 2001:DB8:ACAD:12::/64
  • eui-64
  • Router builds the interface ID from the interface MAC with

modified EUI-64.

ipv6 address FE80::1 link-local Overrides the automatic link-local address. ipv6 enable Enables IPv6 with only a link-local address (no GUA needed).

ipv6 address autoconfig [default] Interface acts as a SLAAC client; default installs a default route from the RA.

ipv6 address dhcp Interface acts as a stateful DHCPv6 client.

R1 — console

R1# show ipv6 interface brief

GigabitEthernet0/0 [up/up]

FE80::1

2001:db8:acad:1::1

GigabitEthernet0/1 [up/up]

Fe80::e58:a2ff:fef1:7b01

2001:db8:acad:12:e58:a2ff:fef1:7b01

GigabitEthernet0/2 [up/up]

Fe80::e58:a2ff:fef1:7b02

GigabitEthernet0/3 [administratively down/down]

unassigned

Figure 9-9 show ipv6 interface brief : G0/0 has a manual link-local address, G0/1 an EUI-64 GUA, G0/2 only a link-local address.

G0/1's MAC 0c58.a2f1.7b01 becomes 0E58:A2FF:FEF1:7B01 (0C flipped to 0E), shown without the leading zero in both its link-local and global address. For full detail, show ipv6 interface lists every address and prefix, joined multicast groups, and ND/RA settings.

R1# show ipv6 interface GigabitEthernet0/0
  • GigabitEthernet0/0 is up, line protocol is up
  • IPv6 is enabled, link-local address is FE80::1
  • No Virtual link-local address(es):
  • Global unicast address(es):
  • 2001:DB8:ACAD:1::1, subnet is 2001:DB8:ACAD:1::/64
  • Joined group address(es):
  • FF02::1
  • FF02::2
  • FF02::1:FF00:1
  • MTU is 1500 bytes
  • ICMP error messages limited to one every 100 milliseconds
  • ICMP redirects are enabled
  • ICMP unreachables are sent
  • ND DAD is enabled, number of DAD attempts: 1
  • ND reachable time is 30000 milliseconds (using 30000)
  • ND advertised reachable time is 0 (unspecified)
  • ND advertised retransmit interval is 0 (unspecified)
  • ND router advertisements are sent every 200 seconds
  • ND router advertisements live for 1800 seconds
  • ND advertised default router preference is Medium

Hosts use stateless autoconfig for addresses.

Figure 9-10 show ipv6 interface : addresses, prefix, joined multicast groups and RA settings.

FF02::2 is joined because ipv6 unicast-routing is on. FE80::1 and 2001:DB8:ACAD:1::1 share their last 24 bits, so one solicited-node group, FF02::1:FF00:1, covers both. As in IPv4, each address also creates a connected (C) /64 route and a local (L) /128 route in show ipv6 route ; link-local addresses create none.

Tip

To ping a link-local address you must tell the router which interface to use, because the same FE80:: prefix exists on every link. Use ping FE80::2 and answer the “Output Interface:” prompt, or type ping ipv6 FE80::2 GigabitEthernet0/1 on platforms that support it.

LAB Configure and verify IPv6 addressing

Goal: Configure IPv6 on two routers using a manual address, a manual link-local address and modified EUI-64, let PC1 autoconfigure with SLAAC, and verify neighbor discovery and connectivity on each link.

Slaac

SW1 R1 R2

G0/0 G0/1 G0/0

2001:db8:acad:1::/64

R1 ::1, lla fe80::1

2001:db8:acad:12::/64

R1 EUI-64 · R2 ::2, LLA FE80::2

Lo0 2001:DB8:ACAD:22::1/64

Figure 9-11 Lab topology for IPv6 addressing.

Steps:

  • 1. On R1, enable IPv6 routing and configure G0/0 and G0/1 exactly as in Section 9.8.
  • 2. On R2, configure the link toward R1 with a manual address and LLA, and a loopback:
R2(config)# ipv6 unicast-routing
R2(config)# interface GigabitEthernet0/0
R2(config-if)# ipv6 address 2001:DB8:ACAD:12::2/64
R2(config-if)# ipv6 address FE80::2 link-local
R2(config-if)# no shutdown
R2(config-if)# interface Loopback0
R2(config-if)# ipv6 address 2001:DB8:ACAD:22::1/64
  • 3. Predict R1's G0/1 address from its MAC ( show interfaces g0/1 | include bia ) before looking. Then confirm with show ipv6 interface brief .
  • 4. Enable IPv6 on PC1 (automatic configuration). Run ipconfig and confirm a 2001:DB8:ACAD:1::/64 address and gateway fe80::1 .
  • 5. From PC1, ping 2001:DB8:ACAD:1::1 . From R1, ping R2's global address and R2's link-local address. Verify:
R1# ping 2001:DB8:ACAD:12::2

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 2001:DB8:ACAD:12::2, timeout is 2 seconds: !!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 1/1/2 ms

R1# ping FE80::2

Output Interface: GigabitEthernet0/1

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to FE80::2, timeout is 2 seconds:

Packet sent with a source address of FE80::E58:A2FF:FEF1:7B01%GigabitEthernet0/1 !!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 1/1/1 ms

R1# show ipv6 neighbors

IPv6 Address Age Link-layer Addr State Interface

2001:DB8:ACAD:1:5C1E:9A2B:44F0:12AD 0 0050.56a1.0010 REACH Gi0/0 FE80::5C1E:9A2B:44F0:12AD 0 0050.56a1.0010 REACH Gi0/0

2001:DB8:ACAD:12::2 0 0c7d.11e4.2200 REACH Gi0/1

FE80::2 0 0c7d.11e4.2200 REACH Gi0/1

Figure 9-12 Successful pings and the resulting neighbor cache entries learned through NS/NA.

Expected results: PC1 holds a SLAAC address in 2001:DB8:ACAD:1::/64 with default gateway fe80::1 ; R1's G0/1 address ends in E58:A2FF:FEF1:7B01 ; all pings succeed; and show ipv6 neighbors lists PC1 and R2 in REACH state. R1 cannot yet reach R2's loopback, because no route to 2001:DB8:ACAD:22::/64 exists. You will fix that with an IPv6 static route in Chapter 20.

Slaac

  • stateless DHCPv6
  • stateful DHCPv6
  • dual stack
  • 1. Which is the correct shortest form of 2001:0DB8:0000:0000:0000:0BAD:0000:0010 ?
  • A. 2001:DB8::BAD::10
  • B. 2001:DB8::BAD:0:10
  • C. 2001:DB8:0:0:0:BAD::1
  • D. 2001:DB8::BAD:0:1
  • 2. Which prefix identifies IPv6 link-local addresses?
  • A. FC00::/7
  • B. FE80::/10
  • C. FF02::/16
  • D. 2000::/3
  • 3. An interface has MAC address 0060.2F3A.0B11 . Which interface ID does modified EUI-64 produce?
  • A. 0060:2FFF:FE3A:0B11
  • B. 0260:2FFF:FE3A:0B11
  • C. 0260:2FFE:FF3A:0B11
  • D. 0062:2FFF:FE3A:0B11
  • 4. Which two statements describe IPv6 unique local addresses? (Choose two.)
  • A. They begin with FD in practice.
  • B. They are routed on the public Internet.
  • C. They include a 40-bit pseudo-random Global ID.
  • D. They are only valid on a single link.
  • E. They begin with FE80.
  • 5. What is the solicited-node multicast address for 2001:DB8:ACAD:1::4C:9A21 ?
  • A. FF02::1:FF4C:9A21
  • B. FF02::1:FF00:9A21
  • C. FF02::1:FF0C:9A21
  • D. FF02::2:FF4C:9A21
  • 6. Which ICMPv6 message does a host send to discover routers on its link?
  • A. Type 133 Router Solicitation
  • B. Type 134 Router Advertisement
  • C. Type 135 Neighbor Solicitation
  • D. Type 136 Neighbor Advertisement
  • 7. Which command lets a Cisco router forward IPv6 packets between interfaces and send RAs?
  • A. ipv6 enable
  • B. ipv6 routing
  • C. ipv6 unicast-routing
  • D. ipv6 address autoconfig
  • 8. A host must obtain its address from a server that keeps bindings. Which RA flag must the router set?
  • A. A flag
  • B. O flag
  • C. M flag
  • D. L flag
  • 9. Which two actions does a host perform when it uses SLAAC? (Choose two.)
  • A. It learns the prefix from a Router Advertisement.
  • B. It receives its default gateway from a DHCPv6 server.
  • C. It performs Duplicate Address Detection before using the address.
  • D. It sends a DHCPv6 SOLICIT to FF02::1:2.
  • E. It uses a broadcast to find the router.
  • 10. What is the prefix of 2001:DB8:CAFE:1A7F::1/60 ?
  • A. 2001:DB8:CAFE:1A70::/60
  • B. 2001:DB8:CAFE:1A00::/60
  • C. 2001:DB8:CAFE::/60
  • D. 2001:DB8:CAFE:1A7F::/60
  • 11. Which address type is assigned to several devices so that packets are delivered to the nearest one?
  • A. Multicast
  • B. Broadcast
  • C. Anycast
  • D. Link-local
  • 12. Which two addresses does a Cisco IOS router with ipv6 unicast-routing join on every IPv6-enabled interface? (Choose two.)
  • A. FF02::1
  • B. FF02::2
  • C. FF02::5
  • D. FF02::A
  • E. FF05::1:3
  • 13. An organization receives 2001:DB8:4400::/48 . How many /64 subnets can it create?
  • A. 256
  • B. 4,096
  • C. 16,384
  • D. 65,536

Answers

  • 1. B. The run of three zero hextets becomes :: ; the single zero hextet before 0010 stays as 0 and leading zeros of 0010 drop to 10. A uses :: twice; C and D drop a trailing zero.
  • 2. B. Link-local is FE80::/10.
  • 3. B. Insert FFFE between 00602F and 3A0B11, then flip the seventh bit of 00 to give 02:

0260:2fff:fe3a:0b11.

  • 4. A, C. ULAs use FC00::/7 with the L bit set (FD) and a 40-bit random Global ID.
  • 5. A. Take the last 24 bits (4C:9A21) and append them to FF02::1:FF00:0/104, giving FF02::1:FF4C:9A21.
  • 6. A. Hosts send RS (133) to FF02::2; routers answer with RA (134).
  • 7. C. ipv6 unicast-routing is the global command.
  • 8. C. The Managed (M) flag tells hosts to use stateful DHCPv6. O means “get other information via DHCPv6”; A permits SLAAC.
  • 9. A, C. SLAAC learns the prefix from the RA and runs DAD. The gateway always comes from the RA.
  • 10. A. A /60 keeps 15 hex digits: 2001:0DB8:CAFE:1A7|F, so the prefix is

2001:db8:cafe:1a70::/60.

  • 11. C. Anycast addresses are shared, and routing delivers to the nearest instance.
  • 12. A, B. All-nodes FF02::1 and all-routers FF02::2. FF02::5 and FF02::A are joined only when OSPFv3 or EIGRPv6 run.
  • 13. D. 64 − 48 = 16 subnet bits; 2

16 = 65,536.

Use ← → to move between sections