← Back to team overview

touch-packages team mailing list archive

[Bug 1186662] Re: isc-dhcp-server fails to renew lease file

 

On my second re-read of this thread I made my spot check and noticed

"
The proper fix is to have dhcpd open the leases file as user dhcpd during start and not root and having /var/lib/dhcp/ and the leases file belong to dhcpd:dhcpd.
"

which implies (correctly) that dhcpd opens dhcpd.leases before dropping
privileges, and also implies that maybe the ownership shennanigans are
due to dhcpd's failure to open the leases file as the non-privileged
user.

This is done because, as things are currently structured, dhcpd
initiates the failover relationships (which requires data from the
dhcpd.leases file) at the same time as it opens the listening sockets
(which requires privileges in the default configuration).

There may also be other information dependencies that I haven't noticed
yet.

We're evaluating our options at this point.

It will be helpful to know if the forcing of ownership to root:root of
the files and directory are being done as an attempt to cope with
dhcpd's behavior or if that is construed as a feature and the desired
state.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to isc-dhcp in Ubuntu.
https://bugs.launchpad.net/bugs/1186662

Title:
  isc-dhcp-server fails to renew lease file

Status in “isc-dhcp” package in Ubuntu:
  Triaged

Bug description:
  After raring upgrade, the dhcp server fails to renew lease file when
  it tries to (about every hour).

  The syslog says:
  dhcpd: Can't create new lease file: Permission denied

  It looks like a permission problem, because

  # chown -R dhcpd:dhcpd /var/lib/dhcp

  the above command temporarily solves the issue, until dhcpd is
  restarted: at that time, the ownership of the directory and the lease
  file is set back to root:root.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/isc-dhcp/+bug/1186662/+subscriptions