Opened 3 years ago
Closed 3 years ago
#18951 closed defect (fixed)
kea systemd unit does not work
| Reported by: | Xi Ruoyao | Owned by: | pierre |
|---|---|---|---|
| Priority: | normal | Milestone: | 12.1 |
| Component: | BOOK | Version: | systemd |
| Severity: | medium | Keywords: | |
| Cc: |
Description
- The book mentions "make install-kea-dhcpd", but the systemd units Makefile only has "install-kea".
- The .service file lacks
RuntimeDirectory=kea, causing the service fail to start. - The .service file lacks
Type=forkingandPIDFile=.... It usesRemainAfterExit=trueinstead but this is not really correct. For example, if someone uses thekillcommand to kill the kea server process, systemd will fail to detect this and report the service still "running".
Change History (6)
follow-up: 2 comment:1 by , 3 years ago
comment:2 by , 3 years ago
Replying to pierre:
After some tests, it seems jhalfs works ok for this unit, but, the make target is wrong in the book. Will change it.
Actually, the book shouldn't be changed, because the target for sysv bootscripts is install-kea-dhcpd, and it is better to have only one instruction common for both revisions. Since the systemd-units tarball has to be changed anyway, it is better to change the target in the systemd-units tarball.
comment:3 by , 3 years ago
I'm not a systemd user, but I guess this part of the doc might be useful...
comment:5 by , 3 years ago
| Owner: | changed from to |
|---|---|
| Status: | new → assigned |
comment:6 by , 3 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Using https://gist.github.com/Skywalker-11/29ab856ed3c88f0eadc6e833f32fa78a and editing for our layout + adding RuntimeDirectory=kea allows the daemon to be started by systemd. Fixed at commit 6e841ea in systemd-units repository. Text adjustments will be done as part of updating kea (#18953).

After some tests, it seems jhalfs works ok for this unit, but, the make target is wrong in the book. Will change it.