IPv6 - NDP preferred and valid lifetimes

When deploying IPv6, it is possible to use the Neighbor Discovery process to assign IPv6 addresses to IPv6 hosts. Within the context of the use of NDP, these values tell a device how to treat particular addresses that have been assigned using stateless autoconfiguration.

When configuring such a case on a Cisco router, the ipv6 nd prefix command is used. This command has two timers associated with it: the preferred and valid lifetimes.

These lifetime parameters are associated with the IPv6 ND protocol and define two key lifetimes for the prefix advertised by the router: the valid lifetime and the preferred lifetime. Here’s a brief overview of both:

  1. Valid Lifetime: This is the length of time (in seconds) that the prefix is considered valid for the purpose of determining the uniqueness of an address on the network. If the valid lifetime expires, addresses using that prefix are no longer considered valid for new connections, but existing connections might continue until they are naturally closed.

  2. Preferred Lifetime: This is the period (also in seconds) during which addresses generated from the prefix are preferred. Once the preferred lifetime expires, although the addresses remain valid until the valid lifetime expires, they are no longer used for new outgoing connections. The system might start using other, more preferred addresses instead.

The lifetimes are crucial for the proper management of IPv6 addresses in a network. They enable a network administrator to control how long a device can use a specific prefix for generating IPv6 addresses. This is particularly useful in dynamic environments where prefixes might change due to renumbering or policy updates. By adjusting the lifetimes, an administrator can ensure a smooth transition for devices from old prefixes to new ones, minimizing potential disruptions in network connectivity.

These lifetimes help devices on the network to determine how long they can use the addresses they have autoconfigured based on the advertised prefix. It ensures that devices update their addresses periodically and phase out the use of old, possibly deprecated addresses in favor of newer ones, enhancing the overall management and security of the network.

For more information, also take a look at IPv6 - Valid and Preferred Addresses.

Also take a look at a related topic of DHCPv6 refresh time option.