DHCP for multiple networks with static and dynamic assignments

Randy Grimshaw rgrimsha at syr.edu
Fri Mar 2 13:47:05 UTC 2007

There have been some suggested feature request solutions to this, but
for now the answer is to create multiple definitions for each host. like

host STAxxxxxxxxxxx {
   hardware ethernet xx:xx:xx:xx:xx:xx;
   fixed-address 123.456.789.101;
host DYNxxxxxxxxxxx {
   hardware ethernet xx:xx:xx:xx:xx:xx;

the server will assign a static when an appropriate static is
available, and the dynamic definition will be used otherwise.


<><Randall Grimshaw
Room 203 Machinery Hall
Syracuse University
Syracuse, NY   13244
rgrimsha at syr.edu

>>> wheart at lab103.ict.pwr.wroc.pl 3/2/2007 8:00:56 AM >>>
I'm operating network splitted into few physical networks (sometimes 
containing several logical subnets). There are two DHCP servers
in fail-over configuration.
Some networks works as "public" so there are no static leases, but more

often static leases (for permanent users) comes with dynamic pool (for


Users may migrate between physical networks, and when they use network

other then their "home" network - they should get an address from

I've noticed that when host address is defined statically (host
in one network, dynamic address assigning doesn't work for that host in
networks - just leaving "no free leases" information in logs. At the
time there are about 10 free leases for given subnet on each server, so

when I remove static address assignment for given host - address is 
assigned and everything works OK.

Log looks like:
Mar  2 13:56:52 server dhcpd: DHCPDISCOVER from 00:16:36:70:f2:34 via 
x.y.z.254: network net_big: no free leases

I'm using ISC DHCPD versions 3.0.1 and 3.0.4 (both linux).

Now my dhcpd.conf looks like:

# some global options

shared-network network_name_n {	# for every physical network
         max-lease-time 86400;
         default-lease-time 43200;

         subnet x.x.x.x netmask 255.255.255.x {
                 option routers x.x.x.x;
                 option broadcast-address x.x.x.x;
                 option domain-name-servers x.x.x.x, x.x.x.x, x.x.x.x;

 		pool {
 			# pool specific options

 	subnet x.x.x.y netmask 255.255.255.x {
                 option routers x.x.x.y;
                 option broadcast-address x.x.x.y;
                 option domain-name-servers x.x.x.x, x.x.x.x, x.x.x.x;

                 pool {
         		# pool specific options

# set of hosts declarations

What I'm doing wrong?

Wojciech Penar

         Wojciech 'Wheart' Penar
  e-mail: wheart.ict.pwr.wroc.pl

More information about the dhcp-users mailing list