Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 

Part 2: Implementing DHCPv6 - Stateless DHCPv6

     

    Introduction

    This document discuss with an example how to configure stateless DHCPv6 in Cisco IOS routers.Stateless DHCPv6 is one of the most convenient method of implementing DHCPv6 in large networks.Stateless DHCPv6 is a combination of Stateless Address Autoreconfiguration (also known as SLAAC) and DHCPv6. In this one or more  IPv6 addresses are assigned to the clients by using SLAAC and additional information i.e configuration parameters such as DNS, NTP are obtained using DHCPv6. This has a significant impact on the DHCP server since the server no longer has to keep track of  the state of any assigned IPv6 addresses to the clients. Also there is no need for state refreshment. In case of large networks which has huge number of hosts attached to it, implementing the stateless DHCPv6 will highly reduce the number of  DHCPv6 messages that are needed for address state refreshment.

     

    Requirements
    Background

     

    In this configuration example,the router R1 is configured as DHCP server while router R2 is configured as DHCPv6Client.

     

    Note: All configurations are tested in a lab environment involving ASR 1000 series router as DHCP server and Cisco 2800 series router as DHCP Clients.

     

    Topology Diagram

    dhcpv6.JPG

    Summary Steps
    Server Configuration

    In Global Configuration Mode

    1. ipv6 unicast-routing
    2. ipv6 dhcp pool <pool name>
    3. dns-server <specify the dns server address>
    4. domain-name <specify the domain name>
    5. exit

    In Interface Configuration Mode

    1. ipv6 address <specify IPv6 Address>
    2. ipv6 nd other-config-flag
    3. ipv6 dhcp server test rapid-commit

    Client Configuration

    In Global Configuration Mode

    1. enable
    2. configure terminal
    3. ipv6 unicast-routing

    In Interface Configuration Mode

    1. ipv6 address autoconfig
    2. ipv6 enable
    3. exit

     

    Configuration

     

    DHCPv6 ServerDHCPv6 Client


    !
    version 15.1
    !
    hostname R1
    !
    ipv6 unicast-routing
    ipv6 dhcp pool test
    dns-server AAAA:BBBB:10FE:100::15
    dns-server 2010:AA01::15
    domain-name example.com
    !
    !
    interface GigabitEthernet0/0/1
    ipv6 address 2010:AA01:10::2/64
    ipv6 nd other-config-flag
    ipv6 dhcp server test rapid-commit
    !
    !
    end

    !
    version 15.0
    !
    hostname R2
    !
    ipv6 unicast-routing
    ipv6 cef
    !
    !
    interface FastEthernet0/1
    ipv6 address autoconfig
    ipv6 enable
    !
    end

     

    Note: Note that in the above configuration, the DHCP server is not configured with any address prefix but only with DNS information. Similarly in the client side is configured to obtain the IPv6 address automatically using the SLAAC.

    Verify Commands
    debug ipv6 dhcp detail

     

    To display the detailed information about DHCP for IPv6 message decoding use this command. The below output shows the detailed message decoding at the client side.

     

    R2#debug ipv6 dhcp detail
    *Oct 29 15:14:03.195: IPv6 DHCP: Sending INFORMATION-REQUEST to FF02::1:2 on FastEthernet0/1
    *Oct 29 15:14:03.195: IPv6 DHCP: detailed packet contents
    *Oct 29 15:14:03.195:   src FE80::224:14FF:FE57:6451
    *Oct 29 15:14:03.195:   dst FF02::1:2 (FastEthernet0/1)
    *Oct 29 15:14:03.195:   type INFORMATION-REQUEST(11), xid 5776019
    *Oct 29 15:14:03.199:   option ELAPSED-TIME(8), len 2
    *Oct 29 15:14:03.199:     elapsed-time 0
    *Oct 29 15:14:03.199:   option CLIENTID(1), len 10
    *Oct 29 15:14:03.199:     00030001002414576450
    *Oct 29 15:14:03.199:   option ORO(6), len 6
    *Oct 29 15:14:03.199:     DNS-SERVERS,DOMAIN-LIST,INFO-REFRESH
    *Oct 29 15:14:03.199: IPv6 DHCP: DHCPv6 changes state from IDLE to INFORMATION-REQUEST (STATELESS) on FastEthernet0/1
    *Oct 29 15:14:03.199: IPv6 DHCP: Received REPLY from FE80::D68C:B5FF:FE2E:E101 on FastEthernet0/1
    *Oct 29 15:14:03.203: IPv6 DHCP: detailed packet contents
    *Oct 29 15:14:03.203:   src FE80::D68C:B5FF:FE2E:E101 (FastEthernet0/1)
    *Oct 29 15:14:03.203:   dst FE80::224:14FF:FE57:6451 (FastEthernet0/1)
    *Oct 29 15:14:03.203:   type REPLY(7), xid 5776019
    *Oct 29 15:14:03.203:   option SERVERID(2), len 10
    *Oct 29 15:14:03.203:     00030001D48CB52EE100
    *Oct 29 15:14:03.203:   option CLIENTID(1), len 10
    *Oct 29 15:14:03.203:     00030001002414576450
    *Oct 29 15:14:03.203:   option DNS-SERVERS(23), len 32
    *Oct 29 15:14:03.203:     AAAA:BBBB:10FE:100::15
    *Oct 29 15:14:03.203:     2010:AA01::15
    *Oct 29 15:14:03.203:   option DOMAIN-LIST(24), len 13
    *Oct 29 15:14:03.203:     example.com
    *Oct 29 15:14:03.203: IPv6 DHCP: Adding server FE80::D68C:B5FF:FE2E:E101
    *Oct 29 15:14:03.203: IPv6 DHCP: Processing options
    *Oct 29 15:14:03.203: IPv6 DHCP: Configuring DNS server AAAA:BBBB:10FE:100::15
    *Oct 29 15:14:03.203: IPv6 DHCP: Configuring DNS server 2010:AA01::15
    *Oct 29 15:14:03.203: IPv6 DHCP: Configuring domain name example.com
    *Oct 29 15:14:03.203: IPv6 DHCP: DHCPv6 changes state from INFORMATION-REQUEST to IDLE (REPLY_RECEIVED) on FastEthernet0/1

    show ipv6 dhcp interface

    This command shows that interface Fa0/0 is configured in client  mode and also shows the details of the DNS server address and the domain  name that it received from the DHCP server.

     

    R2#show ipv6 dhcp interface
    FastEthernet0/1 is in client mode
      Prefix State is IDLE (0)
      Information refresh timer expires in 23:43:01
      Address State is IDLE
      List of known servers:
        Reachable via address: FE80::D68C:B5FF:FE2E:E101
        DUID: 00030001D48CB52EE100
        Preference: 0
        Configuration parameters:
          DNS server: AAAA:BBBB:10FE:100::15
          DNS server: 2010:AA01::15
          Domain name: example.com
          Information refresh time: 0
      Prefix Rapid-Commit: disabled
      Address Rapid-Commit: disabled

    show ipv6 dhcp pool

     

    To display the DHCPv6 pool information, in the DHCPv6 server use this command. The output shows that the  number of active clients is 1 and  also displays other configuration  parameter information, such as domain  name server address and preferred  life time information.

     

    R1#show ipv6 dhcp pool
    DHCPv6 pool: test
      DNS server: AAAA:BBBB:10FE:100::15
      DNS server: 2010:AA01::15
      Domain name: example.com
      Active clients: 0

     

    Note: In th e above output, the DHCP pool has only the DNS information and there is no IP address assignment.

    References
    Routing Information Protocol
    Version history
    Revision #:
    2 of 2
    Last update:
    4 weeks ago
    Updated by:
     
    Contributors