Hi,
In a specific subnet, there are some DHCP clients that I don't want to have a default gateway, but I want all the other clients to have a default gateway set.
I can identify the exception hosts by MAC address without problem, but what would I use as config in dhcpd.conf?
For the curious, I need this config because most clients in this subnet are regular clients, with only one IP address, but a few of them are Windows clients that are in 2 vlans and if I provide two default gateway to a Windows machine, it doesn't know which one to use or chooses randomly, and when it uses the wrong one, it can't reach its destination.
Here is what I tried:
Code:
subnet 192.168.13.0 netmask 255.255.255.0 {
class "Win" {
match hardware;
}
subclass "Win" 64:31:50:33:B5:23;
subclass "Win" 40:0e:85:03:61:17;
# Pools
pool {
range 192.168.13.50 192.168.13.150;
option domain-name-servers 192.168.x.x,192.168.x.x;
option domain-name "mydomain.lan";
option routers 192.168.13.1;
option subnet-mask 255.255.255.0;
deny members of "Win";
}
pool {
range 192.168.13.170 192.168.13.200;
option domain-name-servers 192.168.x.x,192.168.x.x;
option domain-name "mydomain.lan";
option subnet-mask 255.255.255.0;
allow members of "Win";
deny unknown-clients;
}
}
However, clients that match the configured MAC addresses still get the same IP address and still get the default gateway.