Can't ping remote device via Bluetooth Low Energy using routable IPv6 address

Al Bundy asked:

I have simple CoAP Server on a device that implements BLE Internet Protocol Support Profile. I wanted to test it using Mozilla Firefox with Copper plug-in. So far I have managed to connect to my device and ping it with success using its link local address. Unfortunately Firefox cannot access link-local addresses, so in order to use that, I have to configure my device with a routable address.

I have created /etc/radvd.conf file with content:

interface bt0
    AdvSendAdvert on;
    prefix 2001:db8::/64
        AdvOnLink off;
        AdvAutonomous on;
        AdvRouterAddr on;

Then I have set an address in the subnet for the linux box, enabled forwarding and restarted radvd.

sudo ip address add 2001:db8::1/64 dev bt0
echo 1 | sudo tee /proc/sys/net/ipv6/conf/all/forwarding
sudo service radvd restart

This is the output from ifconfig bt0:

bt0       Link encap:UNSPEC  HWaddr 00-15-83-FF-FE-E8-EB-0B-00-00-00-00-00-00-00-00  
          inet6 addr: fe80::215:83ff:fee8:eb0b/64 Scope:Link
          inet6 addr: 2001:db8::1/64 Scope:Global
          RX packets:111 errors:0 dropped:0 overruns:0 frame:0
          TX packets:116 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:8553 (8.5 KB)  TX bytes:10804 (10.8 KB)

Unfortunately something is still wrong configured. I can still ping my device using local link address ping6 fe80::215:83ff:fee8:eb0b%bt0 but when I want to ping it with its routable address ping6 -I bt0 2001:db8::215:83ff:fee8:eb0b I have no responses. I lack idea what might be wrong or what else I need to configure.

My answer:

It appears that your radvd configuration is missing the ABRO options, required for your system to be recognized as a 6LoWPAN border router.

A minimal configuration would be:

interface bt0 {
    abro fe80::215:83ff:fee8:eb0b/64 {
        AdvVersionHigh 10;
        AdvVersionLow 2;
        AdvValidLifeTime 2;
    #...everything else

And of course your devices must be Bluetooth 4.1 (or higher). 4.0 devices will not work.

View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.