[Kea-users] Need help assigning subnets by class with host reservations

MRob mrobti at insiberia.net
Tue Nov 15 15:54:50 UTC 2016


On 2016-11-15 04:51, Thomas Markwalder wrote:
> On 11/15/16 7:41 AM, Thomas Markwalder wrote:
> 
> Sorry, it would need to be at least this:
> 
> diff --git a/src/lib/dhcpsrv/alloc_engine.cc
> b/src/lib/dhcpsrv/alloc_engine.cc
> index bc37eeb..0a5e446 100644
> --- a/src/lib/dhcpsrv/alloc_engine.cc
> +++ b/src/lib/dhcpsrv/alloc_engine.cc
> @@ -2841,6 +2841,11 @@
> AllocEngine::allocateUnreservedLease4(ClientContext4& ctx) {
>              new_lease = allocateOrReuseLease4(candidate, ctx);
>              if (new_lease) {
>                  return (new_lease);
> +            } else {
> +                if (ctx.callout_handle_ &&

You need to remove the opening brace on the next line (or add a closing 
one).

> +                    ctx.callout_handle_->getStatus() ==
> CalloutHandle::NEXT_STEP_SKIP) {
> +                    break;
> +                }
>              }
>          }
>      }

Initial testing shows this seems to fix the problem. Thank you for the 
quick patch.



More information about the Kea-users mailing list