# Kea 1.7.2, November 27th 2019, Release Notes Welcome to Kea 1.7.2, a third monthly development release of Kea. This release is the next step towards having fully multi-threaded DHCP servers, which will eventually become available as 1.8.0. This is a development release. Use with caution! Development releases are not recommended for production use. Changes introduced in this version: 1. **Multi-threading**. One of the major building blocks of the multi-threaded solution has been implemented. We now have a thread pool, which is a mechanism for managing pools. Current Kea DHCPv4 and DHCPv6 daemons each have a single-threaded process that does all tasks sequentially. The upcoming Kea 1.8.0 will have many threads processing multiple packets and possibly performing other tasks in parallel. This code adds the management mechanism to govern threads. It is not used yet by the code, but it is an essential milestone that the upcoming work will be based on. The first part of the code that has been updated to the new threading model is MySQL connection handling. Instead of having one connection shared by all threads, there is now a connection pool that will eventually allow each thread to use a separate connection. Another element is generic support for a critical section. NOTE: The multi-threading solution is not usable yet. (#883, #960, #970). 2. **Default CA port change**. There were some inconsistencies between various Kea elements (the default value for the CA itself, the kea-shell, the example configs, and the ARM) regarding the TCP port the Control Agent (CA) listens on. The default port is now 8000; it can be configured to other values if needed (#793). 3. **perfdhcp improvements**. Perfdhcp, our DHCP performance testing tool, is focused on performance and has always had a very simplified logic regarding validating response correctness. It used to count any responses as valid, even those that did not assign any address. This deficiency has been resolved. We intend to use this new capability for multi-threaded experiments, but it is a general improvement that can be helpful in any performance test (#572). 4. **New hook points: cb4_updated and cb6_updated**. Two new hook points called cb4_updated and cb6_updated have been defined. They are called every time a configuration update is retrieved from the config backend (CB). This allows ISC and other developers to implement additional mechanisms on top of the CB (#596). 5. **Improved support for backup servers in HA configuration**. Kea 1.4.0 introduced High Availability mode with an optional capability to send lease updates to a third backup server. It was recently discovered that under special circumstances (initial traffic being serviced by the primary server, followed by more than 30 seconds of inactivity), the backup server could close the connection. The primary server would enter a "confused" state where it believed there was data to be received from the backup server, but the connection was broken. In effect, the primary server would enter a busy loop, resulting in 100% CPU utilization and general unresponsiveness to DHCP traffic and API commands. This bug has been fixed. This problem affects only users who use HA configuration with an additional backup server and periods of inactivity. (#964). ## Changes to Release Model The Kea project has been in development for several years now, and it has a significant production deployment base with users who are looking for stability, rather than a constant stream of new "bleeding-edge" features. At the same time, we want to continue developing the software, including some new powerful, but difficult-to-implement, features. As a result, we decided to change the release cycle. Starting from 1.6.0, there are two series of releases: stable and development. Stable releases are what you would expect: stable, released infrequently, without new features or significant changes, very well-tested. Those can be identified by the middle version number being even. The current stable release is 1.6.0. If we discover important bugs that require fixing, we may release 1.6.1, but that will be determined on a case-by-case basis. The next major stable version will be 1.8.0, followed by 2.0.0 in the future. Our team continues development of new features. In particular, we're tackling the difficult problem of being able to use all available CPU cores simultaneously. The multi-threading implementation is a complex task and it is unknown how long it will take before the solution is stable and ready for production environment. At the same time, we continue to receive a stream of requests for small features and bug fixes. We don't want to force users to wait half a year or more for the fixes and features that are already done. Therefore, we have decided to start issuing development releases on a monthly basis. Those are slightly less well-tested and may have features that are not complete; a good example may be multi-threading. It is possible that one of the next releases will provide a configuration knob to specify the number of threads, but the actual code won't be extended yet to spawn those threads. The development releases can be easily identified by the middle version number being odd: for example, 1.7.2 is a development release. In December 2019 we will release 1.7.3, the next development version. Once 1.8.0 is out, we will continue our development work with 1.9.0, then 1.9.1, and so on. Our goal is to make the development release available on the last Wednesday of each month. There may be exceptions (such as during holidays), but that's the general plan. We encourage users to test the development releases and report back their findings. For more details on the plan, see ISC's Software Support Policy at https://kb.isc.org/v1/docs/aa-00896. ## Kea overview Kea is a DHCP implementation developed by Internet Systems Consortium, Inc. that features fully functional DHCPv4 and DHCPv6 servers, a dynamic DNS update daemon, a Control Agent (CA) that provides a REST API to control the DHCP and DNS update servers, an example shell client to connect to the CA, a daemon that is able to retrieve YANG configuration and updates from Sysrepo, and a DHCP performance-measurement tool. Both DHCP servers fully support server discovery, address assignment, renewal, rebinding, release, decline, information request, DNS updates, client classification, and host reservations. The DHCPv6 server also supports prefix delegation. Lease information is stored in a CSV file by default; it can optionally be stored in a MySQL, PostgreSQL, or Cassandra database instead. Host reservations can be stored in a configuration file, or in a MySQL, PostgreSQL, or Cassandra database. They can also be retrieved from a RADIUS server, although this functionality is somewhat limited. Kea DHCPv4 and DHCPv6 daemons provide support for YANG models, which are stored in a Sysrepo datastore and can be configured via the NETCONF protocol. This text references issue numbers. For more details, visit the Kea GitLab page at https://gitlab.isc.org/isc-projects/kea/issues. ## License This version of Kea is released under the Mozilla Public License, version 2.0. https://www.mozilla.org/en-US/MPL/2.0 The premium and subscriber-only hook libraries are provided in source code form, under the terms of an End User License Agreement (you will get the source code that you can modify freely, but you are not permitted to redistribute it). ## Download Pre-built ISC packages for current versions of the most popular Linux operating systems are available at: https://cloudsmith.io/~isc/repos/ The Kea source and PGP signature for this release may be downloaded from: https://www.isc.org/downloads The signature was generated with the ISC code signing key which is available at: https://www.isc.org/pgpkeys ISC provides detailed documentation, including installation instructions and usage tutorials, in the Kea Administrator Reference Manual. Documentation is included with the installation or via https://kb.isc.org/docs/kea-administrator-reference-manual in HTML, plain text, or PDF formats. ISC maintains a public open source code tree, wiki, issue tracking system, milestone planning, and a roadmap at https://gitlab.isc.org//isc-projects/kea. Limitations and known issues with this release can be found at https://gitlab.isc.org/isc-projects/kea/wikis/known-issues-list. We ask users of this software to please let us know how it worked for you and what operating system you tested on. Feel free to share your feedback on the Kea Users mailing list (https://lists.isc.org/mailman/listinfo/kea-users). Also we would like to hear whether the documentation is adequate and accurate. Please open tickets in the Kea GitLab project for bugs, documentation omissions and errors, and enhancement requests. We want to hear from you even if everything worked. ## Support Professional support for Kea is available from ISC. We encourage all professional users to consider this option; Kea development and maintenance are funded with support subscriptions. For more information on ISC's Kea and DHCP software support see https://www.isc.org/support/. Free best-effort support is provided by our user community via a mailing list. Information on all public email lists is available at https://www.isc.org/community/mailing-list. If you have any comments or questions about working with Kea, please share them to the Kea Users List (https://lists.isc.org/mailman/listinfo/kea-users). Bugs and feature requests may be submitted via GitLab at https://gitlab.isc.org/isc-projects/kea/issues. ## Changes The following summarizes changes and important upgrade notes since the previous release (1.7.1). 1686. [func] razvan Added a generic ThreadPool class which can be used to process functor work items in parallel, on multiple threads. It uses a queue container to manage the work items. (Gitlab #883) 1685. [build] fdupont Small build improvement. The fcntl.h header is included in more portable way. This should make it easier to build on Alpine systems and possibly other systems. (Gitlab #765) 1684. [func] fdupont As a preparation for upcoming multi-threading, the MySQL connection pool has been implemented. This code is not usable on its own yet, but it will allow all threads to have share a pool of connections in the future. This should improve the overall MySQL lease backend performance. (Gitlab #960) 1683. [bug] wlodek Perfdhcp is able to parse incoming packet and determine if included IA_NA/IA_PD options are correct, counter of rejected leases is introduced for all DHCP v6 message exchanges. Perfdhcp will no longer send Request/Renew/Release message without proper IA_NA/IA_PD included. (Gitlab #572) 1682. [bug]* tmark Added logic to core code and HA hook lib to allow HA peers to detect and handle out of bandwidth socket events. This corrects a defect introduced in Kea 1.6.0 that can cause an HA server to become unresponsive when an HA socket has been closed by a peer. Note that there is a change to the signature of the external socket callback handler invoked by IfaceMgr. Custom hook libraries happen register external sockets with IfaceMgr will require modification and recompilation. (Gitlab #964) Thank you again to everyone who assisted us in making this release possible. We look forward to receiving your feedback.