classify by MAC address
Ruzsinszky Attila
ruzsinszky.attila at gmail.com
Mon Jan 23 06:35:12 UTC 2012
Hi Glenn,
> DHCPDISCOVER from 52:54:00:03:5d:62
>
> match if substring(hardware, 0, 4) = 1:52:54:0;
>
> So you probably want (and similar for the other classes)
>
> match if substring(hardware, 0, 3) = 52:54:0;
Something is not good:
class "KVM-vms" {
# match if binary-to-ascii (16,8,":",substring(hardware, 0, 4)) = "1:52:54:0"
match if substring(hardware, 0, 3) = 52:54:0;
log (debug, binary-to-ascii (16,8, ":", hardware));
}
class "VBox-vms" {
# match if binary-to-ascii (16,8,":",substring(hardware, 0, 4)) = "1:8:0:27";
match if substring(hardware, 0, 3) = 8:0:27;
log (debug, binary-to-ascii (16,8, ":", hardware));
}
class "VMware-vms" {
# match if binary-to-ascii (16,8,":",substring(hardware, 0, 4)) = "1:0:c:29";
match if substring(hardware, 0, 3) = 0:c:29;
log (debug, binary-to-ascii (16,8, ":", hardware));
}
The pools are:
pool {
allow members of "KVM-vms";
range 192.168.52.180 192.168.52.199;
}
pool {
allow members of "VBox-vms";
range 192.168.52.170 192.168.52.179;
}
pool {
allow members of "VMware-vms";
range 192.168.52.160 192.168.52.169;
}
pool {
range 192.168.52.21 192.168.52.29;
deny members of "KVM-vms";
deny members of "VBox-vms";
deny members of "VMware-vms";
}
I started a VBox and a VMware VM and they got IP
from the last (.21-.29) pool! Of course there aren't any
log in the messages file (log command in class).
Do you know what is the problem?
Jan 23 07:33:53 wspc7 dhcpd: Internet Systems Consortium DHCP Server V3.0.2
running on SuSE 9.3.
TIA,
Ruzsi
More information about the dhcp-users
mailing list