OPNsense Forum

Archive => 24.1, 24.4 Legacy Series => Topic started by: 4yi89u on February 08, 2024, 10:50:46 PM

Title: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: 4yi89u on February 08, 2024, 10:50:46 PM
Hello,

I copied DHCP4 config to Kea, disabled DHCP4, and started KEA. But KEA does not start.

I rebooted computer. It still does not start

From general log search for KEA:

2024-02-08T13:46:19-08:00 Notice kernel <118>2024-02-08 13:46:19.103 ERROR [kea-dhcp4.dhcp4/90548.0x833b79000] DHCP4_INIT_FAIL failed to initialize Kea server: configuration error using file '/usr/local/etc/kea/kea-dhcp4.conf': One or more hook libraries failed to load
2024-02-08T13:46:19-08:00 Notice kernel <118>INFO/keactrl: Starting /usr/local/sbin/kea-ctrl-agent -c /usr/local/etc/kea/kea-ctrl-agent.conf
2024-02-08T13:46:19-08:00 Notice kernel <118>INFO/keactrl: Starting /usr/local/sbin/kea-dhcp4 -c /usr/local/etc/kea/kea-dhcp4.conf
2024-02-08T13:46:19-08:00 Notice kernel <118>Starting kea.
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: 4yi89u on February 08, 2024, 10:57:33 PM
I found that if CONTROL AGENT was started the KEA DHCP4 service failed to load.

Am I missing something? Is this intended operation?
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: ks98330q on February 13, 2024, 02:37:54 AM
Imma jump on this bandwagon too.  For me I have none the issues with KEA.  Until I enable the control agent.  Then I get the same error as this post is titled. 
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: patient0 on February 13, 2024, 09:12:43 AM
Quote from: 4yi89u on February 08, 2024, 10:57:33 PM
I found that if CONTROL AGENT was started the KEA DHCP4 service failed to load.

What is the bind port for the control agent and are you using in a HA setup?
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: trevs on January 06, 2025, 07:38:51 PM
I'm having the same issue, or so it seems. 
if I start the control agent then both it and the keadhcpserver services stop and will not start. 
disable the control agent and dhcp server works fine (all in kea). 

I'm in the process of setting up my backup opnsense (HA). So I need to figure this out. 

I set the bind IP to 127.0.0.1 and the port to 8070 (8070 is not in use). 
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: ckruijntjens on May 22, 2025, 10:24:35 PM
Did you ever figure this out? i have the same issue..
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: RMcB on June 20, 2025, 06:31:02 PM
I don't know if this will help anyone, but I am experiencing this same symptom.

I'm running OPNsense 25.1.8_1 configured for HA and KEA on my secondary node fails to start.  After reading patient0's comment I went looking at the KEA config of my secondary node and what I found was that the KEA control agent on my secondary node had the IP address of my primary node.

I reset the IP address to the secondary node's IP and KEA started normally.  When I checked the configuration of the secondary node later (after HA sync) the IP address was reset to the primary node's IP.

Is there maybe an issue with the HA sync that's overwriting the control agent IP address?
Title: Re: kea-dhcpv4 does not start One or more hook libraries failed to load
Post by: Patrick M. Hausen on June 20, 2025, 06:49:27 PM
I have not yet tried such a setup but you probably need to remove the Kea configuration from the XMLRPC sync and configure Kea's builtin HA mechanism.