host statement scope rules (ISC DHCP 3.0.5b1)
isc-dhcp-server at phil.globnix.org
Sat Jul 29 21:00:35 UTC 2006
On 2006-07-28 at 16:30 -0700, Ted Lemon wrote:
> Furthermore, if you know what you're doing, expressing a host statement
> in a non-global scope isn't an error. You need to remember that in the
> DHCP configuration there are actually two sorts of scope: IP address
> configuration scope, and IP option configuration scope. The two are
> tied together, but they aren't the same.
> The mistake people usually make with host declarations is to think "If I
> declare this in a subnet context, then it will only be in effect for
> hosts connected to that subnet, and will be ignored otherwise." This
> is not true: a host declaration matches the intended host if no fixed
> address is present, or if a fixed address that is present is valid on
> the network to which the host is connected. And for no other reason.
> However, a host declaration in a non-global context inherits the options
> and settings of the context in which it is declared. So moving it to
> the global scope is not a neutral act - it's going to inherit different
> configuration settings and options if you do that.
Thank you -- this is exactly what I was trying to express with:
} Whilst the host statement is matched at a global level, aren't
} attributes such as lease time values inherited based upon syntactic
} scope rather than address/netblock matching rules?
} We have generated configs which use host statements inside subnet
} scopes, knowing full well that the host statements are matched globally
} but wanting to be able to inherit values based upon which relay server
} sent data to us.
I can clarify and note that we don't use dynamic leases, but use DHCP
for fixed-address assignment.
So yes, we have some configs which are actively relying upon being able
to set different lease-times and different DNS servers (for crude
load-balancing) based upon which relay-server forwarded the DHCP packets
to us, ie which subnet is in use.
Given that there _IS_ valid reason to place a host declaration within a
subnet syntactic scope, is it possible that ISC could consider having a
"I'm not being stupid" option which can be turned on to disable this
VISTA: Viruses, Infections, Spyware, Trojans & Adware
More information about the dhcp-users