[Kea-users] kea-ctrl-agent not able to get information

Marcin Siodelski marcin at isc.org
Mon May 28 09:42:42 UTC 2018


Hello,

Did you try to send something like this:

$ curl -X POST -H "Content-Type: application/json" -d '{ "command":
"config-get", "service": [ "dhcp4" ] }' http://ca.example.org:8000/

where "command" denotes what command to send to the server and the
"service" denotes whether the command should be forwarded to the DHCPv4
or DHCPv6 server (the server must be running). If you want to send a
command to be processed by the Control Agent (say, get CA's
configuration), the "service" argument must not be specified.

Some more information can be found here:

https://jenkins.isc.org/job/Kea_doc/guide/kea-guide.html#ctrl-channel-client

Marcin Siodelski
ISC


On 27.05.2018 15:23, mAineAc wrote:
> I have configured kea dhcp and I am getting leases and I can see this is
> working correctly. I can check the /usr/local/var/kea/kea-leases4.csv file
> and see leases in that. I have been trying to use the kea-ctrl-agent web
> interface to be able to view leases or even make changes as I can see that
> there are a bunch of commands. I am not sure how to pass these commands to
> the web interface. I browse to the age for the kea control agent port 8080
> as it is set up to do and all I get is: 
> 
> { "result": 400, "text": "Bad Request" }
> 
> This is all I see on the page. 
> 
> I can see that the hooks library gets loaded:
> 
> 2018-05-27 09:13:50.037 INFO  [kea-dhcp4.lease_cmds_hooks/1789]
> LEASE_CMDS_INIT_OK loading Lease Commands hooks library successful
> 2018-05-27 09:13:50.037 INFO  [kea-dhcp4.hooks/1789] HOOKS_LIBRARY_LOADED
> hooks library /usr/local/lib/hooks/libdhcp_lease_cmds.so successfully loaded
> 
> 
> But a few minutes later I get this message:
> 
>  2018-05-27 09:14:50.736 INFO  [kea-dhcp4.lease_cmds_hooks/1789]
> LEASE_CMDS_DEINIT_OK unloading Lease Commands hooks library successful
> 2018-05-27 09:14:50.736 INFO  [kea-dhcp4.hooks/1789] HOOKS_LIBRARY_UNLOADED
> hooks library /usr/local/lib/hooks/libdhcp_lease_cmds.so successfully
> unloaded
> 
> 
> Should this be unloading the library just after it is loaded? I am loading
> the library in my kea control config as well as my ipv6 and ipv4 config. I
> am also using the same ipv4 unix socket in my ipv4 config and my control
> config and the same iwth the ipv6 unix socket. 
> 
> I found a post that mentions this:
> 
> "I already implemented a web-frontend to the database (mysql) to show all
> the leases and reservations."
> 
> But, I am not sure I have done this step and this may be where I am messing
> up because I am not quite sure what is meant there and I did not see
> anything that tells how to d this in the install instructions. I have gone
> through the database instructions a couple of times. 
> 
> mAineAc
> 
> 
> 
> --
> Sent from: http://kea-users.7364.n8.nabble.com/
> _______________________________________________
> Kea-users mailing list
> Kea-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/kea-users
> 




More information about the Kea-users mailing list