Ich habe mich versucht nach dem Wiki zu richten und scheitere schon mit dem Start.
https://wiki.debian.org/DHCP_Server (ist laut history aktueller, aber nutzt immer noch eth0)
oder die deutsche Version
https://wiki.debian.org/de/DHCP_Server
Ich habe sudo apt install isc-dhcp-server gemacht, wobei schon divers rote Meldungen kamen (s.u.) und danach explizit ein dbpk-reconfigure isc-dhcp-server und die Schnittstelle enp3s0 gesetzt.
Dann den Server neu gestartet, wobei die selbe Meldung auftaucht, wie schon bei der Installation.
Code: Alles auswählen
sudo service isc-dhcp-server restart
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.
user ~ 1 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 2021-09-18 15:45:59 CEST; 29s ago
Docs: man:systemd-sysv-generator(8)
Process: 15777 ExecStart=/etc/init.d/isc-dhcp-server start (code=exited, status=1/FAILURE)
CPU: 25ms
Sep 18 15:45:57 TONNE dhcpd[15793]: before submitting a bug. These pages explain the proper
Sep 18 15:45:57 TONNE dhcpd[15793]: process and the information we find helpful for debugging.
Sep 18 15:45:57 TONNE dhcpd[15793]:
Sep 18 15:45:57 TONNE dhcpd[15793]: exiting.
Sep 18 15:45:59 TONNE isc-dhcp-server[15777]: Starting ISC DHCPv4 server: dhcpdcheck syslog for diagnostics. ...
Sep 18 15:45:59 TONNE isc-dhcp-server[15798]: failed!
Sep 18 15:45:59 TONNE isc-dhcp-server[15799]: failed!
Sep 18 15:45:59 TONNE systemd[1]: isc-dhcp-server.service: Control process exited, code=exited, status=1/FAILURE
Sep 18 15:45:59 TONNE systemd[1]: isc-dhcp-server.service: Failed with result 'exit-code'.
Sep 18 15:45:59 TONNE systemd[1]: Failed to start LSB: DHCP server.
Code: Alles auswählen
sudo cat /etc/default/isc-dhcp-server
# Kommentare ausgelassen
INTERFACESv4="enp3s0"
INTERFACESv6=""
Code: Alles auswählen
sudo cat /etc/dhcp/dhcpd.conf
# dhcpd.conf
# ohne Kommentare
option domain-name "example.org";
option domain-name-servers ns1.example.org, ns2.example.org;
default-lease-time 600;
max-lease-time 7200;
ddns-update-style none;
In /var/log/syslog steht was. Warum nicht in dem systemd-log-journal-zeug? Man weis nie so genau, wo man nun hinschauen soll.
Der erste Teil der Meldung ist klar. Sollte aber den Start an sich nicht verhindern. Der zweite Teil behauptet "Not configured to listen on any interfaces!" - was ich IMHO aber mit der Option INTERFACESv4 doch eigentlich bedient haben sollte.
Code: Alles auswählen
Sep 18 15:59:46 TONNE dhcpd[16079]: Wrote 0 leases to leases file.
Sep 18 15:59:46 TONNE dhcpd[16079]:
Sep 18 15:59:46 TONNE dhcpd[16079]: No subnet declaration for enp3s0 (no IPv4 addresses).
Sep 18 15:59:46 TONNE dhcpd[16079]: ** Ignoring requests on enp3s0. If this is not what
Sep 18 15:59:46 TONNE dhcpd[16079]: you want, please write a subnet declaration
Sep 18 15:59:46 TONNE dhcpd[16079]: in your dhcpd.conf file for the network segment
Sep 18 15:59:46 TONNE dhcpd[16079]: to which interface enp3s0 is attached. **
Sep 18 15:59:46 TONNE dhcpd[16079]:
Sep 18 15:59:46 TONNE dhcpd[16079]:
Sep 18 15:59:46 TONNE dhcpd[16079]: Not configured to listen on any interfaces!
Sep 18 15:59:46 TONNE dhcpd[16079]:
Sep 18 15:59:46 TONNE dhcpd[16079]: If you think you have received this message due to a bug rather
Sep 18 15:59:46 TONNE dhcpd[16079]: than a configuration issue please read the section on submitting
Sep 18 15:59:46 TONNE dhcpd[16079]: bugs on either our web page at www.isc.org or in the README file
Sep 18 15:59:46 TONNE dhcpd[16079]: before submitting a bug. These pages explain the proper
Sep 18 15:59:46 TONNE dhcpd[16079]: process and the information we find helpful for debugging.
Sep 18 15:59:46 TONNE dhcpd[16079]:
Sep 18 15:59:46 TONNE dhcpd[16079]: exiting.