Class detection problem

Simon Hobson dhcp1 at
Thu Dec 4 16:03:10 UTC 2008

Bernardo Pita wrote:

>subnet netmask { ignore booting; }
>class "test" {
>     match pick-first-value (option dhcp-client-identifier, hardware);
>subclass "test" 1:00:16:92:3d:d2:08;
>subclass "test" 1:00:1b:d7:02:44:17;
>shared-network share {
>     subnet netmask {
>             option routers;
>             pool {
>                     range;
>                     allow members of "test";
>                     deny unknown clients;
>             }
>     }
>You can see two macs address in the class "test" and one pool in 
> to them, but the DHCP says:
>dhcpd: DHCPDISCOVER from 00:1b:d7:02:44:17 via network 
>share: no free leases
>dhcpd: DHCPDISCOVER from 00:16:92:3d:d2:08 via network 
>share: no free leases

You've explicitly denied them from that pool : "deny unknown 
clients;" You don't need to do this as anything NOT matching class 
"test" will be implicitly denied.

>If I put manually something like this in the pool statement:
>pool {
>     host test1 { hardware ethernet 00:16:92:3d:d2:08; }
>     host test2 { hardware ethernet 00:1b:d7:02:44:17; }
>     range;
>     deny unknown clients;

Please DO NOT put host statements anywhere but the global scope. They 
are (mostly) global in scope but inherit options from where they are 
declared. By defining them anywhere but the global scope leaves you 
open to some very strange behaviour due to unexpected option 

Also, the config you've posted does not include a shared-network. I'd 
strongly recommend that unless you really need it, you don't declare 
it - people get terribly confused by the shared-network declaration.

Simon Hobson

Visit for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.

More information about the dhcp-users mailing list