Knowing the different IPv6 address types (covered in a companion article) is only half the picture — you also need to know how to actually configure them on real devices and, just as importantly, how to verify your configuration is correct and working. This article walks through hands-on IPv6 configuration on Cisco routers and switches, plus verification on Cisco, Linux, and Windows.
Understanding the IPv6 Prefix
Where IPv4 uses a subnet mask (like 255.255.255.0), IPv6 exclusively uses prefix length notation (like /64). There is no equivalent to IPv4’s dotted-decimal subnet mask in everyday IPv6 configuration.
2001:db8:acad:1::10/64
└──────────┬──────────┘└┬┘
Address Prefix length (bits)
- The prefix (
2001:db8:acad:1::/64) identifies the network. - The interface identifier (the remaining 64 bits) identifies the specific host on that network.
Why /64 Is the Standard LAN Prefix Length
Virtually all IPv6 LAN segments use a /64 prefix, regardless of how many hosts are actually on the segment. This is a deliberate design decision (not an efficiency requirement, unlike careful IPv4 subnetting) because:
- SLAAC and EUI-64 interface identifiers require exactly 64 bits to work correctly.
- IPv6’s address space is so vast that “wasting” addresses within a /64 (which contains 18 quintillion addresses) is a complete non-issue.
Step 1: Enable IPv6 Routing on Cisco Devices
Before a Cisco router will forward IPv6 packets between interfaces, you must explicitly enable IPv6 unicast routing:
Router(config)# ipv6 unicast-routingThis single command is one of the most commonly forgotten steps — without it, a router can have perfectly valid IPv6 addresses on its interfaces but will refuse to route between them.
Step 2: Assign IPv6 Addresses to Interfaces
Method A: Static GUA Assignment
Router(config)# interface GigabitEthernet0/0
Router(config-if)# ipv6 address 2001:db8:acad:1::1/64
Router(config-if)# no shutdownMethod B: EUI-64 Auto-Generated Interface ID
Router(config)# interface GigabitEthernet0/1
Router(config-if)# ipv6 address 2001:db8:acad:2::/64 eui-64
Router(config-if)# no shutdownThe router combines the given /64 prefix with an interface identifier automatically derived from the interface’s MAC address (inserting FFFE in the middle and flipping the 7th bit — the “Universal/Local” bit — of the MAC address).
Method C: Assigning a ULA (Unique Local Address)
Router(config-if)# ipv6 address fd12:3456:789a:1::1/64Functionally identical configuration syntax to a GUA — the address itself simply falls within the ULA range (fc00::/7, typically fd00::/8).
Link-Local Addresses Are Automatic
You do not need to manually configure a link-local address — Cisco IOS automatically generates one (using EUI-64 by default) the moment IPv6 is enabled on an interface. You can override it manually if desired:
Router(config-if)# ipv6 address fe80::1 link-localStep 3: Configure Router Advertisements (RA) for SLAAC
By default, once an interface has an IPv6 address and ipv6 unicast-routing is enabled, the router automatically begins sending Router Advertisement (RA) messages, allowing connected hosts to use SLAAC to self-configure their own addresses using the advertised prefix.
You can fine-tune RA behavior:
Router(config-if)# ipv6 nd ra interval 200
Router(config-if)# ipv6 nd prefix 2001:db8:acad:1::/64 no-advertise
To suppress RAs entirely on an interface (e.g., on a WAN link where you don’t want clients to auto-configure):
Router(config-if)# ipv6 nd ra suppress allStep 4: Configure a Default IPv6 Route (Optional, for Internet Access)
Router(config)# ipv6 route ::/0 2001:db8:0:1::1This is the IPv6 equivalent of IPv4’s ip route 0.0.0.0 0.0.0.0 <next-hop> — ::/0 represents “any destination,” exactly as 0.0.0.0/0 does in IPv4.
Full Configuration Example
Topology
graph LR
PC["Client PC"] ---|"2001:db8:acad:1::/64"| R1["Router R1"]
R1 ---|"2001:db8:acad:2::/64 (eui-64)"| R2["Router R2"]
R2 -->|"Default route :: /0"| ISP["ISP / Internet"]R1 Configuration
R1(config)# ipv6 unicast-routing
R1(config)# interface GigabitEthernet0/0
R1(config-if)# description LAN Segment
R1(config-if)# ipv6 address 2001:db8:acad:1::1/64
R1(config-if)# no shutdown
R1(config-if)# exit
R1(config)# interface GigabitEthernet0/1
R1(config-if)# description Link to R2
R1(config-if)# ipv6 address 2001:db8:acad:2::1/64
R1(config-if)# no shutdown
R1(config-if)# exit
R1(config)# ipv6 route ::/0 2001:db8:acad:2::2R2 Configuration
R2(config)# ipv6 unicast-routing
R2(config)# interface GigabitEthernet0/0
R2(config-if)# description Link to R1
R2(config-if)# ipv6 address 2001:db8:acad:2::2/64
R2(config-if)# no shutdownVerification Commands
show ipv6 interface brief
Quick summary of every interface’s IPv6 status and addresses:
R1# show ipv6 interface brief
GigabitEthernet0/0 [up/up]
FE80::1
2001:DB8:ACAD:1::1
GigabitEthernet0/1 [up/up]
FE80::1
2001:DB8:ACAD:2::1show ipv6 interface <interface>
Full detail, including MTU, joined multicast groups, and ND settings:
R1# show ipv6 interface GigabitEthernet0/0
GigabitEthernet0/0 is up, line protocol is up
IPv6 is enabled, link-local address is FE80::1
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
ND DAD is enabled, number of DAD attempts: 1
ND reachable time is 30000 millisecondsshow ipv6 route
Confirms the routing table — the IPv6 equivalent of show ip route:
R1# show ipv6 route
IPv6 Routing Table - default - 5 entries
Codes: C - Connected, L - Local, S - Static, ND - Neighbor Discovery
O - OSPF Intra, OI - OSPF Inter, B - BGP
C 2001:DB8:ACAD:1::/64 [0/0]
via GigabitEthernet0/0, directly connected
L 2001:DB8:ACAD:1::1/128 [0/0]
via GigabitEthernet0/0, receive
C 2001:DB8:ACAD:2::/64 [0/0]
via GigabitEthernet0/1, directly connected
S ::/0 [1/0]
via 2001:DB8:ACAD:2::2Notice the same core logic as IPv4 (connected, local, static routes with AD/metric values) — the codes and structure are almost identical, just with 128-bit addresses.
ping and traceroute (IPv6)
R1# ping 2001:db8:acad:2::2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:DB8:ACAD:2::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5)R1# traceroute 2001:db8:acad:2::2show ipv6 neighbors
The IPv6 equivalent of show ip arp — shows the Neighbor Discovery cache mapping IPv6 addresses to MAC addresses:
R1# show ipv6 neighbors
IPv6 Address Age Link-layer Addr State Interface
FE80::2 0 aabb.cc00.0200 REACH Gi0/1
2001:DB8:ACAD:2::2 0 aabb.cc00.0200 REACH Gi0/1Linux Configuration and Verification Examples
Assigning a Static IPv6 Address
sudo ip -6 addr add 2001:db8:acad:1::10/64 dev eth0Enabling IPv6 Forwarding (to Act as a Router)
sudo sysctl -w net.ipv6.conf.all.forwarding=1Verifying
$ ip -6 addr show eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500
inet6 2001:db8:acad:1::10/64 scope global
inet6 fe80::1a2b:3c4d:5e6f:7890/64 scope link
$ ip -6 route show
2001:db8:acad:1::/64 dev eth0 proto kernel metric 256
default via fe80::1 dev eth0 proto ra metric 1024
$ ping6 2001:db8:acad:1::1
PING 2001:db8:acad:1::1(2001:db8:acad:1::1) 56 data bytes
64 bytes from 2001:db8:acad:1::1: icmp_seq=1 ttl=64 time=0.412 msWindows Verification Example
C:\Users\PC1> ipconfig
Ethernet adapter Ethernet:
Connection-specific DNS Suffix . :
IPv6 Address. . . . . . . . . . . : 2001:db8:acad:1::10
Link-local IPv6 Address . . . . . : fe80::1a2b:3c4d:5e6f:7890%12
Default Gateway . . . . . . . . . : fe80::1%12C:\Users\PC1> ping 2001:db8:acad:2::2
Pinging 2001:db8:acad:2::2 with 32 bytes of data:
Reply from 2001:db8:acad:2::2: time=1msPython Example: Validating an IPv6 Address/Prefix Configuration
import ipaddress
def validate_ipv6(address_with_prefix):
try:
interface = ipaddress.ip_interface(address_with_prefix)
network = interface.network
print(f"Address: {interface.ip}")
print(f"Prefix Length: {interface.network.prefixlen}")
print(f"Network: {network.network_address}/{network.prefixlen}")
print(f"Is Global Unicast: {not (interface.ip.is_private or interface.ip.is_link_local)}")
except ValueError as e:
print(f"Invalid: {e}")
validate_ipv6("2001:db8:acad:1::10/64")Output:
Address: 2001:db8:acad:1::10
Prefix Length: 64
Network: 2001:db8:acad:1::/64
Is Global Unicast: TrueComparison Table: IPv4 vs. IPv6 Addressing Configuration
| Task | IPv4 (Cisco) | IPv6 (Cisco) |
|---|---|---|
| Enable routing | Enabled by default | ipv6 unicast-routing (must enable manually) |
| Assign address | ip address 192.168.1.1 255.255.255.0 | ipv6 address 2001:db8::1/64 |
| Auto-assign via MAC | Not applicable | ipv6 address <prefix>/64 eui-64 |
| Default route | ip route 0.0.0.0 0.0.0.0 <next-hop> | ipv6 route ::/0 <next-hop> |
| View routing table | show ip route | show ipv6 route |
| View ARP/ND cache | show ip arp | show ipv6 neighbors |
| View interfaces | show ip interface brief | show ipv6 interface brief |
Best Practices
- Always issue
ipv6 unicast-routingfirst on any Cisco router intended to route between IPv6 segments — it’s easy to forget and causes confusing “addresses configured but nothing forwards” symptoms. - Standardize on /64 for LAN segments unless you have a very specific, well-understood reason to deviate.
- Use meaningful, documented prefixes in lab and production environments — the
2001:db8::/32range is reserved specifically for documentation and examples (per RFC 3849), so use it freely in labs and diagrams without risk of conflicting with real addresses. - Verify both the configuration AND live neighbor/routing state —
show running-configshows intent;show ipv6 interface brief,show ipv6 route, andshow ipv6 neighborsshow reality. - Suppress Router Advertisements on interfaces that shouldn’t be handing out addresses (e.g., WAN uplinks) to avoid unintended client auto-configuration.
Troubleshooting Checklist
- Is
ipv6 unicast-routingenabled globally? - Does
show ipv6 interface briefshow the expected address AND[up/up]status? - Does
show ipv6 routeshow the expected connected, static, or dynamic routes? - Does
show ipv6 neighborsshow a successfully resolved neighbor entry (stateREACH) for the next hop? - Can you ping the link-local address of the directly connected neighbor before troubleshooting further upstream?
- Is there a default route (
::/0) if the destination is outside the local prefix?
Summary
Configuring IPv6 addressing follows a strikingly similar logical flow to IPv4 — assign addresses, enable routing, configure default routes — but with IPv6-specific syntax (ipv6 address, /64 prefixes, eui-64 auto-generation) and the crucial extra step of enabling ipv6 unicast-routing. Verification commands mirror their IPv4 counterparts closely (show ipv6 route, show ipv6 neighbors, show ipv6 interface brief), making the transition from IPv4 to IPv6 configuration far more approachable once you recognize these parallels.