Re: [Kea-users] Converting a dhcpd option to kea

2023-10-23 Thread Darren Ankney
Hi,

You may want to have a look at the Kea Migration Assistant Online
site: https://dhcp.isc.org for help migrating an ISC DHCP
configuration to Kea (though it cannot automatically convert all parts
of some ISC DHCP configurations).  You configuration could be broken
into three parts.  The custom option definition
(https://kea.readthedocs.io/en/kea-2.2.0/arm/dhcp4-srv.html#custom-dhcpv4-options),
the Class definition / membership
(https://kea.readthedocs.io/en/kea-2.2.0/arm/classify.html), and the
setting of values in the custom options inside the class
(https://kea.readthedocs.io/en/kea-2.2.0/arm/classify.html).

Converted, it might look something like the below which I obtained
from the aforementioned https://dhcp.isc.org I have not tested the
config for functionality (though it looks to me like it would work),
only for correct syntax (meaning Kea will start and run using this
config).  Hopefully this (and the Kea Migration Assistant site) help!

{
  "Dhcp4": {
"option-def": [
  {
"space": "Nutanix",
"name": "fc_ip",
"code": 200,
"type": "string"
  },
  {
"space": "Nutanix",
"name": "api_key",
"code": 201,
"type": "string"
  }
],
"client-classes": [
  {
"name": "NutanixFC",
"test": "option[60].hex == 'NutanixFC'",
"option-def": [
  {
"name": "vendor-encapsulated-options",
"code": 43,
"type": "empty",
"encapsulate": "Nutanix"
  }
],
"option-data": [
  {
"name": "vendor-encapsulated-options",
"code": 43
  },
  {
"space": "Nutanix",
"name": "fc_ip",
"code": 200,
"data": "10.1.1.1"
  },
  {
"space": "Nutanix",
"name": "api_key",
"code": 201,
"data":
"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJLZXlVVUlEIjoiZjE2MzBkYzMtODU0OC00YjZiLTZlMWMtZTVlOTU0YjM1NTQ2In0.HB_IdIaFvvyHpfzDzLZMQkHKstRsdiWnEMoqtU4N4kY"
  }
]
  }
]
  }
}

Thank you,

Darren Ankney

On Mon, Oct 23, 2023 at 4:25 PM Marcos Della  wrote:
>
> I have the following from dhcpd that I wanted to convert to KEA. I'm 
> struggling with how to implement it correctly:
>
> option space Nutanix;
> option Nutanix.fc_ip code 200 = string;
> option Nutanix.api_key code 201 = string;
> class “NutanixFC” {
> match if option vendor-class-identifier = “NutanixFC”;
>
> vendor-option-space Nutanix;
>
> option Nutanix.fc_ip “10.1.1.1”;
>
> option Nutanix.api_key 
> “eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJLZXlVVUlEIjoiZjE2MzBkYzMtODU0OC00YjZiLTZlMWMtZTVlOTU0YjM1NTQ2In0.HB_IdIaFvvyHpfzDzLZMQkHKstRsdiWnEMoqtU4N4kY”;}
>
> --
> 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.
>
> Kea-users mailing list
> Kea-users@lists.isc.org
> https://lists.isc.org/mailman/listinfo/kea-users
-- 
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.

Kea-users mailing list
Kea-users@lists.isc.org
https://lists.isc.org/mailman/listinfo/kea-users


[Kea-users] Converting a dhcpd option to kea

2023-10-23 Thread Marcos Della
I have the following from dhcpd that I wanted to convert to KEA. I'm
struggling with how to implement it correctly:

option space Nutanix;
option Nutanix.fc_ip code 200 = string;
option Nutanix.api_key code 201 = string;
class “NutanixFC” {
match if option vendor-class-identifier = “NutanixFC”;

vendor-option-space Nutanix;

option Nutanix.fc_ip “10.1.1.1”;

option Nutanix.api_key
“eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJLZXlVVUlEIjoiZjE2MzBkYzMtODU0OC00YjZiLTZlMWMtZTVlOTU0YjM1NTQ2In0.HB_IdIaFvvyHpfzDzLZMQkHKstRsdiWnEMoqtU4N4kY”;}
-- 
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.

Kea-users mailing list
Kea-users@lists.isc.org
https://lists.isc.org/mailman/listinfo/kea-users