Manually Configuring IPv6 Addresses on an Interface
Problems
You want to manually configure a full IPv6 address on an interface.
Solution
You can configure an IPv6 unicast address on an interface by using a very similar process to how we set up IPv4 addresses in previous chapters of this book:
Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z. Router1(config)#ipv6 unicast-routing
Router1(config)#interface
Router1(config-if)#
FastEthernet0/0
ipv6 address
Router1(config-if)#
AAAA::1/64
exit
Router1(config)#end
Router1#
We can configure an IPv6 Anycast address by using the anycast keyword:
Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z. Router1(config)#ipv6 unicast-routing
Router1(config)#interface
Router1(config-if)#
FastEthernet0/0
ipv6 address
AAFF::1/64
anycast
Router1(config-if)#exit
Router1(config)#end
Router1#
You can specify an IPv6 link-local address by using the link-local keyword:
Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z. Router1(config)#ipv6 unicast-routing
Router1(config)#interface
Router1(config-if)#
FastEthernet0/0
ipv6 address FE80::1 link-local
Router1(config-if)#exit
Router1(config)#end
Router1#
Discussion
In this recipe, we have manually configured three different types of IPv6 addresses. The first example simply configures a standard globally accessible unicast address. This is similar to the standard IPv4 unicast address:
Router1(config)#interface
Get Cisco IOS Cookbook, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.