我有一个ubuntu 14.04服务器和isc-dhcpd-4.2.4。我已经在配置中定义的客户端可以获取他们的IP地址,新添加的mac地址无法获取他们的IP号码,我得到了#34;没有免费租用"错误。
我的/etc/dhcp/dhcpd.conf文件是:
option domain-name "xxx.com";
option domain-name-servers 10.0.0.2;
option local-pac-server code 252 = text;
option local-pac-server "http://10.0.0.50/proxy.pac";
default-lease-time 28800;
max-lease-time 86400;
authoritative;
ddns-update-style none;
log-facility local3;
option ntp-servers 10.0.0.50;
option routers 10.0.0.1;
option subnet-mask 255.255.252.0;
option netbios-node-type 8;
option netbios-name-servers 10.0.0.2;
option netbios-dd-server 10.0.0.2;
option 46xxOptions code 176 = string;
option 46xxOptions "MCIPADD=10.0.0.92,MCPORT=1719,TFTPSRVR=10.0.0.40,VLANTEST=0";
subnet 10.0.0.0 netmask 255.255.252.0 {
group ist {
include "/etc/dhcp/dhcpd.body";
}
}
在dhcpd.body中定义了794个ip地址,最后两行是这样的:
host s793 {
hardware ethernet 00:80:64:7B:D5:38;
fixed-address 10.0.3.97;
}
host s794 {
hardware ethernet 00:80:64:67:4D:42;
fixed-address 10.0.3.98;
}
我的/var/lib/dhcp/dhcpd.lease文件是:
# The format of this file is documented in the dhcpd.leases(5) manual page.
# This lease file was written by isc-dhcp-4.2.4
server-duid "\000\001\000\001\032\353\222k\000\025]\000\023\031";
但是当我检查日志时:
tail -f /var/log/syslog
我收到了这个错误:
Apr 28 13:50:34 okubuntuserver dhcpd: DHCPDISCOVER from 00:15:70:4d:2c:ff via eth0: network 10.0.0.0/22: no free leases
Apr 28 13:50:35 okubuntuserver dhcpd: DHCPDISCOVER from 00:15:70:62:db:76 via eth0: network 10.0.0.0/22: no free leases
但是这些mac地址已经在dhcpd.body中配置。