← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1861032] [NEW] [RFE] Add support for configuring dnsmasq with multiple IPv6 addresses in same subnet on same port

 

Public bug reported:

To enable network boot and Ironic provisioning a patch has been proposed
to dnsmasq. The patch add's the possibility to provide list's of
individual addresses as well as prefixed ranges of ipv6 addresses for a
dhcp-host reservation.

When dnsmasq recieve a request matching the clid or mac address is
recieved the server will iterate over all candidate addresses until it
find's one that is not already leased to a different clid/iaid and
advertise this address.

Using multiple reservations for a single host makes it possible to
maintain a static leases only configuration which support network
booting systems with UEFI firmware that request a new address (a new
SOLICIT with a new IA_NA option using a new IAID) for different boot
modes, for instance 'PXE over IPv6', and 'HTTP-Boot over IPv6'. Open
Virtual Machine Firmware (OVMF) and most UEFI firmware build on the EDK2
code base exhibit this behaviour.

A new configuration syntax is introduces in dnsmasq in patch:
http://lists.thekelleys.org.uk/pipermail/dnsmasq-
discuss/2020q1/013743.html

For example:

 --dhcp-host=52:54:00:3f:5c:c0,[fd12:3456::aa02][fd12:3456::aa04],host1

The above will make the two addresses fd12:3456::aa02 and
fd12:3456::aa04 available to the host with hardware address
52:54:00:3f:5c:c0.


This RFE is to add functionality to the dnsmasq dhcp-agent implementation to write the new configuration format in the dnsmasq hosts file.

Given a neutron port:

    "ports": [
        {
            "dns_assignment": [
               {
                  "hostname": "myport02",
                   "ip_address": "fd12:3456::aa02",
                   "fqdn": "myport02.my-domain.org"
               },
               {
                  "hostname": "myport04",
                   "ip_address": "fd12:3456::aa04",
                   "fqdn": "myport04.my-domain.org"
               },
            ],
            "fixed_ips": [
                {
                    "ip_address": "fd12:3456::aa02",
                    "subnet_id": "008ba151-0b8c-4a67-98b5-0d2b87666062"
                },
                {
                    "ip_address": "fd12:3456::aa04",
                    "subnet_id": "008ba151-0b8c-4a67-98b5-0d2b87666062"
                }

            ],
            "id": "d80b1a3b-4fc1-49f3-952e-1e2ab7081d8b",
            "mac_address": "fa:16:3e:58:42:ed",
            "network_id": "70c1db1f-b701-45bd-96e0-a313ee3430b3",

        },
    ]
}


Current behaviour
-----------------
  dhcp-host=fa:16:3e:58:42:ed,myport02.my-domain.org,[fd12:3456::aa02]
  dhcp-host=fa:16:3e:58:42:ed,myport04.my-domain.org,[fd12:3456::aa04]

  NOTE, this configuration means dnsmasq will only ever lease
fd12:3456::aa04. As it will always find that as the first valid
configuration for mac fa:16:3e:58:42:ed. In other words, the _current
behaviour is broken_.

New behaviour
-------------
  dhcp-host=fa:16:3e:58:42:ed,myport02.my-domain.org,[fd12:3456::aa02][fd12:3456::aa04]

  This will allow dnsmasq to lase both addresses when requests from the
client mac using different IAID's is recieved.

** Affects: neutron
     Importance: Undecided
     Assignee: Harald Jensås (harald-jensas)
         Status: In Progress


** Tags: rfe

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1861032

Title:
  [RFE] Add support for configuring dnsmasq with multiple IPv6 addresses
  in same subnet on same port

Status in neutron:
  In Progress

Bug description:
  To enable network boot and Ironic provisioning a patch has been
  proposed to dnsmasq. The patch add's the possibility to provide list's
  of individual addresses as well as prefixed ranges of ipv6 addresses
  for a dhcp-host reservation.

  When dnsmasq recieve a request matching the clid or mac address is
  recieved the server will iterate over all candidate addresses until it
  find's one that is not already leased to a different clid/iaid and
  advertise this address.

  Using multiple reservations for a single host makes it possible to
  maintain a static leases only configuration which support network
  booting systems with UEFI firmware that request a new address (a new
  SOLICIT with a new IA_NA option using a new IAID) for different boot
  modes, for instance 'PXE over IPv6', and 'HTTP-Boot over IPv6'. Open
  Virtual Machine Firmware (OVMF) and most UEFI firmware build on the
  EDK2 code base exhibit this behaviour.

  A new configuration syntax is introduces in dnsmasq in patch:
  http://lists.thekelleys.org.uk/pipermail/dnsmasq-
  discuss/2020q1/013743.html

  For example:

   --dhcp-
  host=52:54:00:3f:5c:c0,[fd12:3456::aa02][fd12:3456::aa04],host1

  The above will make the two addresses fd12:3456::aa02 and
  fd12:3456::aa04 available to the host with hardware address
  52:54:00:3f:5c:c0.

  
  This RFE is to add functionality to the dnsmasq dhcp-agent implementation to write the new configuration format in the dnsmasq hosts file.

  Given a neutron port:

      "ports": [
          {
              "dns_assignment": [
                 {
                    "hostname": "myport02",
                     "ip_address": "fd12:3456::aa02",
                     "fqdn": "myport02.my-domain.org"
                 },
                 {
                    "hostname": "myport04",
                     "ip_address": "fd12:3456::aa04",
                     "fqdn": "myport04.my-domain.org"
                 },
              ],
              "fixed_ips": [
                  {
                      "ip_address": "fd12:3456::aa02",
                      "subnet_id": "008ba151-0b8c-4a67-98b5-0d2b87666062"
                  },
                  {
                      "ip_address": "fd12:3456::aa04",
                      "subnet_id": "008ba151-0b8c-4a67-98b5-0d2b87666062"
                  }

              ],
              "id": "d80b1a3b-4fc1-49f3-952e-1e2ab7081d8b",
              "mac_address": "fa:16:3e:58:42:ed",
              "network_id": "70c1db1f-b701-45bd-96e0-a313ee3430b3",

          },
      ]
  }

  
  Current behaviour
  -----------------
    dhcp-host=fa:16:3e:58:42:ed,myport02.my-domain.org,[fd12:3456::aa02]
    dhcp-host=fa:16:3e:58:42:ed,myport04.my-domain.org,[fd12:3456::aa04]

    NOTE, this configuration means dnsmasq will only ever lease
  fd12:3456::aa04. As it will always find that as the first valid
  configuration for mac fa:16:3e:58:42:ed. In other words, the _current
  behaviour is broken_.

  New behaviour
  -------------
    dhcp-host=fa:16:3e:58:42:ed,myport02.my-domain.org,[fd12:3456::aa02][fd12:3456::aa04]

    This will allow dnsmasq to lase both addresses when requests from
  the client mac using different IAID's is recieved.

To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1861032/+subscriptions


Follow ups