Assigning a Fixed IP Address Based on dhcp-client-identifier

Glen R. J. Neff neff_glen at emc.com
Tue May 19 16:56:46 UTC 2009


On Tue, 2009-05-19 at 09:30 -0700, Scott Coleman wrote:
> I want to assign IP addresses to clients based solely on their Option
> 61 client IDs. For convenience/test purposes, I want to do this on a
> subnet that already has a regular DHCP server, so I want my test dhcpd
> to only assign an address to "known" clients (i.e. clients which have
> a matching client ID listed in the config file). I've come up with
> something that seems like it should work, but every time a client does
> a DHCPDISCOVER the server reports "no free leases."
> 

> subnet 10.24.0.0 netmask 255.255.0.0
> {
>   pool
>   {
>     allow members of "test";
>     option routers 10.24.7.1;
>     option domain-name-servers 10.24.7.1;
>     range 10.24.7.10 10.24.7.100;
>     deny unknown-clients;
>   }
> }
> 
> host pos_30
> {
>   option dhcp-client-identifier "\0pos_30";
>   option host-name "pos_30";
>   fixed-address 10.24.7.30;
> }
> 
> host pos_31
> {
>   option dhcp-client-identifier "\0pos_31";
>   option host-name "pos_31";
>   fixed-address 10.24.7.31;

This is kind of counter-intuitive, and I've fought with this before, but
static assignments need to be outside your scope.

-G

-- 
/*
 * Glen R. J. Neff
 * RTP TSG Network Team
 * neff_glen at emc.com
 *
 * EMC^2 == E^2
 */



More information about the dhcp-users mailing list