Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
03-24-2015, 10:04 PM
|
#1
|
Member
Registered: Jan 2010
Posts: 121
Rep:
|
dhcp no free leases
I have seen this error here, and elsewhere. I tried deleting /var/lib/dhcpd/dhcpd.leases and restarting dhcpd, same problem. So I am hoping someone has a better set of eyes than I do.
Code:
Mar 24 19:47:50 tsui dhcpd: DHCPDISCOVER from f0:4d:a2:40:a0:5a via em1: network 10.1.1.0/24: no free leases
Mar 24 19:47:54 tsui dhcpd: DHCPDISCOVER from f0:4d:a2:40:a0:5a via em1: network 10.1.1.0/24: no free leases
Mar 24 19:48:02 tsui dhcpd: DHCPDISCOVER from f0:4d:a2:40:a0:5a via em1: network 10.1.1.0/24: no free leases
Mar 24 19:48:18 tsui dhcpd: DHCPDISCOVER from f0:4d:a2:40:a0:5a via em1: network 10.1.1.0/24: no free leases
Mar 24 19:48:50 tsui dhcpd: DHCPDISCOVER from f0:4d:a2:40:a0:5a via em1: network 10.1.1.0/24: no free leases
Code:
[root@tsui dhcp]# more /etc/dhcp/dhcpd.conf
ddns-update-style none;
subnet 10.1.1.0 netmask 255.255.255.0 {
default-lease-time 1200;
max-lease-time 1200;
option routers 10.1.1.1;
option subnet-mask 255.255.255.0;
option domain-name "local";
option domain-name-servers 10.1.1.1;
option broadcast-address 10.1.1.255;
option interface-mtu 1500;
group "local" {
host tsui-em1 {
hardware ethernet F0:4D:A2:40:9B:26;
option host-name "tsui";
fixed-address 10.1.1.1;
filename "pxelinux.0";
next-server 10.1.1.1;
}
}
}
The address in the messages is from the machine I am trying to PXE boot. I have a Netgear8 port switch between the two machines. Pretty simple setup for testing, but even this isn't working. Maybe I missed something in the config file.
|
|
|
03-25-2015, 03:04 AM
|
#2
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,505
|
A quick looks shows that you have no range directive, so your dhcp server doesn't know what range of IPs to give out, so you'll never get one.
|
|
2 members found this post helpful.
|
03-25-2015, 12:28 PM
|
#3
|
Member
Registered: Jan 2010
Posts: 121
Original Poster
Rep:
|
Giving it a range statement solved the problem, but we have several machines set up using ROCKS which installs a dhcp server. They are all working, and none have a range statement, but at least it offered the client an IP. Still, the client is not booting. On the client side I received:
No bootfile name received
Installing the head node, which has the dhcp server is all canned, so I don't know why I am having all these issues.
|
|
|
09-04-2016, 10:07 PM
|
#4
|
LQ Newbie
Registered: May 2004
Posts: 8
Rep:
|
We're having the same problem did you ever find a solution?
|
|
|
05-29-2017, 03:14 PM
|
#5
|
Member
Registered: Nov 2007
Posts: 37
Rep:
|
@brownwrap (03-24-15) There are no free leases, because there are no ranges defined where they might apply.
You need a range statement inside each subnet{} block. EG
Code:
range 10.1.1.129 10.1.1.199;
Add that line following your max-lease-time line.
Notice the dhcpd.conf(5) manpage says "For any subnet on which addresses will be assigned dynamically, there must be at least one range statement." This is in ISC DHCPd which is the DHCP daemon in many open source distributions.
|
|
|
05-30-2017, 04:36 AM
|
#6
|
Senior Member
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,505
|
Quote:
Originally Posted by clsgis
@brownwrap (03-24-15) There are no free leases, because there are no ranges defined where they might apply.
|
lol, wow, congratulations on repeating the answer that was given 2 years ago and acknowledged by the OP!
|
|
|
06-01-2017, 10:59 AM
|
#7
|
Member
Registered: Nov 2007
Posts: 37
Rep:
|
Jeering not called for
OP left out the part where the range declaration has to be inside the subnet block braces. I found seven different threads on Linuxquestions and the CentOS and Ubuntu forums where people were asking about that same error message and getting no answer. About half of them had no range statement at all, and the other half had the range statement outside the braces where it no longer has any effect.
|
|
|
All times are GMT -5. The time now is 05:51 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|