[Kea-users] Non working relay when using raw socket / config-control config-databases

Kevin Olbrich ko at sv01.de
Sun Jul 19 20:35:59 UTC 2020


Hi!

Currently I'm struggling with two features of Kea.

First issue is, that relayed requests are not answered when Kea runs
with a raw-socket (because the server also assigns IPs in it's own
network).
If I change raw to udp, relayed requests work flawlessly. I always had
this issue with Kea but the docs state, raw should also work with
relayed requests:
"When using raw sockets, both the traffic from the directly connected
clients and the relayed traffic are handled."
(https://kea.readthedocs.io/en/kea-1.6.2/arm/dhcp4-srv.html)
At least for me, that's not the case.

My second issue is about the config-control config-databases:
https://kb.isc.org/docs/using-the-kea-configuration-backend

I've defined my subnets via the mysql schema but to make it work, I
have to add this code for every subnet:
    "subnet4": [
        {
            "id": 1,
            "subnet": "192.168.0.0/24",
            "pools": []
        } ...

Host reservations from the DB are also loaded / applied when this
snippet is available.

These hooks are loaded:
        "hooks-libraries": [
            {
                "library":
"/usr/lib/x86_64-linux-gnu/kea/hooks/libdhcp_lease_cmds.so"
            },
            {
                "library":
"/usr/lib/x86_64-linux-gnu/kea/hooks/libdhcp_mysql_cb.so"
            },
            {
                "library":
"/usr/lib/x86_64-linux-gnu/kea/hooks/libdhcp_stat_cmds.so"
            }
        ],


Is this the only way to make Kea serve these subnets? Do I need
premium hooks (cb_cmds) if I want to avoid the subnet declaration in
local config?
The subnets are attached to a server-tag but Kea always complains with
"DHCP4_PACKET_NAK_0001 - failed to select a subnet for incoming
packet" if I remove the subnet4 block.
According to the docs, this module is needed to have Change-APIs
available (rest, etc.) but I don't need them - the database is handled
by me directly.

Kind regards
Kevin


More information about the Kea-users mailing list