[Kea-users] a few questions from a Kea newbie

Darren Ankney darren.ankney at gmail.com
Tue Nov 14 11:24:02 UTC 2023


Hello,

Some clarification about #2.  It is possible, but not if another
client currently has an active lease.  Kea will refuse to assign the
IP to what is essentially a new client while an existing client still
holds a lease on the IP address.  The reason this behavior has changed
is due to a change in the address reservation mechanism.  ISC DHCP,
when 'fixed-address' was used, did not record a lease for the leased
address.  It was then free to assign the IP address to whatever host
matched the reservation.  This had the side effect of it being
possible to have multiple clients with the same IP address if they all
matched reservations.  In Kea, a lease is created for all assignments.
An IP cannot be assigned to a new client if there is already a lease
for another client (which makes complete sense).  To work around this,
you can use the API to delete a lease
(https://kea.readthedocs.io/en/kea-2.4.0/arm/hooks.html#the-lease4-del-lease6-del-commands)
if desired.  Do be careful that the client has actually gone before
deleting the lease, however, or you could wind up with multiple
clients leased the same IP address.

Thank you,

Darren Ankney

On Mon, Nov 13, 2023 at 8:08 PM Kevin P. Fleming
<lists.kea-users at kevin.km6g.us> wrote:
>
> 1) No, it is not necessary to use a database in order to use reservations.
>
> 2) Unfortunately this is not currently possible unless you can ensure that the host releases its lease before switching interfaces. I have discussed this in a number of threads on this list and there is an open issue for it.
>
> 3) Yes you can have multiple reservations for the same hardware address.
>
> On Mon, Nov 13, 2023, at 16:50, Jason Keltz wrote:
> > Hi.
> >
> > I'm investigating migrating from ISC DHCPd to Kea and running into a few
> > issues.
> >
> > I see some conflicting information online, due to kea development over
> > time, so I was hoping to ask here for some clarification.
> >
> > 1) Is it really necessary to install a database backend such as
> > Postgres/MySQL if I want to have static host reservations?  This was
> > working so perfectly with dhcpd without any db backend for such a long
> > time.  Not having a DB backend on the DHCP server means one less thing
> > to worry about when Kea is updated, or the DB updated.   I accept that
> > performance of the DB is likely going to be better than the reservations
> > being stored in a text file, but for my basic setup, it just doesn't
> > matter to me. The simplicity of not needing a DB for this over-rides the
> > performance gain that may be attained with a DB.  I just want to be sure
> > that I haven't overlooked something.
> >
> > 2) Does Kea permit multiple ethernet addresses mapped to the same IPv4
> > IP?  I do this for multiple reasons - for example, I may have a server
> > that has 2 ethernet addresses, and when I plug it in, whether I use one
> > or the other network port, the IP should be the same.  Obviously I
> > shouldn't plug in both or things would break, but that would be my
> > problem.  At the same time, maybe a laptop has an ethernet port built
> > in, but when plugged into a dock that has its own network port, I want
> > the machine to get the same IP one way or the other (static
> > reservation).  Now, I think I can permit this by enabling
> > "ip-reservations-unique" to false, but I wanted to clarify.  Again, I
> > did this with DHCPd all the time.
> >
> > 3) Finally - does Kea permit multiple IPv4 IPs for the same ethernet
> > address?  I believe that "ip-reservations-unique" does not permit this,
> > yet this is more important for me, and I did this with dhcpd.  For
> > example, in different places in the building there are different VLANs.
> > Most hosts just get a static IP reservation from DHCP.  99% of hosts
> > will ever be on one VLAN. However, for say, my test laptop that has a
> > single IP reserved on every VLAN - can Kea handle this scenario?
> >
> > Answers to these questions would be a great start!
> >
> > Thanks for reading..
> >
> > Jason.
> >
> > --
> > 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 at 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 at lists.isc.org
> https://lists.isc.org/mailman/listinfo/kea-users


More information about the Kea-users mailing list