[Kea-users] How to Configure MySQL backend?

Thomas Andersen than at itu.dk
Mon Apr 25 19:33:41 UTC 2016


Hi Jonis,

I had a few problems inserting host reservations. Heres a line from my perl script.

my $sth = $dbh->prepare("INSERT INTO hosts (dhcp_identifier, dhcp_identifier_type, dhcp4_subnet_id, ipv4_address, hostname) VALUES (UNHEX(?), ?, ?, INET_ATON(?) ,?)") or die $dbh->errstr;
$sth->execute($mac, 0, $vlan, $ip, $hostname) or die $dbh->errstr;

/Thomas

From: <kea-users-bounces at lists.isc.org<mailto:kea-users-bounces at lists.isc.org>> on behalf of Jonis Maurin Ceara <jonis at fearp.usp.br<mailto:jonis at fearp.usp.br>>
Date: Monday 25 April 2016 at 21:15
Cc: "Kea-users at lists.isc.org<mailto:Kea-users at lists.isc.org>" <Kea-users at lists.isc.org<mailto:Kea-users at lists.isc.org>>
Subject: Re: [Kea-users] How to Configure MySQL backend?

Tks Jan and Thomas, that's exactly what I need: Host reservation. :)



Jonis Maurin Ceará
Analista de Sistemas
FEA-RP
Help Desk +55 (16) 3315-3898
Audiovisual +55 (16) 3315-3927
Desenv. Sistemas +55 (16) 3315-4485
Infraestrutura +55 (16) 3315-8539 / 0672
Atendimento Web: http://suporte.fearp.usp.br

________________________________
De: "Jan Schermer" <jan at schermer.cz<mailto:jan at schermer.cz>>
Para: "Jonis Maurin Ceara" <jonis at fearp.usp.br<mailto:jonis at fearp.usp.br>>
Cc: Kea-users at lists.isc.org<mailto:Kea-users at lists.isc.org>
Enviadas: Segunda-feira, 25 de Abril de 2016 16:11:09
Assunto: Re: [Kea-users] How to Configure MySQL backend?

This is excerpt from my config

I'm sure I got it either from examples (possibly the a spec file for the json config?) or docs on the site (they leave a lot to be desired, that's true :))

{
  "Dhcp4": {
    "interfaces-config": {
      "interfaces": ["eth0"]
    },
    "lease-database": {
      "host": "localhost",
      "name": "kea",
      "password": "password",
      "type": "mysql",
      "user": "kea"
};


Jan


On 25 Apr 2016, at 21:07, Jonis Maurin Ceara <jonis at fearp.usp.br<mailto:jonis at fearp.usp.br>> wrote:

Hi!
I'm trying to use MySQL as backend for DHCP, but I can't find documentation for this configuration. I've found how to compile and import tables ( http://kea.isc.org/docs/kea-guide.html ), but there's no documentation about how to configure for MySQL usage (mysql host, username, etc etc...).


Jonis Maurin Ceará
Analista de Sistemas
FEA-RP
Help Desk +55 (16) 3315-3898
Audiovisual +55 (16) 3315-3927
Desenv. Sistemas +55 (16) 3315-4485
Infraestrutura +55 (16) 3315-8539 / 0672
Atendimento Web: http://suporte.fearp.usp.br<http://suporte.fearp.usp.br/>

_______________________________________________
Kea-users mailing list
Kea-users at lists.isc.org<mailto:Kea-users at lists.isc.org>
https://lists.isc.org/mailman/listinfo/kea-users


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20160425/82a27465/attachment.htm>


More information about the Kea-users mailing list