Hi Marcin Jurczuk

Generally if you like to use database as a configuration backend, then you must 
configure a database (mysql or postgres) in the configuration file and make the 
connection work (deploy DB schemas etc)
Kea-arm is your source to this

Subnets are either configured in the configuration file OR in the database 
backend – both scenarios does not work well together.
To use the database backend for subnet configuration you must disable the 
subnet libdhcp_subnet_cmds hooks library and use the libdhcp_cb_cmds instead. 
Not both.

When using the api for creating subnets you should look in the documentation at 
https://kea.readthedocs.io/en/latest/arm/hooks.html#libdhcp-cb-cmds-so-configuration-backend-commands
The api commands used for this all starts with ‘remote-‘ e.g. 
‘remote-subnet4-set’

I hope this will help you getting forward.
Kristen



Fra: Kea-users <[email protected]> På vegne af Marcin Jurczuk
Sendt: 19. november 2025 00:44
Til: [email protected]
Emne: [Kea-users] libdhcp_subnet_cmds and database insert

Du får ikke ofte mails fra [email protected]<mailto:[email protected]>. Få 
mere at vide om, hvorfor dette er 
vigtigt<https://aka.ms/LearnAboutSenderIdentification>
Hi,
I read basically all documentation about libdhcp_subnet_cmds hook and I still 
can't figure out how to force system to puth subnet config to database.
hosts_cmds have this option  called "operation-target" that allows you to 
define where config should be stored. It is not mentioned in subnet hook.
I'm able to insert network to config file(after API call to write cfg) but not 
to db.
What is operation-target equivalent or how force kea do save subnet to database.

Thanks in advance.
-- 
ISC funds the development of this software with paid support subscriptions. 
Contact us at https://www.isc.org/contact/ for more information.

To unsubscribe visit https://lists.isc.org/mailman/listinfo/kea-users.
[email protected]

Reply via email to