Reply
New Member
Posts: 1
Registered: ‎01-14-2018
Kudos: 3

Re: Comcast IPv6 issues when hwnat enabled on ER-X

The very latest firmware released this week still has this problem. With hwnat off, IPv6 works great. Turn it on and no more IPv6. 

 

Comcast in San Francisco, CA.

 

Thankfully I only have a 180 Mb connection so the CPU is able to keep up with things, but I suspect I’ll be on gigabit in the next couple years as fiber is landing quickly around here. I’ll likely move to a different product since it’s absurd to have to pick between IPv6 or gigabit speed.  

 

The lack of of response is disappointing. 

Regular Member
Posts: 524
Registered: ‎09-23-2015
Kudos: 166
Solutions: 3

Re: Comcast IPv6 issues when hwnat enabled on ER-X


wrote:

I've had no PD/IPv6 issues after about a week with hwnat off.

 

This thread will be a year old in 3 weeks. It doesn't seems like this is getting fixed if they haven't figured it out by now.


Time flies, eh? Man Happy

 

@UBNT-sandisn are you able to give us a status update on this issue? I certainly believe UBNT when you guys say you haven't been able to reproduce it in your lab -- because I also haven't been able to reproduce it. But the sheer number of different people impacted by this issue convince me it's legit.

 

You've got users offering you remote access to devices that CAN reliably reproduce the issue. Given the sheer number of Comcast customers out there who could potentially purchase an ER-X, I'm a little surprised that this hasn't been prioritized higher... and that you guys haven't been ALL OVER those offers of visibility into affected devices.

This is where I used to list my UBNT gear, but now it's mostly stuff I'm not allowed to talk about yet. Man Wink
942.22 Mbps down / 926.27 Mbps up (http://result.googlefiber.net/share/316298352.png)
My Blog: http://www.stevejenkins.com/
New Member
Posts: 1
Registered: ‎09-11-2017

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Just another Comcast user of Ubiquiti gear that has plenty of time to help troubleshoot during working hours Pacific time.

-Gene
New Member
Posts: 23
Registered: ‎08-18-2016
Kudos: 3
Solutions: 1

Re: Comcast IPv6 issues when hwnat enabled on ER-X

 

You've got users offering you remote access to devices that CAN reliably reproduce the issue. Given the sheer number of Comcast customers out there who could potentially purchase an ER-X, I'm a little surprised that this hasn't been prioritized higher... and that you guys haven't been ALL OVER those offers of visibility into affected devices.


 

What you are missing here is that UBNT isn't the developer or maintainer of the HWNAT module - the chip vendor is. This is a huge problem for all the manufacturers of embedded devices running linux, not just UBNT. Old kernels, buggy proprietary kernel modules, it's a flipping nightmare

Regular Member
Posts: 524
Registered: ‎09-23-2015
Kudos: 166
Solutions: 3

Re: Comcast IPv6 issues when hwnat enabled on ER-X


wrote:

 

 

 What you are missing here is that UBNT isn't the developer or maintainer of the HWNAT module - the chip vendor is. This is a huge problem for all the manufacturers of embedded devices running linux, not just UBNT. Old kernels, buggy proprietary kernel modules, it's a flipping nightmare


That's a very fair point.

 

Yet still, I'd imagine UBNT would want to track down exactly what's going on with the HWNAT module in their devices so they can either change the chipset in future HW revs, and/or pass the information upstream to the chip vendor, and/or devise a SW solution to help mitigate the issue.

This is where I used to list my UBNT gear, but now it's mostly stuff I'm not allowed to talk about yet. Man Wink
942.22 Mbps down / 926.27 Mbps up (http://result.googlefiber.net/share/316298352.png)
My Blog: http://www.stevejenkins.com/
Ubiquiti Employee
Posts: 481
Registered: ‎01-06-2017
Kudos: 177
Solutions: 20

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Thanks everyone for the input.

 

During each release cycle we revisit this thread and check the new information. Now that we have started working on 2.0 we'll revisit the issue once again.

New Member
Posts: 4
Registered: ‎01-15-2017

Re: Comcast IPv6 issues when hwnat enabled on ER-X

I have an ERX-SFP that has its managment console online.

I am on Comcast and have this problem.

If UBNT needs a router to play with, contact me and I can share credentials.

 

Jon

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

I spent a little while digging into this. Currently the device I'm testing with is on Comcast and hwnat is disabled:

 

 

ubnt@panic:~$ show configuration commands | grep -i -e duid -e hwnat
set interfaces ethernet eth0 dhcpv6-pd duid '00:01:00:01:20:a1:65:da:04:18:d6:06:61:0a'
set system offload hwnat disable

 

 

I've narrowed things down a bit to being (at least in my case) due to the script /opt/vyatta/sbin/dhcpv6-pd-duid.pl.

 

When starting from a place where IPv6 is working.... Low and behold the binary file in which the DUID is parseable:

 

 

 

ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show
DUID 00:01:00:01:22:2a:5f:60:04:18:d6:06:61:0a

 

This is the command run behind the scenes via

show dhcpv6-pd duid
/opt/vyatta/share/vyatta-op/templates/show/dhcpv6-pd/duid/node.def 

 

Then, I try to regenerate the config:

 

ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=delete
ubnt@panic:~$ sudo  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=set --duid='00:01:00:01:20:a1:65:da:04:18:d6:06:61:0a' --intf=eth0
ubnt@panic:~$ 
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show  
DUID 00:01:00:01:20:a1:65:da:04:18:d6:06:61:0a::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

Then, I tried to back up and see if it was due to "setting" rather than "generating" a DUID:

 

ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=delete
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=gen --intf=eth0
Error opening [/var/lib/dhcpv6/dhcp6c_duid]: Permission denied
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=delete
No DUID found
ubnt@panic:~$ sudo  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=gen --intf=eth0
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show  
DUID 00:01:01:5a:97:aa:c6:04:18:d6:06:61:05:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

From reading the source of that utility, it seems that there is a problem with packing the file.  I can see in the "show_did" function call that there are checks being done for endianess, while in the set and gen functions there are not.  In trying to find the "upstream" (which seems to be UBNT internal) it lead me in a circle to here:  https://phabricator.vyos.net/T421

 

Hope this helps others in digging through this.

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Also, continuing with more manual steps, I've confirmed that I can corrupt my DUID file in a consistent manner (and regenerate it):

 

 

ubnt@panic:~$ sudo /usr/sbin/dhcp6c -dDf -c /var/run/dhcp6c-eth0-pd.conf -p /var/run/dhcp6c-eth0-pd.pid eth0
Mar/01/2018 07:32:17: gethwid: found an interface switch0 for DUID
Mar/01/2018 07:32:17: get_duid: generated a new DUID: 00:01:00:01:22:2a:69:01:04:18:d6:06:61:0a
Mar/01/2018 07:32:17: get_duid: saved generated DUID to /var/lib/dhcpv6/dhcp6c_duid
Mar/01/2018 07:32:17: cfdebug_print: <3>comment [# This file was auto-generated by /opt/vyatta/sbin/dhcpv6-pd-client.pl] (70)
Mar/01/2018 07:32:17: cfdebug_print: <3>comment [# configuration sub-system.  Do not edit it.] (44)
Mar/01/2018 07:32:17: cfdebug_print: <3>[interface] (9)
Mar/01/2018 07:32:17: cfdebug_print: <5>[eth0] (4)
Mar/01/2018 07:32:17: cfdebug_print: <3>begin of closure [{] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:32:17: cfdebug_print: <3>[ia-na] (5)
Mar/01/2018 07:32:17: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[request] (7)
Mar/01/2018 07:32:17: cfdebug_print: <3>[domain-name-servers] (19)
Mar/01/2018 07:32:17: cfdebug_print: <3>[,] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[domain-name] (11)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:32:17: cfdebug_print: <3>[rapid-commit] (12)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:32:17: cfdebug_print: <3>[ia-pd] (5)
Mar/01/2018 07:32:17: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[script] (6)
Mar/01/2018 07:32:17: cfdebug_print: <3>["/opt/vyatta/sbin/ubnt-dhcp6c-script"] (37)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[id-assoc] (8)
Mar/01/2018 07:32:17: cfdebug_print: <15>[na] (2)
Mar/01/2018 07:32:17: cfdebug_print: <15>[0] (1)
Mar/01/2018 07:32:17: cfdebug_print: <15>begin of closure [{] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[id-assoc] (8)
Mar/01/2018 07:32:17: cfdebug_print: <15>[pd] (2)
Mar/01/2018 07:32:17: cfdebug_print: <15>[0] (1)
Mar/01/2018 07:32:17: cfdebug_print: <15>begin of closure [{] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[prefix] (6)
Mar/01/2018 07:32:17: cfdebug_print: <3>[::] (2)
Mar/01/2018 07:32:17: cfdebug_print: <3>[/] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[60] (2)
Mar/01/2018 07:32:17: cfdebug_print: <3>[infinity] (8)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[prefix-interface] (16)
Mar/01/2018 07:32:17: cfdebug_print: <5>[switch0] (7)
Mar/01/2018 07:32:17: cfdebug_print: <3>begin of closure [{] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[sla-id] (6)
Mar/01/2018 07:32:17: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[sla-len] (7)
Mar/01/2018 07:32:17: cfdebug_print: <3>[4] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>[ifid] (4)
Mar/01/2018 07:32:17: cfdebug_print: <3>[1] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:32:17: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:32:17: configure_pool: called
Mar/01/2018 07:32:17: clear_poolconf: called
Mar/01/2018 07:32:17: dhcp6_reset_timer: reset a timer on eth0, state=INIT, timeo=0, retrans=791
Mar/01/2018 07:32:18: client6_send: a new XID (15b936) is generated
Mar/01/2018 07:32:18: copy_option: set client ID (len 14)
Mar/01/2018 07:32:18: copyout_option: set identity association
Mar/01/2018 07:32:18: copy_option: set rapid commit (len 0)
Mar/01/2018 07:32:18: copy_option: set elapsed time (len 2)
Mar/01/2018 07:32:18: copy_option: set option request (len 4)
Mar/01/2018 07:32:18: copyout_option: set IA_PD prefix
Mar/01/2018 07:32:18: copyout_option: set IA_PD
Mar/01/2018 07:32:18: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:32:18: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=0, retrans=1090
Mar/01/2018 07:32:19: copy_option: set client ID (len 14)
Mar/01/2018 07:32:19: copyout_option: set identity association
Mar/01/2018 07:32:19: copy_option: set rapid commit (len 0)
Mar/01/2018 07:32:19: copy_option: set elapsed time (len 2)
Mar/01/2018 07:32:19: copy_option: set option request (len 4)
Mar/01/2018 07:32:19: copyout_option: set IA_PD prefix
Mar/01/2018 07:32:19: copyout_option: set IA_PD
Mar/01/2018 07:32:19: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:32:19: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=1, retrans=2167
Mar/01/2018 07:32:21: copy_option: set client ID (len 14)
Mar/01/2018 07:32:21: copyout_option: set identity association
Mar/01/2018 07:32:21: copy_option: set rapid commit (len 0)
Mar/01/2018 07:32:21: copy_option: set elapsed time (len 2)
Mar/01/2018 07:32:21: copy_option: set option request (len 4)
Mar/01/2018 07:32:21: copyout_option: set IA_PD prefix
Mar/01/2018 07:32:21: copyout_option: set IA_PD
Mar/01/2018 07:32:21: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:32:21: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=2, retrans=4400
Mar/01/2018 07:32:21: client6_recv: receive advertise from fe80::201:5cff:fe6d:9c46%eth0 on eth0
Mar/01/2018 07:32:21: dhcp6_get_options: get DHCP option client ID, len 14
Mar/01/2018 07:32:21:   DUID: 00:01:00:01:22:2a:69:01:04:18:d6:06:61:0a
Mar/01/2018 07:32:21: dhcp6_get_options: get DHCP option server ID, len 14
Mar/01/2018 07:32:21:   DUID: 00:01:00:01:1c:e3:7b:f8:40:a8:f0:2e:87:34
Mar/01/2018 07:32:21: dhcp6_get_options: get DHCP option identity association, len 40
Mar/01/2018 07:32:21:   IA_NA: ID=0, T1=1800, T2=2880
Mar/01/2018 07:32:21: copyin_option: get DHCP option IA address, len 24
Mar/01/2018 07:32:21: copyin_option:   IA_NA address: 2001:558:6045:61:1cf6:78a8:eb23:b4d8 pltime=3600 vltime=3600
Mar/01/2018 07:32:21: dhcp6_get_options: get DHCP option IA_PD, len 41
Mar/01/2018 07:32:21:   IA_PD: ID=0, T1=1800, T2=2880
Mar/01/2018 07:32:21: copyin_option: get DHCP option IA_PD prefix, len 25
Mar/01/2018 07:32:21: copyin_option:   IA_PD prefix: 2601:643:8400:67f0::/60 pltime=3600 vltime=3600
Mar/01/2018 07:32:21: dhcp6_get_options: get DHCP option DNS, len 32
Mar/01/2018 07:32:21: client6_recvadvert: server ID: 00:01:00:01:1c:e3:7b:f8:40:a8:f0:2e:87:34, pref=-1
Mar/01/2018 07:32:21: client6_recvadvert: unexpected advertise
Mar/01/2018 07:32:21: client6_recvadvert: reset timer for eth0 to 0.968155
Mar/01/2018 07:32:22: select_server: picked a server (ID: 00:01:00:01:1c:e3:7b:f8:40:a8:f0:2e:87:34)
Mar/01/2018 07:32:22: client6_send: a new XID (500224) is generated
Mar/01/2018 07:32:22: copy_option: set client ID (len 14)
Mar/01/2018 07:32:22: copy_option: set server ID (len 14)
Mar/01/2018 07:32:22: copyout_option: set IA address
Mar/01/2018 07:32:22: copyout_option: set identity association
Mar/01/2018 07:32:22: copy_option: set elapsed time (len 2)
Mar/01/2018 07:32:22: copy_option: set option request (len 4)
Mar/01/2018 07:32:22: copyout_option: set IA_PD prefix
Mar/01/2018 07:32:22: copyout_option: set IA_PD
Mar/01/2018 07:32:22: client6_send: send request to ff02::1:2%eth0
Mar/01/2018 07:32:22: dhcp6_reset_timer: reset a timer on eth0, state=REQUEST, timeo=0, retrans=1017
Mar/01/2018 07:32:22: client6_recv: receive reply from fe80::201:5cff:fe6d:9c46%eth0 on eth0
Mar/01/2018 07:32:22: dhcp6_get_options: get DHCP option client ID, len 14
Mar/01/2018 07:32:22:   DUID: 00:01:00:01:22:2a:69:01:04:18:d6:06:61:0a
Mar/01/2018 07:32:22: dhcp6_get_options: get DHCP option server ID, len 14
Mar/01/2018 07:32:22:   DUID: 00:01:00:01:1c:e3:7b:f8:40:a8:f0:2e:87:34
Mar/01/2018 07:32:22: dhcp6_get_options: get DHCP option identity association, len 40
Mar/01/2018 07:32:22:   IA_NA: ID=0, T1=1800, T2=2880
Mar/01/2018 07:32:22: copyin_option: get DHCP option IA address, len 24
Mar/01/2018 07:32:22: copyin_option:   IA_NA address: 2001:558:6045:61:1cf6:78a8:eb23:b4d8 pltime=3600 vltime=3600
Mar/01/2018 07:32:22: dhcp6_get_options: get DHCP option IA_PD, len 41
Mar/01/2018 07:32:22:   IA_PD: ID=0, T1=1800, T2=2880
Mar/01/2018 07:32:22: copyin_option: get DHCP option IA_PD prefix, len 25
Mar/01/2018 07:32:22: copyin_option:   IA_PD prefix: 2601:643:8400:67f0::/60 pltime=3600 vltime=3600
Mar/01/2018 07:32:22: dhcp6_get_options: get DHCP option DNS, len 32
Mar/01/2018 07:32:22: info_printf: nameserver[0] 2001:558:feed::1
Mar/01/2018 07:32:22: info_printf: nameserver[1] 2001:558:feed::2
Mar/01/2018 07:32:22: get_ia: make an IA: PD-0
Mar/01/2018 07:32:22: update_prefix: create a prefix 2601:643:8400:67f0::/60 pltime=3600, vltime=3600
Mar/01/2018 07:32:22: ifaddrconf: add an address 2601:643:8400:67f0::1/64 on switch0
Mar/01/2018 07:32:22: get_ia: make an IA: NA-0
Mar/01/2018 07:32:22: update_address: create an address 2001:558:6045:61:1cf6:78a8:eb23:b4d8 pltime=3600, vltime=3600
Mar/01/2018 07:32:22: ifaddrconf: add an address 2001:558:6045:61:1cf6:78a8:eb23:b4d8/128 on eth0
Mar/01/2018 07:32:22: dhcp6_remove_event: removing an event on eth0, state=REQUEST
Mar/01/2018 07:32:22: dhcp6_remove_event: removing server (ID: 00:01:00:01:1c:e3:7b:f8:40:a8:f0:2e:87:34)
Mar/01/2018 07:32:22: client6_recvreply: executes /opt/vyatta/sbin/ubnt-dhcp6c-script
Mar/01/2018 07:32:25: client6_script: script "/opt/vyatta/sbin/ubnt-dhcp6c-script" terminated
Mar/01/2018 07:32:25: client6_recvreply: got an expected reply, sleeping.



^C
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show
DUID 00:01:00:01:22:2a:69:01:04:18:d6:06:61:0a
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=delete
ubnt@panic:~$ sudo  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=gen --intf=eth0
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show
DUID 00:01:01:5a:97:ac:e3:04:18:d6:06:61:05:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
ubnt@panic:~$  
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=delete
ubnt@panic:~$  /opt/vyatta/sbin/dhcpv6-pd-duid.pl --action=show  
No DUID found
ubnt@panic:~$  
ubnt@panic:~$  
ubnt@panic:~$ sudo /usr/sbin/dhcp6c -dDf -c /var/run/dhcp6c-eth0-pd.conf -p /var/run/dhcp6c-eth0-pd.pid eth0
Mar/01/2018 07:34:29: gethwid: found an interface switch0 for DUID
Mar/01/2018 07:34:29: get_duid: generated a new DUID: 00:01:00:01:22:2a:69:85:04:18:d6:06:61:0a
Mar/01/2018 07:34:29: get_duid: saved generated DUID to /var/lib/dhcpv6/dhcp6c_duid
Mar/01/2018 07:34:29: cfdebug_print: <3>comment [# This file was auto-generated by /opt/vyatta/sbin/dhcpv6-pd-client.pl] (70)
Mar/01/2018 07:34:29: cfdebug_print: <3>comment [# configuration sub-system.  Do not edit it.] (44)
Mar/01/2018 07:34:29: cfdebug_print: <3>[interface] (9)
Mar/01/2018 07:34:29: cfdebug_print: <5>[eth0] (4)
Mar/01/2018 07:34:29: cfdebug_print: <3>begin of closure [{] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:34:29: cfdebug_print: <3>[ia-na] (5)
Mar/01/2018 07:34:29: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[request] (7)
Mar/01/2018 07:34:29: cfdebug_print: <3>[domain-name-servers] (19)
Mar/01/2018 07:34:29: cfdebug_print: <3>[,] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[domain-name] (11)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:34:29: cfdebug_print: <3>[rapid-commit] (12)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[send] (4)
Mar/01/2018 07:34:29: cfdebug_print: <3>[ia-pd] (5)
Mar/01/2018 07:34:29: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[script] (6)
Mar/01/2018 07:34:29: cfdebug_print: <3>["/opt/vyatta/sbin/ubnt-dhcp6c-script"] (37)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[id-assoc] (8)
Mar/01/2018 07:34:29: cfdebug_print: <15>[na] (2)
Mar/01/2018 07:34:29: cfdebug_print: <15>[0] (1)
Mar/01/2018 07:34:29: cfdebug_print: <15>begin of closure [{] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[id-assoc] (8)
Mar/01/2018 07:34:29: cfdebug_print: <15>[pd] (2)
Mar/01/2018 07:34:29: cfdebug_print: <15>[0] (1)
Mar/01/2018 07:34:29: cfdebug_print: <15>begin of closure [{] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[prefix] (6)
Mar/01/2018 07:34:29: cfdebug_print: <3>[::] (2)
Mar/01/2018 07:34:29: cfdebug_print: <3>[/] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[60] (2)
Mar/01/2018 07:34:29: cfdebug_print: <3>[infinity] (8)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[prefix-interface] (16)
Mar/01/2018 07:34:29: cfdebug_print: <5>[switch0] (7)
Mar/01/2018 07:34:29: cfdebug_print: <3>begin of closure [{] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[sla-id] (6)
Mar/01/2018 07:34:29: cfdebug_print: <3>[0] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[sla-len] (7)
Mar/01/2018 07:34:29: cfdebug_print: <3>[4] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>[ifid] (4)
Mar/01/2018 07:34:29: cfdebug_print: <3>[1] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of closure [}] (1)
Mar/01/2018 07:34:29: cfdebug_print: <3>end of sentence [;] (1)
Mar/01/2018 07:34:29: configure_pool: called
Mar/01/2018 07:34:29: clear_poolconf: called
Mar/01/2018 07:34:29: dhcp6_reset_timer: reset a timer on eth0, state=INIT, timeo=0, retrans=675
Mar/01/2018 07:34:29: client6_send: a new XID (f2a7dd) is generated
Mar/01/2018 07:34:29: copy_option: set client ID (len 14)
Mar/01/2018 07:34:29: copyout_option: set identity association
Mar/01/2018 07:34:29: copy_option: set rapid commit (len 0)
Mar/01/2018 07:34:29: copy_option: set elapsed time (len 2)
Mar/01/2018 07:34:29: copy_option: set option request (len 4)
Mar/01/2018 07:34:29: copyout_option: set IA_PD prefix
Mar/01/2018 07:34:29: copyout_option: set IA_PD
Mar/01/2018 07:34:29: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:34:29: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=0, retrans=1061
Mar/01/2018 07:34:31: copy_option: set client ID (len 14)
Mar/01/2018 07:34:31: copyout_option: set identity association
Mar/01/2018 07:34:31: copy_option: set rapid commit (len 0)
Mar/01/2018 07:34:31: copy_option: set elapsed time (len 2)
Mar/01/2018 07:34:31: copy_option: set option request (len 4)
Mar/01/2018 07:34:31: copyout_option: set IA_PD prefix
Mar/01/2018 07:34:31: copyout_option: set IA_PD
Mar/01/2018 07:34:31: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:34:31: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=1, retrans=2023
Mar/01/2018 07:34:33: copy_option: set client ID (len 14)
Mar/01/2018 07:34:33: copyout_option: set identity association
Mar/01/2018 07:34:33: copy_option: set rapid commit (len 0)
Mar/01/2018 07:34:33: copy_option: set elapsed time (len 2)
Mar/01/2018 07:34:33: copy_option: set option request (len 4)
Mar/01/2018 07:34:33: copyout_option: set IA_PD prefix
Mar/01/2018 07:34:33: copyout_option: set IA_PD
Mar/01/2018 07:34:33: client6_send: send solicit to ff02::1:2%eth0
Mar/01/2018 07:34:33: dhcp6_reset_timer: reset a timer on eth0, state=SOLICIT, timeo=2, retrans=4101
Mar/01/2018 07:34:33: client6_recv: receive advertise from fe80::201:5cff:fe6d:9c46%eth0 on eth0
Mar/01/2018 07:34:33: dhcp6_get_options: get DHCP option client ID, len 14
Mar/01/2018 07:34:33:   DUID: 00:01:00:01:22:2a:69:85:04:18:d6:06:61:0a
Mar/01/2018 07:34:33: dhcp6_get_options: get DHCP option server ID, len 14
Mar/01/2018 07:34:33:   DUID: 00:01:00:01:1c:e4:c0:0d:40:a8:f0:2e:8f:18
Mar/01/2018 07:34:33: dhcp6_get_options: get DHCP option identity association, len 40
Mar/01/2018 07:34:33:   IA_NA: ID=0, T1=1800, T2=2880
Mar/01/2018 07:34:33: copyin_option: get DHCP option IA address, len 24
Mar/01/2018 07:34:33: copyin_option:   IA_NA address: 2001:558:6045:61:e587:1060:f929:20e7 pltime=3600 vltime=3600
Mar/01/2018 07:34:33: dhcp6_get_options: get DHCP option IA_PD, len 41
Mar/01/2018 07:34:33:   IA_PD: ID=0, T1=1800, T2=2880
Mar/01/2018 07:34:33: copyin_option: get DHCP option IA_PD prefix, len 25
Mar/01/2018 07:34:33: copyin_option:   IA_PD prefix: 2601:643:8403:6670::/60 pltime=3600 vltime=3600
Mar/01/2018 07:34:33: dhcp6_get_options: get DHCP option DNS, len 32
Mar/01/2018 07:34:33: client6_recvadvert: server ID: 00:01:00:01:1c:e4:c0:0d:40:a8:f0:2e:8f:18, pref=-1
Mar/01/2018 07:34:33: client6_recvadvert: unexpected advertise
Mar/01/2018 07:34:33: client6_recvadvert: reset timer for eth0 to 0.958186
Mar/01/2018 07:34:34: select_server: picked a server (ID: 00:01:00:01:1c:e4:c0:0d:40:a8:f0:2e:8f:18)
Mar/01/2018 07:34:34: client6_send: a new XID (31cbf0) is generated
Mar/01/2018 07:34:34: copy_option: set client ID (len 14)
Mar/01/2018 07:34:34: copy_option: set server ID (len 14)
Mar/01/2018 07:34:34: copyout_option: set IA address
Mar/01/2018 07:34:34: copyout_option: set identity association
Mar/01/2018 07:34:34: copy_option: set elapsed time (len 2)
Mar/01/2018 07:34:34: copy_option: set option request (len 4)
Mar/01/2018 07:34:34: copyout_option: set IA_PD prefix
Mar/01/2018 07:34:34: copyout_option: set IA_PD
Mar/01/2018 07:34:34: client6_send: send request to ff02::1:2%eth0
Mar/01/2018 07:34:34: dhcp6_reset_timer: reset a timer on eth0, state=REQUEST, timeo=0, retrans=1092
Mar/01/2018 07:34:34: client6_recv: receive reply from fe80::201:5cff:fe6d:9c46%eth0 on eth0
Mar/01/2018 07:34:34: dhcp6_get_options: get DHCP option client ID, len 14
Mar/01/2018 07:34:34:   DUID: 00:01:00:01:22:2a:69:85:04:18:d6:06:61:0a
Mar/01/2018 07:34:34: dhcp6_get_options: get DHCP option server ID, len 14
Mar/01/2018 07:34:34:   DUID: 00:01:00:01:1c:e4:c0:0d:40:a8:f0:2e:8f:18
Mar/01/2018 07:34:34: dhcp6_get_options: get DHCP option identity association, len 40
Mar/01/2018 07:34:34:   IA_NA: ID=0, T1=1800, T2=2880
Mar/01/2018 07:34:34: copyin_option: get DHCP option IA address, len 24
Mar/01/2018 07:34:34: copyin_option:   IA_NA address: 2001:558:6045:61:e587:1060:f929:20e7 pltime=3600 vltime=3600
Mar/01/2018 07:34:34: dhcp6_get_options: get DHCP option IA_PD, len 41
Mar/01/2018 07:34:34:   IA_PD: ID=0, T1=1800, T2=2880
Mar/01/2018 07:34:34: copyin_option: get DHCP option IA_PD prefix, len 25
Mar/01/2018 07:34:34: copyin_option:   IA_PD prefix: 2601:643:8403:6670::/60 pltime=3600 vltime=3600
Mar/01/2018 07:34:34: dhcp6_get_options: get DHCP option DNS, len 32
Mar/01/2018 07:34:34: info_printf: nameserver[0] 2001:558:feed::1
Mar/01/2018 07:34:34: info_printf: nameserver[1] 2001:558:feed::2
Mar/01/2018 07:34:34: get_ia: make an IA: PD-0
Mar/01/2018 07:34:34: update_prefix: create a prefix 2601:643:8403:6670::/60 pltime=3600, vltime=3600
Mar/01/2018 07:34:34: ifaddrconf: add an address 2601:643:8403:6670::1/64 on switch0
Mar/01/2018 07:34:34: get_ia: make an IA: NA-0
Mar/01/2018 07:34:34: update_address: create an address 2001:558:6045:61:e587:1060:f929:20e7 pltime=3600, vltime=3600
Mar/01/2018 07:34:34: ifaddrconf: add an address 2001:558:6045:61:e587:1060:f929:20e7/128 on eth0
Mar/01/2018 07:34:34: dhcp6_remove_event: removing an event on eth0, state=REQUEST
Mar/01/2018 07:34:34: dhcp6_remove_event: removing server (ID: 00:01:00:01:1c:e4:c0:0d:40:a8:f0:2e:8f:18)
Mar/01/2018 07:34:34: client6_recvreply: executes /opt/vyatta/sbin/ubnt-dhcp6c-script
Mar/01/2018 07:34:36: client6_script: script "/opt/vyatta/sbin/ubnt-dhcp6c-script" terminated
Mar/01/2018 07:34:36: client6_recvreply: got an expected reply, sleeping.
^C

 

 

So it looks like the C code in dhcp6c (https://github.com/jinmei/wide-dhcpv6/blob/master/dhcp6c.c) is doing the right things, but the perl script is getting a little confused with the byte ordering.

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Working through this at the moment since Ubiquiti isn't really feeling the pressure.  Work is currently being tracked here:

 

https://github.com/brianredbeard/edgeos_setup/tree/bugfixes/bugfixes

 

 

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Seriously... the more I look at this utility, the angrier it's making me. It's like there was no QA or testing for this. For those wanting to follow along, just read the file notes.md and ignore the commit messages. That's the my only place to (fully) vent at the moment.
New Member
Posts: 6
Registered: ‎01-30-2018
Kudos: 2

Re: Comcast IPv6 issues when hwnat enabled on ER-X

[ Edited ]

So it appears that that 16-bit part with its byte ordering reversed stores the length of the DUID. 0x000e is 14 which is the correct length, I believe. 0x0e00 is decimal 3584. The length of the screwed version of DUID file show in notes.md is 14 bytes followed by 3570 empty colon delimited entries.

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Yup, @mcrane...  That seems to be it.  After digging into the syntax for pack and unpack, it becomes obvious.... the only check for endianness is in the function show_duid().  In the calls for set_duid() and set_duid_bin() they are just blindly slamming things into network byte order (big endian) in the call to pack(), regardless of the byte order of the chipset:

 

sub set_duid {
    my ($duid) = @_;

    open(my $FH, '>', $dhcp6c_duid) || die "Error opening [$dhcp6c_duid]: $!\n";
    binmode($FH);

    # print $duid;

    $duid =~ s/://g;
    # print $duid;
    my $len = length($duid) / 2;
    my $buf = pack("n", $len);
    print $FH $buf || die "duid length write failed: $!\n";

    my $bin_duid = pack("H*", $duid);
    print $FH $bin_duid || die "duid write failed: $!\n";
    close($FH);
}

sub set_duid_bin {
    my ($duid) = @_;

    open(my $FH, '>', $dhcp6c_duid) || die "Error opening [$dhcp6c_duid]: $!\n";
    binmode($FH);

    $duid =~ s/://g;
    my $len = length($duid);
    my $buf = pack("n", $len);
    print $FH $buf || die "write failed\n";

    print $FH $duid;
    close($FH);
}

 

 

 

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

So according to RFC3315 (Section 9.1 - https://tools.ietf.org/html/rfc3315#section-9.1) it seems that portions should be stored in network byte order, but not all:

 

9.2. DUID Based on Link-layer Address Plus Time [DUID-LLT]

   This type of DUID consists of a two octet type field containing the
   value 1, a two octet hardware type code, four octets containing a
   time value, followed by link-layer address of any one network
   interface that is connected to the DHCP device at the time that the
   DUID is generated.  The time value is the time that the DUID is
   generated represented in seconds since midnight (UTC), January 1,
   2000, modulo 2^32.  The hardware type MUST be a valid hardware type
   assigned by the IANA as described in RFC 826 [14].  Both the time and
   the hardware type are stored in network byte order.  The link-layer
   address is stored in canonical form, as described in RFC 2464 [2].

   The following diagram illustrates the format of a DUID-LLT:

     0                   1                   2                   3
     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |               1               |    hardware type (16 bits)    |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |                        time (32 bits)                         |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    .                                                               .
    .             link-layer address (variable length)              .
    .                                                               .
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


   The choice of network interface can be completely arbitrary, as long
   as that interface provides a globally unique link-layer address for
   the link type, and the same DUID-LLT SHOULD be used in configuring
   all network interfaces connected to the device, regardless of which
   interface's link-layer address was used to generate the DUID-LLT.

   Clients and servers using this type of DUID MUST store the DUID-LLT
   in stable storage, and MUST continue to use this DUID-LLT even if the
   network interface used to generate the DUID-LLT is removed.  Clients
   and servers that do not have any stable storage MUST NOT use this
   type of DUID.

   Clients and servers that use this DUID SHOULD attempt to configure
   the time prior to generating the DUID, if that is possible, and MUST
   use some sort of time source (for example, a real-time clock) in
   generating the DUID, even if that time source could not be configured
   prior to generating the DUID.  The use of a time source makes it
   unlikely that two identical DUID-LLTs will be generated if the
   network interface is removed from the client and another client then
   uses the same network interface to generate a DUID-LLT.  A collision
   between two DUID-LLTs is very unlikely even if the clocks have not
   been configured prior to generating the DUID.

   This method of DUID generation is recommended for all general purpose
   computing devices such as desktop computers and laptop computers, and
   also for devices such as printers, routers, and so on, that contain
   some form of writable non-volatile storage.

   Despite our best efforts, it is possible that this algorithm for
   generating a DUID could result in a client identifier collision.  A
   DHCP client that generates a DUID-LLT using this mechanism MUST
   provide an administrative interface that replaces the existing DUID
   with a newly-generated DUID-LLT.

 

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

[ Edited ]

Resolution for corruption issues with the DUID:

 

https://github.com/brianredbeard/edgeos_setup/blob/bugfixes/bugfixes/opt/vyatta/sbin/dhcpv6-pd-duid....

 

There is a bug in the package vyatta-cfg-system_0.20.22.  The utility scripts/dhcpv6-pd-duid.pl, which is called by the configuration system in handling of the file /var/lib/dhcpv6/dhcp6c_duid fails to properly handle ordering of the most significant byte on little endian platforms (ER-X, etc).

 

This version makes a few changes from the original:

  • Resolving issue with the byte ordering of the length field of a DUID
  • Additional comments explaining the logic
  • Presenting the correct fields as per RFC 3315:
    • Link type (previously defined, but not correctly inserted)
    • Time (wrong length being sent

 

 Edited: GitHub URL changed to link directly to a hash so as not to track a mutable resource (the branch name).

New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

[ Edited ]

For anyone interested in the exact changes, they can be viewed in a visual diff here:

 

https://github.com/brianredbeard/edgeos_setup/compare/db9cc6f161efecef6775e9f7777823890dd08bfd...b9f...

 

I thought about digging in further, adding some tests, etc... and then I realized I'm doing free work for a company who doesn't publish the sources for their open source components in any easily consumable manner....why am I bothering?

 

Edited: Changed wording in last paragraph for content/clarity.

New Member
Posts: 6
Registered: ‎01-30-2018
Kudos: 2

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Nice work! It's really sad that Ubiquity or Vyatta couldn't be bothered to (apparently) even actually look at this after more than a year of people reporting problems.

Established Member
Posts: 1,564
Registered: ‎03-02-2016
Kudos: 348
Solutions: 114

Re: Comcast IPv6 issues when hwnat enabled on ER-X

Nice work. @UBNT-benpin and @UBNT-sandisn - please take a look.
New Member
Posts: 17
Registered: ‎09-06-2015
Kudos: 29

Re: Comcast IPv6 issues when hwnat enabled on ER-X

[ Edited ]

@mcrane Having stepped back through the whole thread I figure I'll share some of my assumptions, throught processes, etc.  

 

First off, I want to say that while there 100% WAS problems with that utility, it may not be the same thing that other folks are seeing...  that being said, it's hard to know for sure.  One of the things that I did VERY intentionally was sharing a consistent DUID that had been generated. 

 

This goes against the common understanding (within IPv6 spheres) that a DUID is a secret and should be kept secret.  I wonder how many people (if anyone) were setting a DUID in their configs (as I was) to attemp to ensure that it stayed consistent, but redacted it out of the guidance that a DUID is a secret.

 

 

I was setting the DUID because (as RFC 3315 states):

 

 

 The DUID is designed to be unique across all DHCP clients and servers, and
 stable for any specific client or server - that is, the DUID used by a client
 or server SHOULD NOT change over time if at all possible; for example, a
 device's DUID should not change as a result of a change in the device's network
 hardware.

 

 

and

 

 

Clients and servers using this type of DUID MUST store the DUID-LLT
in stable storage, and MUST continue to use this DUID-LLT even if the
network interface used to generate the DUID-LLT is removed.

 

 

Thus... it made sense to set it via:

 

 

set interfaces ethernet eth0 dhcpv6-pd duid '00:01:06:00:5a:be:90:92:00:00:00:00:00:00'

 

 

Now... should hwnat be changing the byte order processing of the CPU? Of course not.  Should Comcast specific issues have anything to do with bugs in a Perl script? No, and if so that would be mind blowing.  

 

After all the only place the string "duid" (case insensitive) shows up in the Vyatta bits is that one script (dhcpv6-pd-duid.pl) and then the various templates for configuration.

 

 

root@panic:/opt/vyatta# grep -r -i -l  duid *
sbin/dhcpv6-pd-duid.pl
share/vyatta-cfg/templates/interfaces/bonding/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/bonding/node.tag/vif/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/bridge/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/bridge/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/bridge/node.tag/vif/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/bridge/node.tag/vif/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/ethernet/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/ethernet/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/ethernet/node.tag/vif/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/ethernet/node.tag/vif/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/pseudo-ethernet/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/pseudo-ethernet/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/pseudo-ethernet/node.tag/vif/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/switch/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/switch/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/switch/node.tag/vif/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-cfg/templates/interfaces/switch/node.tag/vif/node.tag/pppoe/node.tag/dhcpv6-pd/duid/node.def
share/vyatta-op/templates/show/dhcpv6-pd/duid/node.def
share/vyatta-op/templates/delete/dhcpv6-pd/duid/node.def

 

Also, this wouldn't explain why when @cdozois (or other users) were running dhcp6c in the foreground that they go no response.  More importantly @UBNT-sandisn has been doing what they can too because to solve an issue like this one needs to make a BUNCH of assumptions about what the end user may be doing...  in my case though I didn't have to make any assumptions.  I just happened to have the right confluence of skills and knowledge to think differently about the problem.

 

Oh, that and spending way too much time hex editing save files for games in the 90s.  Biggrin5

 

For anyone who is interested in more of the backend side of various Ubiquiti devices digging into the work done by @sjjenkins@Lochnair, @nickolai and others are super useful.  

 

Also, I will continue to keep dumping information about the systems side of Ubiquiti devices here - https://github.com/brianredbeard/edgeos_setup/

 

Edited: Fixed typo many -> make 

New Member
Posts: 6
Registered: ‎01-30-2018
Kudos: 2

Re: Comcast IPv6 issues when hwnat enabled on ER-X

> First off, I want to say that while there 100% WAS problems with that utility, it may not be the same thing that other folks are seeing...

I updated dhcpv6-pd-duid.pl and turned offloading back on about 12 hours ago. It generally takes more than a day for my ipv6 connectivity to die. I'll report back if it does.
Reply