[Kea-users] free text parameter under each subnet

Thomas Markwalder tmark at isc.org
Fri Aug 18 17:19:31 UTC 2017


Hello Itay:

"user-context" is per pool not per subnet.   Our admin guide example is
incorrect.  Try this:

"pools": [ {
                "pool": "10.0.0.10 -  10.0.0.99",
*                "user-context": { "color": "red" }*
               } ] ,
*                     
*
Meanwhile, I'll create a ticket to update the doc.

Thanks,

Thomas

On 8/18/17 11:59 AM, itay cohen wrote:
> actually user-context is perfect for me,
> i tried the example in the admin guide,
>
> but when i use it i get an error:
> ERROR [kea-dhcp4.dhcp4/20619] DHCP4_INIT_FAIL failed to initialize Kea
> server: configuration error using file '/usr/local/etc/kea/kea.conf':
> /usr/local/etc/kea/kea.conf:126.4-17: got unexpected keyword
> "user-context" in subnet4 map.
>
>                 { "subnet": "10.0.0.0/24 <http://10.0.0.0/24>",
>                         "id": 3001,
>                         "pools": [ { "pool": "10.0.0.10 -  10.0.0.99"
> } ] ,
> *                        "user-context": { "color": "red" },*
>                         "relay": { "ip-address": "10.0.0.1" },
>                         "option-data": [ { "name": "routers", "data":
> "10.0.0.1"  } ],
>                         "renew-timer": 200,
>                         "rebind-timer": 400,
>                         "valid-lifetime": 600
>                 },
>
> please advise,
> thank you
>
> On Fri, Aug 18, 2017 at 3:10 PM, Francis Dupont <fdupont at isc.org
> <mailto:fdupont at isc.org>> wrote:
>
>     James Sumners writes:
>     > Unfortunately the parser doesn't ignore unknown properties.
>
>     => not unfortunately: it is by design and I am sure you'd like the
>     parser to catch a trivial spelling error than to silently ignore it.
>
>     Regards
>
>     Francis Dupont <fdupont at isc.org <mailto:fdupont at isc.org>>
>
>     PS: as you expect to add a new subnet property you need to patch the
>     parser. Note in pools you have the user-context property which can
>     be used
>     for the same goal and can be extended (i.e., post a request) to
>     subnets
>     or other syntax elements (only host reservations will be complex
>     because
>     of external host databases).
>
>
>
>
> _______________________________________________
> Kea-users mailing list
> Kea-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/kea-users


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20170818/cb378c87/attachment.htm>


More information about the Kea-users mailing list