[Kea-users] dhcp6 address assignment

perl-list perl-list at network1.net
Tue Oct 18 18:47:53 UTC 2022


>    1. I used to assign same ipv6 address for the same machine which was dial boot
>    linux/windows. It was possible by assigning same ipv6 address to both DUIDs
>    before. But in kea this is not allowed. I found out there is a possibility to
>    assign ipv6 address by MAC address which was not possible in ISC DHCPD. I was
>     very happy with that finding but fallen into second problem.


You could make a client class (https://kea.readthedocs.io/en/latest/arm/dhcp6-srv.html#reserving-client-classes-in-dhcpv6) for each dual booting client with both duids in the class.

Then make very tiny pools with only one address assigned to those classes

I think the below should work.

<SNIP>
"client-classes": [
  {
    "name": "WINDOWS1",
    "test": "(substring(option[1].hex,0,all) == 0x000203090505149182b5fb4c) or (substring(option[1].hex,0,all) == 0x0001000126ffbc3f001c42bdc36c)"
  },
  {
    "name": "WINDOWS2",
    "test": "(substring(option[1].hex,0,all) == 0x0001000116c3c001) or (substring(option[1].hex,0,all) == 0x0001000116c3c001)"
  }
],

<SNIP>
"subnet6": [
  {
<SNIP>
    "subnet": "2001:db8:2e50:e8::/64",
    "pools": [
      {
        "pool": "2001:db8:2e50:e8::1-2001:db8:2e50:e8::1",
        "client-class": "WINDOWS1"
      },
      {
        "pool": "2001:db8:2e50:e8::2-2001:db8:2e50:e8::2",
        "client-class": "WINDOWS2"
      }
],
<SNIP>

>    2. The windows machine got 2 interfaces ethernet and wifi. I configured kea to
>    assign one ipv6 address to the ethernet adapter and another one to the wifi
>    adapter. But after investigating logs kea was receiving dhcp6 request over wifi
>    using the ethernet adapter mac address. How is this possible? Is it possible
>    the MAC address in DHCP does not match L2 MAC address? I did not sniff the
>    request, yet. I decided to switch back to DUID assignment since this problem is
>     worse than the previous.

This is likely because Kea is deriving the MAC address from the DUID (assuming the traffic was relayed).  The windows machine will most likely use the same DUID for all interfaces (at least it is supposed to or allowed to - I'd have to go review the RFC again to be sure).



More information about the Kea-users mailing list