Apologies if this report turns out to be a duplicate; I did look through
bugs.d.o (and those PRs listed by reportbug) but didn't find an existing
one for this issue.
The problem is that the isc-dhcp-server package installation fails in
it's last step:
(#) root@master:~
>>> apt-get install isc-dhcp-server -y
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
policykit-1 isc-dhcp-server-ldap
The following NEW packages will be installed:
isc-dhcp-server
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/548 kB of archives.
After this operation, 1,468 kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously unselected package isc-dhcp-server.
(Reading database ... 56261 files and directories currently installed.)
Preparing to unpack .../isc-dhcp-server_4.4.1-2_amd64.deb ...
Unpacking isc-dhcp-server (4.4.1-2) ...
Processing triggers for systemd (240-2) ...
Processing triggers for man-db (2.8.4-3) ...
Setting up isc-dhcp-server (4.4.1-2) ...
Generating /etc/default/isc-dhcp-server...
restorecon: lstat(/var/lib/dhcp/dhcpd.leases) failed: No such file or directory
dpkg: error processing package isc-dhcp-server (--configure):
installed isc-dhcp-server package post-installation script subprocess returned error exit status 255
Processing triggers for systemd (240-2) ...
Errors were encountered while processing:
isc-dhcp-server
needrestart is being skipped since dpkg has failed
E: Sub-process /usr/bin/dpkg returned an error code (1)
Disabling copy-on-write on /var/cache/apt/pkgcache.bin
This is easily fixed with "touch /var/lib/dhcp/dhcpd.leases" followed by a
reinvokation of apt-get:
(#) root@master:~
>>> touch /var/lib/dhcp/dhcpd.leases; apt-get install isc-dhcp-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
isc-dhcp-server is already the newest version (4.4.1-2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up isc-dhcp-server (4.4.1-2) ...
Job for isc-dhcp-server.service failed because the control process exited with error code.
See "systemctl status isc-dhcp-server.service" and "journalctl -xe" for details.
invoke-rc.d: initscript isc-dhcp-server, action "start" failed.
[...expected service startup errors regarding lack of configuration...]