I am setting up a DHCP server running on my wireless interface.
During boot the following messages show up in /var/log/syslog:
Nov 28 07:56:48 pi-w isc-dhcp-server[503]: Launching IPv4 server only.
Nov 28 07:56:51 pi-w isc-dhcp-server[503]: Starting ISC DHCPv4 server: dhcpdcheck syslog for diagnostics. ... failed!
Nov 28 07:56:51 pi-w isc-dhcp-server[503]: failed!
Nov 28 07:56:51 pi-w systemd[1]: isc-dhcp-server.service: Control process exited, code=exited, status=1/FAILURE
Nov 28 07:56:51 pi-w systemd[1]: isc-dhcp-server.service: Failed with result 'exit-code'.
/etc/default/isc-dhcp-server is:
# Defaults for isc-dhcp-server (sourced by /etc/init.d/isc-dhcp-server)
Path to dhcpd's config file (default: /etc/dhcp/dhcpd.conf).
#DHCPDv4_CONF=/etc/dhcp/dhcpd.conf
#DHCPDv6_CONF=/etc/dhcp/dhcpd6.conf
Path to dhcpd's PID file (default: /var/run/dhcpd.pid).
#DHCPDv4_PID=/var/run/dhcpd.pid
#DHCPDv6_PID=/var/run/dhcpd6.pid
Additional options to start dhcpd with.
Don't use options -cf or -pf here; use DHCPD_CONF/ DHCPD_PID instead
#OPTIONS=""
On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACESv4="wlan0"
#INTERFACESv6=""
Excerpt from /etc/dhcp/dhcpd.conf:
subnet 192.168.1.0 netmask 255.255.255.0 {
range 192.168.1.50 192.168.1.115;
option subnet-mask 255.255.255.0;
option domain-name-servers 192.168.1.254, 10.128.254.254;
option domain-name “example.com”;
option routers 192.168.1.1;
}
wlan0 is set to a static IP in /etc/dhcpcd.conf:
interface wlan0
static ip_address=192.168.1.22/24
static routers=192.168.1.1
static domain_name_servers=127.0.0.1
static domain_search=
When I run sudo systemctl start isc-dhcp-server it is successful:
Nov 28 08:09:39 pi-w isc-dhcp-server[627]: Launching IPv4 server only.
Nov 28 08:09:41 pi-w isc-dhcp-server[627]: Starting ISC DHCPv4 server: dhcpd.
sudo systemctl status isc-dhcp-server.service:
● isc-dhcp-server.service - LSB: DHCP server
Loaded: loaded (/etc/init.d/isc-dhcp-server; generated)
Active: failed (Result: exit-code) since Sat 2020-11-28 17:18:15 PST; 1min 26s ago
Docs: man:systemd-sysv-generator(8)
Process: 474 ExecStart=/etc/init.d/isc-dhcp-server start (code=exited, status=1/FAILURE)
Nov 28 17:18:13 pi-w dhcpd[594]: bugs on either our web page at www.isc.org or in the README file
Nov 28 17:18:13 pi-w dhcpd[594]: before submitting a bug. These pages explain the proper
Nov 28 17:18:13 pi-w dhcpd[594]: process and the information we find helpful for debugging.
Nov 28 17:18:13 pi-w dhcpd[594]:
Nov 28 17:18:13 pi-w dhcpd[594]: exiting.
Nov 28 17:18:15 pi-w isc-dhcp-server[474]: Starting ISC DHCPv4 server: dhcpdcheck syslog for diagnostics. ... failed!
Nov 28 17:18:15 pi-w isc-dhcp-server[474]: failed!
Nov 28 17:18:15 pi-w systemd[1]: isc-dhcp-server.service: Control process exited, code=exited, status=1/FAILURE
Nov 28 17:18:15 pi-w systemd[1]: isc-dhcp-server.service: Failed with result 'exit-code'.
Nov 28 17:18:15 pi-w systemd[1]: Failed to start LSB: DHCP server.
sudo systemctl cat isc-dhcp-server.service:
# /run/systemd/generator.late/isc-dhcp-server.service
# Automatically generated by systemd-sysv-generator
[Unit]
Documentation=man:systemd-sysv-generator(8)
SourcePath=/etc/init.d/isc-dhcp-server
Description=LSB: DHCP server
Before=multi-user.target
Before=multi-user.target
Before=multi-user.target
Before=graphical.target
After=remote-fs.target
After=network-online.target
After=slapd.service
After=nss-lookup.target
Wants=network-online.target
[Service]
Type=forking
Restart=no
TimeoutSec=5min
IgnoreSIGPIPE=no
KillMode=process