Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jun 2025 18:40:02 +0200
From:      A FreeBSD User <freebsd@walstatt-de.de>
To:        FreeBSD CURRENT <freebsd-current@freebsd.org>, FreeBSD Ports <freebsd-ports@freebsd.org>
Subject:   net/kea: [2.6.3_1]: Unable to open database: invalid path specified - only /var/db as folder allowed
Message-ID:  <20250622184029.76567686@thor.sb211.local>

index | next in thread | raw e-mail

[-- Attachment #1 --]
After a recent update of net/kea (now at 2.6.3_1), kea rejects to startup because we have our
lease database not within /var/db/kea, but in /pool/data/kea.

According to the documentation provided at

https://kea.readthedocs.io/en/latest/arm/dhcp4-srv.html#dhcpv4-server-configuration

this is a intended behaviour since kea 2.7.9. For me, this change in 2.6.3 came out of the
blue and hit hard.

To solve the problem for those having other folders in mind than the at compile time fixed
one, one has to set the environment variable KEA_DHCP_DATA_DIR before startup of kea.

I have no clear idea were to put the proper definition of this environmental variable BEFORE
kea starts up. I tried using /etc/login.conf:

[...]
:setenv=BLOCKSIZE=K,KEA_DHCP_DATA_DIR=/pool/data/kea/:\
[...]

but the downside is that the rc-script in /usr/local/etc/rc.d/kea requirs 

REQUIRE: LOGIN ...

before being effective. Consequence: net/kea doesn't start properly when KEA_DHCP_DATA_DIR is
set via /etc/login.conf.

I guess the approach regarding /etc/login.conf is as wrong as changing the rc.d script's
milestone from NETWORK to LOGIN.

Is there a clean way - apart from changing rc.d-script - to provide environment variables at
boottime?

Thanks in advance,

oh

p.s. filed a PR: Bug 287598 


-- 

A FreeBSD user

[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQRQheDybVktG5eW/1Kxzvs8OqokrwUCaFgx/QAKCRCxzvs8Oqok
r8bHAP4inPfORxl0kSkopKuP52i03M4VKWoAf4D1EHfJI/orcQD7ByBCxAibZIg2
GqMduN2iJXfCYqvS3cPbH2abrsbHnQc=
=R5Bj
-----END PGP SIGNATURE-----
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20250622184029.76567686>