Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • Kea Kea
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 563
    • Issues 563
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 69
    • Merge requests 69
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source ProjectsISC Open Source Projects
  • KeaKea
  • Issues
  • #1683
Closed
Open
Issue created Jan 28, 2021 by Wlodzimierz Wencel@wlodekMaintainer

kea is not accepting custom spaces in option definitions in class

options in kea can be defined in kea standard space dhcp4 and dhcp6 or custom spaces e.g.:

"option-def": [
  {
    "array": false,
    "code": 242,
    "encapsulate": "",
    "name": "dls",
    "record-types": "",
    "space": "XYZ",
    "type": "string"
  }
],

But Kea accept custom spaces only on global level, returns error with this configuration:

client-classes": [
    {
        "option-def": [
            {
                "encapsulate": "339", 
                "code": 43, 
                "type": "empty", 
                "name": "vendor-encapsulated-options"
            }, 
            {
                "code": 2, 
                "name": "vlanid", 
                "space": "339", 
                "type": "uint32", 
                "record-types": "", 
                "array": false, 
                "encapsulate": ""
            }, 
            {
                "code": 3, 
                "name": "dls", 
                "space": "339", 
                "type": "string", 
                "record-types": "", 
                "array": false, 
                "encapsulate": ""
            }
        ], 
        "name": "VENDOR_CLASS_339", 
        "option-data": [
            {
                "name": "vendor-encapsulated-options"
            }, 
            {
                "always-send": true, 
                "data": "123", 
                "name": "vlanid", 
                "space": "339"
            }, 
            {
                "always-send": true, 
                "data": "sdlp://192.0.2.11:18443", 
                "name": "dls", 
                "space": "339"
            }
        ]
    }
], 

Error:

2021-01-28 07:16:28.281 INFO  [kea-dhcp4.dhcp4/27394.140192072867456] DHCP4_STARTING Kea DHCPv4 server version 1.9.4-git (development) starting
2021-01-28 07:16:28.282 WARN  [kea-dhcp4.dhcp4/27394.140192072867456] DHCP4_DEVELOPMENT_VERSION This software is a development branch of Kea. It is not recommended for production use.
2021-01-28 07:16:28.283 ERROR [kea-dhcp4.dhcp4/27394.140192072867456] DHCP4_CONFIG_LOAD_FAIL configuration error using file: /home/wlodek/installed/git/etc/kea/kea-dhcp4.conf, reason: Not allowed option definition for code '2' in space '339' at (/home/wlodek/installed/git/etc/kea/kea-dhcp4.conf:46:21)
2021-01-28 07:16:28.285 ERROR [kea-dhcp4.dhcp4/27394.140192072867456] DHCP4_INIT_FAIL failed to initialize Kea server: configuration error using file '/home/wlodek/installed/git/etc/kea/kea-dhcp4.conf': Not allowed option definition for code '2' in space '339' at (/home/wlodek/installed/git/etc/kea/kea-dhcp4.conf:46:21)

Making impossible to have multiple suboptions code 2 for different classes. full config attached kea-dhcp4.conf

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking