One subnet, two pools, one with a default gateway, the other without

Randall C Grimshaw rgrimsha at syr.edu
Mon Aug 12 19:17:33 UTC 2013


The problem with groups that you will encounter is that when systems do a followup DHCPINFO request - for device descovery or whatever - which seems to be the modus operandi for the major OS.... The DHCP server will only be able to provide the defaults and not the values that you expect. My experience with this effect is mostly for DNS server values so your results may vary for route info, but the risk is there.

I tend to include these preferences within the subnet definitions and use secondaries to carve up the network.

Randall Grimshaw rgrimsha at syr.edu
________________________________________
From: dhcp-users-bounces+rgrimsha=syr.edu at lists.isc.org [dhcp-users-bounces+rgrimsha=syr.edu at lists.isc.org] on behalf of Ugo Bellavance [ugob at lubik.ca]
Sent: Monday, August 12, 2013 2:02 PM
To: dhcp-users at lists.isc.org
Subject: Re: One subnet, two pools, one with a default gateway, the other       without

Le 2013-08-12 13:12, Steven Carr a écrit :
> On 12 August 2013 16:29, Ugo Bellavance <ugob at lubik.ca> wrote:
>> Using that configuration, all clients get the subnet's config (so even the
>> ones I want to have no default gateway get one).  If I remove the subnet's
>> config, the "Reservations" hosts don't get a default gateway while they
>> should.
>
> The DHCP config uses inheritance for the various levels e.g. pool from
> subnet, subnet from global. Host objects inherit from global and the
> subnet that they are in (and as was recently discussed in another
> thread it is bad practice to include host declarations inside the
> subnet declaration as they are globally defined).
>
> So in order to achieve what you want you need to remove the routers
> option from the subnet declaration, add the routers option to the pool
> declaration that needs a router and then also add the routers option
> to each host declaration.

Great, thanks to your very quick answer.

I thought it would be to make a group out of it to make it easier to manage:

group {
         option routers 192.168.x.1;
         host HOST1 { hardware ethernet 00:50:56:94:3C:6F; fixed-address
192.168.x.152; }
         host HOST2 { hardware ethernet 00:0f:fe:8a:5a:cf; fixed-address
192.168.x.151; }
         }

My tests tell me that it works, does it make sense?

Thanks,

Ugo

_______________________________________________
dhcp-users mailing list
dhcp-users at lists.isc.org
https://lists.isc.org/mailman/listinfo/dhcp-users


More information about the dhcp-users mailing list