Re: DHCP server - map to host names?

From: Whoever (nobody@devnull.none)
Date: 04/22/03


From: Whoever <nobody@devnull.none>
Date: Tue, 22 Apr 2003 17:59:47 GMT

On Thu, 17 Apr 2003, Dave Miner wrote:

> John Howells wrote:
> >
> > LHradowy wrote:
> >
> >>How would I set up the DHCP server to map ip's to the host names, currently
> >>I am mapping to the MAC address. I am running currently SUN 5.7
> >
> >
> > If the question is
> >
> >
> > how can I set up the DHCP server so that a machine that has its name set
> > to 'fred' always has the address '1.2.3.4' without having to set a
> > static MAC address allocation in the network table, and so that even if
> > the MAC address of 'fred' were to change it would still have the address
> > '1.2.3.4' allocated
> > <<
> >
> > I think the answer is you cannot. The DHCP server can only allocate
> > dynamic or static addresses, and the latter can only be done against MAC
> > address.
> >
>
> This isn't quite true, in that the DHCP server allocates address to a client's
> identifier; usually this is defaulted to being based on the MAC address, but
> some clients (such as Solaris and the ISC client for Linux and other Unixes) can
> be set to send an arbitrary string as the client identifier, and this could be a
> hostname in those cases.

This isn't quite true. Firstly, this is a function of the dhcp server, and
before any absolute statements such as this are made, one should know
which server is being discussed.

With ISC's DHCP server, you can match on the client identifier (usually
based on the MAC address) or you can match and allocate based on the MAC
address itself (and ignore the client identifier).

>From "man dhcpd.conf":

  Host declarations are matched to actual DHCP or BOOTP clients by
matching the dhcp-client-identifier option specified in the host
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
declaration to the one sup-plied by the client, or, if the host
declaration or the client does not provide a dhcp-client-identifier
option, by matching the hardware parameter in the host declaration to the
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
network hardware address supplied by the client. BOOTP clients do not
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
normally provide a dhcp-client-identifier, so the hardware address must be
used for all clients that may boot using the BOOTP protocol.



Relevant Pages

  • Re: DHCP server - map to host names?
    ... The DHCP server can only allocate ... and the latter can only be done against MAC ... > some clients can ... Host declarations are matched to actual DHCP or BOOTP clients by ...
    (comp.unix.solaris)
  • Re: Understanding the DHCP Server Client conversation (very intresting subject)
    ... why not the DHCP server just sends its offer to the client that is requesting the service according to its MAC address?? ... you said the (DHCP server send the DHCP OFFER as a unicast, to the whole network) but a specified MAC address. ...
    (microsoft.public.cert.exam.mcse)
  • Re: DHCP Leasing
    ... >>> One hour after their leasing, the DHCP server goes down. ... >> This is not quite how DHCP leases work. ... >> the DHCP server, not the client. ... >> will use an APIPA address and continue to rebroadcast a Discovery packet ...
    (microsoft.public.cert.exam.mcse)
  • Re: mac address issue
    ... mac address that was different in some way that just resulted in the DHCP ... Sounds like the client is sent our a DHCP request, ... your DHCP server is replying with an offer, but the client is sending back ... Modeled after the famous Black Hat event ...
    (Security-Basics)
  • Re: DHCP client and XPE FP2007
    ... If you put your device through FBA with its NIC connected to a network that ... start with a REQUEST for the remembered IP address. ... "remembered address" can not be leased by the DHCP server then your device ... But if I reboot the client ...
    (microsoft.public.windowsxp.embedded)