Tuesday 15 January 2013

DHCPv6

DHCPv6 works pretty much the same way DHCP does in v4, with the obvious difference that it supports the new addressing scheme for IPv6. And it might come as a surprise, but there are a couple of other options that DHCP still provides for us that autoconfiguration doesn’t. I’m serious—there’s absolutely no mention of DNS servers, domain names, or many of the other options that DHCP has always provided for us via IPv4 with autoconfiguration. This is a big reason why it’s likely we’ll still be using DHCP in IPv6 most of the time.

Upon booting up in IPv4, a client sent out a DHCP discover message looking for a server to give it the information it needs. But remember, in IPv6, the RS and RA process happens first. If there’s a DHCPv6 server on the network, the RA that comes back to the client will tell it if DHCP is available for use. If a router isn’t found, the client will respond by sending out a DHCP solicit message—a solicit message that’s actually a multicast message addressed with a source of ff02::1:2, meaning all DHCP agents, both servers and relays.

It’s good to know that there’s some support for DHCPv6 in the Cisco IOS. But it’s limited to a stateless DHCP server, meaning it doesn’t offer any address management of the pool, plus the options available for configuring that address pool are limited to the DNS, domain name, and SIP servers only.

This means that you’re definitely going to need some other server around that can supply and dispense all the additional, required information, as well as manage the address assignment. Anyway, here’s how the configuration looks for the stateless DHCP server in the router IOS—it’s really close to what we’d configure with IPv4:

Router1(config)#ipv6 dhcp pool ?
WORD DHCP pool name
Router1(config)#ipv6 dhcp pool test
Router1(config-dhcp)#?

IPv6 DHCP configuration commands:
default       Set a command to its defaults
dns-server   DNS servers
domain-name  Domain name to complete unqualified host names
exit Exit from DHCPv6 configuration mode
no Negate a command or set its defaults
prefix-delegation IPv6 prefix delegation
sip SIP Servers options
Router1(config-dhcp)#dns-server ?

Hostname or X:X:X:X::X Server’s name or IPv6 address

Router1(config-dhcp)#domain-name lammle.com
Router1(config-dhcp)#prefix-delegation ?
X:X:X:X::X/<0-128> IPv6 x:x::y/<z>
aaa  Acquire prefix from AAA
pool  IPv6 prefix pool
Router1(config-dhcp)#prefix-delegation pool ?
WORD IPv6 prefix pool
Router1(config-dhcp)# prefix-delegation pool test ?
lifetime Configure prefix lifetimes
<cr>
Router1(config-dhcp)# prefix-delegation pool test lifetime ?
<60-4294967295> Valid lifetime (seconds)
at Expire prefix at a specific time/date infinite Infinite valid lifetime
Router1(config-dhcp)#prefix-delegation pool test lifetime 3600 ?
<60-4294967295> Preferred lifetime (seconds) infinite Infinite preferred lifetime
Router1(config-dhcp)#prefix-delegation pool test lifetime 3600 3600 ?
<cr>
Router1(config-dhcp)#prefix-delegation pool test lifetime 3600 3600
Notice that just like in DHCP with IPv4, you don’t need to set a lifetime.

Okay—now that I’ve got the pool configured, I just have to assign it to an interface, a departure from IPv4:Router1(config)#int fa 0/0
Router1(config-if)#ipv6 dhcp server ?
WORD Name of IPv6 DHCP pool
Router1(config-if)#ipv6 dhcp server test

Sweet—we now have a fully configured DHCPv6 server applied to our interface fa0/0!

No comments:

Post a Comment