On Mon, Jun 26, 2017 at 08:26:03PM -0500, Edgar Pettijohn wrote:
I found the following conflict between dhcp-options(5) and dhcpd.conf(5).


From dhcpd.conf:

As you can see in Example 2, it's legal to specify host addresses in
parameters as hostnames rather than as numeric IP addresses. If a given hostname resolves to more than one IP address (for example, if that host has two Ethernet interfaces), both addresses are supplied to the client.


From dhcp-options:

The ip-address data type can be entered either as an explicit IP address
    (e.g., 239.254.197.10) or as a domain name (e.g., haagen.isc.org).  A
    domain name must resolve to a single IP address.


Does anyone know which is correct? Must it resolve to a single IP address or not?
I'm not an expert but from what I know:

Almost all parameters taking an ip-address argument allow multiple
arguments, thus making multiple IP addresses per hostname usable.

For those that except a single or strictly pairwise arguments such as
        dhcp-requested-address ip-address
and
        static-routes ip-address ip-address [, ip-address ip-address ...]
one may always use the first IP address a given hostname resolves to.

Generally speaking there's nothing wrong with hosntames resolving to
multiple IP addresses.

RFC 2131, Section 3.6 (Use of DHCP in clients with multiple interfaces)
for example states that
        A client with multiple network interfaces must use DHCP through
        each interface independently to obtain configuration information
        parameters for those separate interfaces.

Since clients will only accept a single DHCP offer which in turn is
always bound to the client's MAC address, DHCP can work just fine with
multiple interfaces/leases per host.

Thinking of techniques like round-robin DNS, expecting hostnames for
the ip-address type to resolve to a single IP address only could
actually cause problems.

Reply via email to