How can I get isc-dhcp-server/dhcpd to listen on one interface only?
22,775
Try seting the INTERFACE
variable in /etc/default/isc-dhcp-server
to the desired interface. For example:
INTERFACES="eth2"
Related videos on Youtube
Author by
Kalle Richter
Updated on September 18, 2022Comments
-
Kalle Richter over 1 year
I would like my
isc-dhcp-server
instance to listen on my LAN interface only because I'm investigating an issue with my "WiFi router" and configuredINTERFACES='p18p1'
in/etc/default/isc-dhcp-server
wherep18p1
is my LAN interface. However, after restart withsudo systemctl restart isc-dhcp-server.service
if seeudp 0 0 0.0.0.0:67 0.0.0.0:* 23088/dhcpd
in the output of
sudo netstat -tupln | grep 67
which leads me to believe that theinterfaces
configuration value is ignored. Specifyinginterfaces p18p1;
in/etc/dhcpd/dhcpd.conf
causes thesystemd
unit to fail to start - it seems to enforce specification of interfaces in/etc/default/isc-dhcp-server
.I'm using Ubuntu 17.04.
-
heemayl almost 7 yearsWhats the output of
systemctl cat isc-dhcp-server.service
? Also if you dosudo /etc/init.d/isc-dhcp-server restart
, does it work?
-
-
Mehmet Fide over 2 yearsdidn't work on Ubuntu 20.04