Knowledge Base ISC Main Website Ask a Question/Contact ISC
DHCPv6 and link-local IPv6 interface addresses
Author: Tomasz Mrugalski Reference Number: AA-00368 Views: 131 Created: 2011-07-13 21:16 Last Updated: 2011-07-13 21:17 0 Rating/ Voters

Problem:

For DHCPv6 server, if we want dhcpd listening on a certain interface it requires a subnet declaration in dhcpd.conf which covers the interface's address, otherwise, the dhcpd server will refuse to
listen on the specified interface. For example, we see this message when starting the DHCP server:

No subnet6 declaration for eth0 (fe80::20c:29ff:fe1a:cc12).
** Ignoring requests on eth0. If this is not what
you want, please write a subnet6 declaration
in your dhcpd.conf file for the network segment
to which interface eth0 is attached. **


Answer:

It's not possible to have dhcpd listen on an interface if it's not declared via subnet6.

The message:

No subnet6 declaration for eth0 (fe80::20c:29ff:fe1a:cc12)

... means that there is no known IPv6 subnet defined in dhcpd.conf that matches the current configuration of eth0.

When starting, the server expects to be able to find at least one IPv6 interface that has been declared in the configuration file, otherwise (quite reasonably - since it can do nothing without at least one interface on which to be working) it will refuse to start.  It will report an error on each it finds that it doesn't have a subnet declaration for.

When configuring dhcpd, in your subnet declarations, you're describing your network rather than simply saying 'for pool X use interface Y'.  The subnet declarations are telling dhcpd which interfaces it needs to handle.

Now - think a bit more on this - a dhcp server is listening for local subnet traffic - so it should have interfaces configured on that subnet.  So could you configure the link local address?  Well maybe.  But does it make any sense to try to do this?  Are you wanting to serve addresses to clients from the link local address range?

Here's an example of how to do this in a production environment.  Let's assume that there is a subnet 2001:db8:1::/48.  You would do the following to start serving IPv6 addresses from that pool:

  1. Assign an address from that pool to one of your interfaces, e.g:
    ip addr add 2001:db8:1::1/48 dev eth0
  2. Add the following entry to your server config file:

    subnet6 2001:db8:1::/48 {
       range6 2001:db8:1::2 2001:db8:1::ff;
       }

  3. Start your server.

The server will detect that there is a 2001:db8:1::/48 pool in your network.  It will discover that your server is connected to that pool over eth0 interface as its address belongs to that pool.  The server will then start listening on that interface and will provide addresses from 2001:db8:1::2 to 2001:db8:1::ff.  (Note that the address that is used by the dhcp server itself was carefully excluded from that range).

So now, what to do about any other interfaces on the DHCP server machine.  If those interfaces have only link-local addresses (i.e. belonging to fe80::/10 prefix), the server will complain about not being able to detect to which subnet they are connected.  You can do one of 3 things here:

  1. Disable the interface (ifconfig eth0 down). dhcpd will ignore down interfaces.
  2. Assign (possibly a dummy) address to that interface, then define an empty subnet (i.e. a subnet6 without any range6 in it).
  3. Ignore the message as long as you have at least one interface that server is able to provide configuration over.

We plan to skip this error message for link local addresses in future versions of dhcpv6, but the bottom line is still that you need to have at least one interface with a genuine IPv6 address assigned to it.


© 2001-2017 Internet Systems Consortium

For assistance with problems and questions for which you have not been able to find an answer in our Knowledge Base, we recommend searching our community mailing list archives and/or posting your question there (you will need to register there first for your posts to be accepted). The bind-users and the dhcp-users lists particularly have a long-standing and active membership.

ISC relies on the financial support of the community to fund the development of its open source software products. If you would like to support future product evolution and maintenance as well having peace of mind knowing that our team of experts are poised to provide you with individual technical assistance whenever you call upon them, then please consider our Professional Subscription Support services - details can be found on our main website.

Feedback
  • There is no feedback for this article
Quick Jump Menu