Hi,
Thank you for the answer. The addrtotext option is great.
I would like to explain what we need.
We wouldn't like to use an identifier for every host.
1) Because we want to hand out DNS names to VMs with random MAC addresses.
2) We are using /24 and /23 networks. So that even if we would know the MAC-
addresses this would mean a lot of entries in the kea-dhcp*.conf.
It would be great dns names could be handed out for a pool in kea-dhcp*.conf
for a host that doesn't have an identifier. Or an Asterix identifier.
Regards,
Joop.
On Tuesday, January 6, 2026 9:35:04 AM Central European Standard Time Peter
Davies wrote:
> Hi Joop,
> A host reservation should have an identifier. If you do not use the
> "hw-address,"
> what identifier do you use?
>
> You may wish to use the following, which appends the IP address to the
> hostname:
> "hostname-expr" :
> "concat('vm-test-',addrtotext(option[50].hex))" } }
>
> /Peter
>
> On 05/01/2026 16.59, Joop Boonen wrote:
> > Dear all,
> >
> > I'm using the option like this.
> > "Dhcp4": {
> >
> > "hooks-libraries": [
> >
> > {
> >
> > "library": "libdhcp_ddns_tuning.so",
> > "parameters": {
> >
> > "hostname-expr" : "concat('vm-
> >
> > test-',hexstring(option[50].hex,''))"
> >
> > }
> >
> > },
> >
> > I notice when I don't have an hw-address entry
> >
> > {
> >
> > "hw-address": "<hw-addres>",
> > "ip-address": "<ip-address",
> > "hostname": "<hostname>"
> >
> > },
> >
> > The ddns entries doesn't get Updated.
> > For some reason it looks like hostname-expr needs an assigned hostname.
> >
> > Does someone know how this can be solved.
> >
> > Regards,
> >
> > Joop Boonen.
--
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.
[email protected]