Hi Jonathan,
We added logs in src/core/net/ip6.cpp(attached with logs) and below are the observations
1. In non working case(with externa commissioner), GetOnLinkNetif() is returning value greater than 0. Below are the logs. Please check with the attached file.
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - Unicast..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - Linklocal Unicast..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - forward1..
Mar 15 13:19:32 raspberrypi wpantund[18704]: DestIP - [2001:22:db8:1:0:0:0:2]
Mar 15 13:19:32 raspberrypi wpantund[18704]: NetifIP - [fd11:1111:1122:0:0:ff:fe00:fc37]
Mar 15 13:19:32 raspberrypi wpantund[18704]: PrefixLength is 0
Mar 15 13:19:32 raspberrypi wpantund[18704]: iForLoop is 1
Mar 15 13:19:32 raspberrypi wpantund[18704]: oForLoop is 1
Mar 15 13:19:32 raspberrypi wpantund[18704]: rval is 1
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - Iface 3 global..
Mar 15 13:19:32 raspberrypi wpantund[18704]: Fwd Iface ID - 1
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - forward3..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - forward5..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - exit..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - Unicast..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - 1 Unicast..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - Receive 1..
Mar 15 13:19:32 raspberrypi wpantund[18704]: IP6 - exit..
In working case(When native commissioner is started), GetOnLinkNetif() is returning value lesser than 0. Below are the logs.
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Unicast..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Linklocal Unicast..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - forward1..
Mar 15 13:44:29 raspberrypi wpantund[18704]: DestIP - [2001:22:db8:1:0:0:0:2]
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fd11:22:0:0:7428:71ab:ebbc:3358]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 64
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fd11:1111:1122:0:0:ff:fe00:fc00]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 128
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fd11:1111:1122:0:0:ff:fe00:8c00]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 64
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fd11:1111:1122:0:92e:db17:2800:cefe]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 64
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fe80:0:0:0:7428:71ab:ebbc:3358]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 64
Mar 15 13:44:29 raspberrypi wpantund[18704]: iForLoop is 5
Mar 15 13:44:29 raspberrypi wpantund[18704]: oForLoop is 1
Mar 15 13:44:29 raspberrypi wpantund[18704]: rval is -1
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Iface 5..
Mar 15 13:44:29 raspberrypi wpantund[18704]: Fwd Iface ID - 0
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - forward2..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - exit..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Unicast..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Linklocal Unicast..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - forward1..
Mar 15 13:44:29 raspberrypi wpantund[18704]: DestIP - [fd11:22:0:0:a48:3f8:57eb:4b70]
Mar 15 13:44:29 raspberrypi wpantund[18704]: NetifIP - [fd11:22:0:0:7428:71ab:ebbc:3358]
Mar 15 13:44:29 raspberrypi wpantund[18704]: PrefixLength is 64
Mar 15 13:44:29 raspberrypi wpantund[18704]: iForLoop is 1
Mar 15 13:44:29 raspberrypi wpantund[18704]: oForLoop is 1
Mar 15 13:44:29 raspberrypi wpantund[18704]: rval is 1
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - Iface 3 global..
Mar 15 13:44:29 raspberrypi wpantund[18704]: Fwd Iface ID - 1
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - forward5..
Mar 15 13:44:29 raspberrypi wpantund[18704]: IP6 - exit..
Observations:
===========
1. In non working case, commissioner ALOC alone is present as part of mNetifListHead whereas in working case, ip addresses of wpan0, leader ip address, leader aloc address are present in mNetifListHead
2. In a scenario we tested, first with native commissioner started and it works fine with mNetifListHead containing all IPs. The same exists even when native commissioner is stopped. But the moment when external commissioner is started, mNetifListHead contains only commissioner ALOC.
Please let us know your thoughs on these observations
Thanks.