[Kea-users] Configure a subnet in Kea configuration backend

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[Kea-users] Configure a subnet in Kea configuration backend

Dan Nguyen
Hello,


I'm trying to use Kea 1.6 with MariaDB in a project. Setup and install Kea + MariaDB cluster was fine. I then manually inserted a subnet and DHCP scope to database for testing. I had to insert manually because there is no way to add a subnet to database through Kea interface. Is there a better way to add a subnet via Kea interface?

I then used config-get command to get server's configuration but no subnet was shown and the server's log also said that it found no subnet. I had one in database so what could be the problem there?

Part of server's configuration is attached.


Thanks,

Dan Nguyen

_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users

dhcp-conf.txt (2K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] Configure a subnet in Kea configuration backend

Cathy Almond
Hi Dan,

On 14/11/2019 05:05, Dan Nguyen wrote:
> I'm trying to use Kea 1.6 with MariaDB in a project. Setup and install
> Kea + MariaDB cluster was fine. I then manually inserted a subnet and
> DHCP scope to database for testing. I had to insert manually because
> there is no way to add a subnet to database through Kea interface.

The notes in the Kea ARM suggest that if you're managing the
configuration backend directly, then you're best to use
commonly-available database tools to insert/modify/delete etcetera

https://kea.readthedocs.io/en/v1_6_0/arm/config.html#config-backend

> Is there a better way to add a subnet via Kea interface?

There is a much much easier way, but you need the cb_cmds hook for this,
and it's not a part of OpenSource Kea, you'll need a subscription to get
it.  I'm guessing, since you've not already gone this route, that this
isn't an option for you just now?

https://kea.readthedocs.io/en/v1_6_0/arm/hooks.html#cb-cmds-library

> I then used config-get command to get server's configuration but no
> subnet was shown and the server's log also said that it found no subnet.
> I had one in database so what could be the problem there?

I'm going to guess that there is something wrong or missing, such that
the Kea DHCPv4 server didn't load what you specified.

https://kea.readthedocs.io/en/v1_6_0/arm/dhcp4-srv.html#dhcp4-cb

There may be something helpful logged?  There look to be some promising
potential messages listed here that relate to the CB backend
(independent of the cb_cmds hook):

https://kea.readthedocs.io/en/v1_6_0/kea-messages.html#dhcp4

For example: DHCP4_CB_FETCH_UPDATES_FAIL

> Part of server's configuration is attached.

Nothing jumped out at me as being glaringly wrong - maybe others reading
will see what we might have missed, but I think the most likely cause of
this problem is not getting the configuration elements correct in the
DB, or perhaps there being a schema problem perhaps?

Hoping that the troubleshooting pointers help as a starting point for
you - and perhaps other people on the list have already tried doing what
you're doing and can give you further hints?

Cathy
_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users