Report information
The Basics
Id:
45638
Status:
open
Priority:
Medium/Medium
Queue:

People
Owner:
Nobody in particular
Cc:
AdminCc:

BugTracker
Version Fixed:
(no value)
Version Found:
(no value)
Versions Affected:
(no value)
Versions Planned:
(no value)
Priority:
(no value)
Severity:
(no value)
CVSS Score:
(no value)
CVE ID:
(no value)
Component:
(no value)
Area:
bug

Dates
Created:Fri, 28 Jul 2017 09:38:11 -0400
Updated:Wed, 09 Aug 2017 06:46:48 -0400
Closed:Not set



This bug tracker is no longer active.

Please go to our Gitlab to submit issues (both feature requests and bug reports) for active projects maintained by Internet Systems Consortium (ISC).

Due to security and confidentiality requirements, full access is limited to the primary maintainers.

Date: Fri, 28 Jul 2017 13:38:05 +0000
To: dhcp-bugs@isc.org
Subject: dhcp-4.3.3-P1 - dhcpd.leases file is not rotating
From: "Kate Andreeva" <katja@fusionlayer.com>
Bug Report from www.isc.org: Name: Kate Andreeva Email: katja@fusionlayer.com Software Version: dhcp-4.3.3-P1 OS: CentOS 6 Subject:dhcpd.leases file is not rotating Bug Detail =========== File dhcpd.leases is not rotating on regular basis. This causes file growth up go few GBs and dhcpd daemon cannot start because it cannot parse such huge file. As a workaround we changing permissions of "/var/lib/dhcpd/dhcpd.leases" to root:root and restarting dhcpd. System changes permissions to "dhcp:dhcp" and the lease rotation started working. This bug was around for few years (according to community), would be really great to fix it. --- This email was received through isc.org Bug Submission Form
On Fri Jul 28 13:38:11 2017, katja@fusionlayer.com wrote: > Bug Report from www.isc.org: > > Name: Kate Andreeva > Email: katja@fusionlayer.com > Software Version: dhcp-4.3.3-P1 > OS: CentOS 6 > Subject:dhcpd.leases file is not rotating > > > Bug Detail > =========== > File dhcpd.leases is not rotating on regular basis. This causes file > growth up go few GBs and dhcpd daemon cannot start because it cannot > parse such huge file. As a workaround we changing permissions of > "/var/lib/dhcpd/dhcpd.leases" to root:root and restarting dhcpd. > System changes permissions to "dhcp:dhcp" and the lease rotation > started working. > > This bug was around for few years (according to community), would be > really great to fix it. > > --- > This email was received through isc.org Bug Submission Form Hello: Normal operation of dhcpd is to append lease updates to the lease file and once per hour recreate the lease, keeping only the most current lease information per lease. This interval is hard coded into the server. The basic process consists of: 1. Closing the existing lease file and rename it by appending a "~" 2. Opening a new lease file and writing out all of the known leases All lease updates append to the new lease until the next rewrite, 60 minutes later. So an hour after startup, even with no lease activity, you should see <leaese file> and <lease file>~. This functionality has been part of the server for a very long time. The server must be started as root because it must be able to open raw sockets. By default then the lease file is owned by root. Even if something else comes along later and alters ownership of the lease file, the server should still be able rewrite the lease file as it is running as root. There is a build configure option, --enable-paranoia, which compiles in support for dhcpd command line arguments -user, -group, and -chroot (see dhcpd.8). These may be used to allow the server to be started as root and later change privileges to those specified by the arguments. When this is the case, the lease file will be created and owned by the user and/or group specified. Again though, this will not impact lease file rewrites as the server's uid/gid still own the lease file. Please note that this configure option is off by default. We would like to see the command line being used to invoke dhcpd. Could you explain what in the "system" is changing the lease file ownership? Did you compile and install from source or are you running an installed package? Also it would be worthwhile examining the system logs to look for errors. You should be able to look for when the server started and then at 60 minute intervals in the logs beyond that.
Hello Kate: Are you still experiencing issues with this? Regards, Thomas Markwalder ISC Software Engineering On Fri Jul 28 18:47:47 2017, tmark wrote: > On Fri Jul 28 13:38:11 2017, katja@fusionlayer.com wrote: > > Bug Report from www.isc.org: > > > > Name: Kate Andreeva > > Email: katja@fusionlayer.com > > Software Version: dhcp-4.3.3-P1 > > OS: CentOS 6 > > Subject:dhcpd.leases file is not rotating > > > > > > Bug Detail > > =========== > > File dhcpd.leases is not rotating on regular basis. This causes file > > growth up go few GBs and dhcpd daemon cannot start because it cannot > > parse such huge file. As a workaround we changing permissions of > > "/var/lib/dhcpd/dhcpd.leases" to root:root and restarting dhcpd. > > System changes permissions to "dhcp:dhcp" and the lease rotation > > started working. > > > > This bug was around for few years (according to community), would be > > really great to fix it. > > > > --- > > This email was received through isc.org Bug Submission Form > > Hello: > > Normal operation of dhcpd is to append lease updates to the lease file > and once per hour recreate the lease, keeping only the most current > lease information per lease. This interval is hard coded into the > server. The basic process consists of: > > 1. Closing the existing lease file and rename it by appending a "~" > 2. Opening a new lease file and writing out all of the known leases > > All lease updates append to the new lease until the next rewrite, 60 > minutes later. > So an hour after startup, even with no lease activity, you should see > <leaese file> and <lease file>~. > > This functionality has been part of the server for a very long time. > > The server must be started as root because it must be able to open raw > sockets. By default then the lease file is owned by root. Even if > something else comes along later and alters ownership of the lease > file, the server should still be able rewrite the lease file as it is > running as root. > > There is a build configure option, --enable-paranoia, which compiles > in support for dhcpd command line arguments -user, -group, and -chroot > (see dhcpd.8). These may be used to allow the server to be started as > root and later change privileges to those specified by the arguments. > When this is the case, the lease file will be created and owned by the > user and/or group specified. Again though, this will not impact lease > file rewrites as the server's uid/gid still own the lease file. > Please note that this configure option is off by default. > > We would like to see the command line being used to invoke dhcpd. > > Could you explain what in the "system" is changing the lease file > ownership? > > Did you compile and install from source or are you running an > installed package? > > Also it would be worthwhile examining the system logs to look for > errors. You should be able to look for when the server started and > then at 60 minute intervals in the logs beyond that.