multi vlan subnet, wrong netmask and wrong router offer in PXE

Sten Carlsen stenc at
Tue Apr 7 11:13:43 UTC 2020

On 07-04-2020 11.51, nono monbou wrote:
> Hello
> I have a problem on pxe boot on one of my vlan.
> Dhcp offers the wrong netmask and the wrong router ip.
> Dhcp offer the netmask and the router ip  of the first declarated
> subnet in the dhcpd.conf.
> I join my dhcpd.conf
> For example
> A machine of the vlan 10 (subnet obtain
> ip address but 255.255.248 netmask and router ip.

Host statement are ALWAYS global BUT take some of their parameters from
the place where they are declared.

It looks like the host you refer to here is one of the following:


since these are declared in "subnet netmask"
and this is the only place where the router is mentioned.

Your class definitions are seemingly identical for each subnet? I
believe this is a big mistake, AFAIK class statements are global in
nature, so they may pick up the router from any of the places they are


Collect all host statements in one place outside the scope of all
subnets. E.g. at the end of the file.

Collect the class statements in the same way, as hosts. Then look for
another way to set the differentiating details in each pool.

> Could you help me ?
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at

Best regards

Sten Carlsen

No improvements come from shouting:


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the dhcp-users mailing list