ipv6 workaround for Unifi USG on 2 Degrees UFB

I had an issue where our USG Pro was not getting ipv6 from 2 Degrees UFB after upgrading our Controller to 5.8. After a lot of messing around with this, I found a workaround originally posted here: https://community.ubnt.com/t5/UniFi-Routing-Switching/USG-DHCPv6-PD-bug-when-using-PPPoE/td-p/2487710.

Digging into the dhcpv6-pd logs shows this:

Dumping out the config I saw that I had two dhcpv6-pd blocks, one under interface eth2 vif 10 and the other under interface eth2 vif 10 pppoe 2 (where it should be):

It was possible to temporarily fix this issue by removing the first block:

This allowed our USG to get ipv6 from our ISP and now all the clients on the network also got ipv6.

To make this more permanent I had to add this file on the USG under /config/scripts/post-config.d/dhcp.sh

To run this script, I added the following on the Controller in /usr/lib/unifi/data/sites/default/config.gateway.json:

This runs the dhcp.sh script 2 minutes after provisioning and then the script removes the scheduled task (as it only needs to run once).

Leave a Reply

Your email address will not be published. Required fields are marked *