[Kea-users] Hosts Storage DB and multiple subnets/scopes

mtint hpc hpcmtint at gmail.com
Wed Oct 4 16:27:07 UTC 2023


I see this documentation
https://github.com/josh73/migrate-host-reservations-to-kea-mysql/tree/master


but i can't confirm or verify this - link does not exixts
https://downloads.isc.org/isc/kea/cur/2.5/doc/html/search.html?q=ipv4-subnet-id&check_keywords=yes&area=default

dhcpd_subnet_id A unique number associated with a particular subnet. See
https://downloads.isc.org/isc/kea/cur/doc/kea-guide.html#ipv4-subnet-id

On Wed, 4 Oct 2023 at 15:06, mtint hpc <hpcmtint at gmail.com> wrote:

> Hi All,
>
> We have pre-allocated all my desktops, 400+  in current DDI (replacing
> with Kea/phpIPAM).
> Hoping to do the same with kea. I see in section Hosts Storage,
>
> // The example below is not optimal from a performance perspective, but it
> // nicely showcases the host reservation capabilities. Please use the
> minimum
> // set of identifier types used in your network.
>
>
>
> *  "host-reservation-identifiers":    [ "circuit-id", "hw-address",
> "duid", "client-id" ],*
>
> // Specify connection to the database holding host reservations. The type
> // specifies that the MySQL database is used. user and password are the
> // credentials used to connect to the database. host and name specify
> // location of the host where the database instance is running, and the
> // name of the database to use. The server processing a packet will first
> // check if there are any reservations specified for this client in the
> // reservations list, within the subnet (configuration file). If there are
> // no reservations there, the server will try to retrieve reservations
> // from this database.
>   "hosts-database": {
>     "type": "mysql",
>     "reconnect-wait-time": 3000, // expressed in ms
>     "max-reconnect-tries": 3,
>     "name": "keatest",
>     "user": "keatest",
>     "password": "keatest",
>     "host": "localhost",
>     "port": 3306,
>     "trust-anchor": "my-ca",
>     "cert-file": "my-cert",
>     "key-file": "my-key",
>     "cipher-list": "AES"
>   },
>
>   "id": 1 <== is the subnet id?
>
> how does it work with multiple subnets/scopes, is there a column to
> identify a different subnet?
> in *host-reservation-identifiers *
>
> typically config but in my case reservations all in DB.
> {
> "subnet4": [
>     {
>         "id": 1,
>         "pools": [ { "pool":  "192.0.2.1 - 192.0.2.200" } ],
>         "subnet": "192.0.2.0/24",
>         "interface": "eth0",
>         "reservations": [
>             {
>                 "hw-address": "1a:1b:1c:1d:1e:1f",
>                 "ip-address": "192.0.2.202"
>             },
>             {
>                 "duid": "0a:0b:0c:0d:0e:0f",
>                 "ip-address": "192.0.2.100",
>                 "hostname": "alice-laptop"
>             },
>             {
>                 "circuit-id": "'charter950'",
>                 "ip-address": "192.0.2.203"
>             },
>             {
>                 "client-id": "01:11:22:33:44:55:66",
>                 "ip-address": "192.0.2.204"
>             }
>         ]
>     }
> ],
>
> Regards,
>
> Michael
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20231004/0d712f07/attachment-0001.htm>


More information about the Kea-users mailing list