on release {} and DHCPv6

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

on release {} and DHCPv6

perl-list
Folks,

I am testing what custom logs can be created with DHCPv6.  I have this in my config file:


on release {
        log(info,"THIS IS A RELEASE!");
        if exists dhcp6.ia-na {
                log(info,
                        concat( "RELEASED,",
                                "IP,",binary-to-ascii(16, 16, ":", substring(option dhcp6.ia-na,16,16))
                        )
                );
        }
        if exists dhcp6.client-id {
                log(info,
                        concat( "RELEASED,",
                                "DUID,",binary-to-ascii(16, 8, ":", option dhcp6.client-id)
                        )
                );
        }
}


According to a packet capture, both ia-na (option 3) and client-id (option 1) are present.  These options appear to have exactly the same content as they do during a Request.  

However, in the log, all that is printed is "THIS IS A RELEASE!".

These same sorts of log messages work fine in on commit {}  

Anyone have any idea why these options aren't available during a release?  Is there some secret sauce that I am missing here to decode these options during a release? 

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users
Reply | Threaded
Open this post in threaded view
|

Re: on release {} and DHCPv6

perl-list
Anyone have any idea on accessing DHCPv6 options in the "on release {}" block?



From: "Darren Ankney" <[hidden email]>
To: [hidden email]
Sent: Tuesday, November 22, 2016 10:07:39 AM
Subject: on release {} and DHCPv6
Folks,

I am testing what custom logs can be created with DHCPv6.  I have this in my config file:


on release {
        log(info,"THIS IS A RELEASE!");
        if exists dhcp6.ia-na {
                log(info,
                        concat( "RELEASED,",
                                "IP,",binary-to-ascii(16, 16, ":", substring(option dhcp6.ia-na,16,16))
                        )
                );
        }
        if exists dhcp6.client-id {
                log(info,
                        concat( "RELEASED,",
                                "DUID,",binary-to-ascii(16, 8, ":", option dhcp6.client-id)
                        )
                );
        }
}


According to a packet capture, both ia-na (option 3) and client-id (option 1) are present.  These options appear to have exactly the same content as they do during a Request.  

However, in the log, all that is printed is "THIS IS A RELEASE!".

These same sorts of log messages work fine in on commit {}  

Anyone have any idea why these options aren't available during a release?  Is there some secret sauce that I am missing here to decode these options during a release? 

_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users


_______________________________________________
dhcp-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/dhcp-users