Assigning IPv6 addresses to interfaces

You can assign primary and secondary IPv6 addresses to interfaces, using Classless Interdomain Routing (CIDR) network masks.

About this task

Configuration of IPv6 addresses on an interface has the following conditions.
  • Multiple primary IPv6 addresses from different subnets are allowed, but not from the same subnet.
  • Secondary IPv6 addresses have the same subnet as the primary addresses.
  • Primary IPv6 addresses cannot be deleted when a secondary address is configured.
  • Secondary IPv6 addresses cannot be added when the primary address is not configured.

Take the following steps to assign IPv6 addresses. The examples in steps 2-5 are for an Ethernet interface.

Procedure

  1. From privileged EXEC mode, enter global configuration mode.
    device# configure terminal
    
  2. Access the interface to which you are assigning the IP addresses.
    device(config)# interface ethernet 0/2
  3. Assign one or more primary IP addresses, including the CIDR network mask.
    device(config-if-eth-0/2)# ipv6 address 102:102::1/64
    device(config-if-eth-0/2)# ipv6 address 202:102::1/64
  4. Assign one or more secondary IP addresses, including the CIDR network mask and the secondary keyword.
    device(config-if-eth-0/2)# ipv6 address 102:102::2/64 secondary
    device(config-if-eth-0/2)# ipv6 address 202:102::2/64 secondary
  5. Activate the interface.
    device(config-if-eth-0/2)# no shutdown