Web lists-archives.com

RE: dhcp service problem on stretch




Hi,

>On Thu, Sep 06, 2018 at 05:33:39PM +0000, Bonno Bloksma wrote:
>> Sep 06 17:47:42 linom1 isc-dhcp-server[1668]: Launching both IPv4 and IPv6 servers (please configure INTERFACES in /etc/default/isc-dhcp-server if
> Please edit the file above and place your network interfaces there.


Ok, so that is new probably. Never had to do that.
On my old jessie server I had just the default file:
----<quote>-------------
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACES=""
----<quote>-------------

That file on my new stretch server now has:
----<quote>-------------
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACESv4="ens192"
INTERFACESv6=""
----<quote>-------------

But.....
----<quote>-------------
linom1:/etc/default# service isc-dhcp-server stop
linom1:/etc/default# service isc-dhcp-server start
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.

linom1:/etc/default# service isc-dhcp-server status
● isc-dhcp-server.service - LSB: DHCP server
   Loaded: loaded (/etc/init.d/isc-dhcp-server; generated; vendor preset: enabled)
   Active: failed (Result: exit-code) since Fri 2018-09-07 11:35:57 CEST; 32s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 7646 ExecStart=/etc/init.d/isc-dhcp-server start (code=exited, status=1/FAILURE)
    Tasks: 1 (limit: 4915)
   CGroup: /system.slice/isc-dhcp-server.service
           └─1409 /usr/sbin/dhcpd -4 -q -cf /etc/dhcp/dhcpd.conf

Sep 07 11:35:57 linom1 systemd[1]: Starting LSB: DHCP server...
Sep 07 11:35:57 linom1 isc-dhcp-server[7646]: /etc/init.d/isc-dhcp-server: 50: /etc/init.d/isc-dhcp-server: cannot open /etc/dhcp/dhcpd6.conf: No such file
Sep 07 11:35:57 linom1 isc-dhcp-server[7646]: Launching IPv4 server only.
Sep 07 11:35:57 linom1 isc-dhcp-server[7646]: Starting ISC DHCPv4 server: dhcpddhcpd service already running (pid file /var/run/dhcpd.pid currenty exists) ... failed!
Sep 07 11:35:57 linom1 systemd[1]: isc-dhcp-server.service: Control process exited, code=exited status=1
Sep 07 11:35:57 linom1 systemd[1]: Failed to start LSB: DHCP server.
Sep 07 11:35:57 linom1 systemd[1]: isc-dhcp-server.service: Unit entered failed state.
Sep 07 11:35:57 linom1 systemd[1]: isc-dhcp-server.service: Failed with result 'exit-code'.
----<quote>-------------

Ok, it still wants to open a dhcpd6 config file.
Commented the  INTERFACESv6="" line 
And it STILL wants to open the dhcpd6 config file.

I put the original dhcpd6.conf file back in place, it is just a bunch of comment lines and some defaults.
It still does NOT want to start.

----<quote>-------------
-- Unit isc-dhcp-server.service has begun starting up.
Sep 07 11:40:31 linom1 isc-dhcp-server[7741]: Launching IPv4 server only.
Sep 07 11:40:31 linom1 isc-dhcp-server[7741]: Starting ISC DHCPv4 server: dhcpddhcpd service already running (pid file /var/run/dhcpd.pid currenty exists) ... failed!
Sep 07 11:40:31 linom1 systemd[1]: isc-dhcp-server.service: Control process exited, code=exited status=1
Sep 07 11:40:31 linom1 systemd[1]: Failed to start LSB: DHCP server.
-- Subject: Unit isc-dhcp-server.service has failed
----<quote>-------------

Seems it does not want to stop either. 
I have never had this much problems getting a simple DHCP server running. :-(

Ok, did:
# apt-get remove isc-dhcp-server
# apt-get purge
reboot
Hmm, purge did not clean everything so:
# rm /etc/default/isc-dhcp-server
# rm /etc/dhcp/dhcpd*
Then
----<quote>-------------
# apt-get install isc-dhcp-server
linom1:/etc/dhcp# service isc-dhcp-server status
● isc-dhcp-server.service - LSB: DHCP server
   Loaded: loaded (/etc/init.d/isc-dhcp-server; generated; vendor preset: enabled)
   Active: active (exited) since Fri 2018-09-07 11:45:23 CEST; 4min 57s ago
     Docs: man:systemd-sysv-generator(8)
   CGroup: /system.slice/isc-dhcp-server.service

Sep 07 11:45:23 linom1 systemd[1]: Starting LSB: DHCP server...
Sep 07 11:45:23 linom1 systemd[1]: Started LSB: DHCP server.
----<quote>-------------

Ok, I have default server running again. But with what?
Why the heck does this NOT produce any errors?
----<quote>-------------
linom1:/etc/dhcp# ls
debug  dhclient.conf  dhclient-enter-hooks.d  dhclient-exit-hooks.d
----<quote>-------------
There is NOT a single dhcpd*.conf file present.

I am giving up. I have no idea what is happenign any more, it seems this has gone for something simple to something wierd.
I have been doing this for close to 20 years, running Linux servers with DHCP, but this leaves me frustrated.
I am going to let this rest for a few weeks and then start allover again with a fresh new Debian stretch server with noting else on it but a default isc-dhcp-server and take it from there.

I anyone has any helpful insights, please post them. I will read them when i go back to this project.

Bonno Bloksma