openwrt / packages

Community maintained packages for OpenWrt. Documentation for submitting pull requests is in CONTRIBUTING.md
GNU General Public License v2.0
3.93k stars 3.44k forks source link

openthread-br: Routing problems with ipv6 and ipv4 #23753

Open kaizirlewagen opened 5 months ago

kaizirlewagen commented 5 months ago

I build my own firmware with the latest openwrt master, and install the openthread-br package. I can create a openthread network, i can join an openthread cli device. I install tayga for nat64.

config interface 'nat64'
    option proto 'tayga'
    option device 'tayga-nat64'
    option ipv4_addr '192.168.255.1'
    option ipv6_addr '2001:db8:1::2'
    option prefix '2001:db8:1:ffff::/96'
    option dynamic_pool '192.168.255.0/24'
    option noroutes '0'
tayga-nat64 Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  
          inet6 addr: fe80::e592:6251:adea:dd91/64 Scope:Link
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:74 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:500 
          RX bytes:0 (0.0 B)  TX bytes:13832 (13.5 KiB)

I use some nordic devices to join and i can ping the child device with ipv6 from the openwrt. But i can't ping with ipv6 the router and i can't ping an ipv4 target behind the router and also not the router himself with ipv4 like.

Openthread IP data from the host

# ot-ctl ipaddr
fd00:0:fb01:1:0:ff:fe00:fc35
fd00:0:fb01:1:0:ff:fe00:fc10
fd00:0:fb01:1:0:ff:fe00:d000
fd11:22:0:0:69f0:7509:378:f403
fd00:0:fb01:1:63f3:1fd4:ad9a:1ca
fe80:0:0:0:4f8:6124:cc8c:5cb
Done
> joiner start J01NME
Done
> thread start
Done
> ipaddr
fd11:22:0:0:2cf0:4207:a5c:8686
fd00:0:fb01:1:0:ff:fe00:d001
fd00:0:fb01:1:9162:b700:2fcc:c131
fe80:0:0:0:6468:e0be:d327:1058
Done

ping from openthread nordic device:

# ping fd11:22:0:0:2cf0:4207:a5c:8686
PING fd11:22:0:0:2cf0:4207:a5c:8686 (fd11:22::2cf0:4207:a5c:8686): 56 data bytes
64 bytes from fd11:22::2cf0:4207:a5c:8686: seq=0 ttl=64 time=173.633 ms
64 bytes from fd11:22::2cf0:4207:a5c:8686: seq=1 ttl=64 time=49.717 ms
64 bytes from fd11:22::2cf0:4207:a5c:8686: seq=2 ttl=64 time=49.143 ms

The openthread network has the following config:

Active Timestamp: 1
Channel: 11
Channel Mask: 0x07fff800
Ext PAN ID: fb02fb02fb020000
Mesh Local Prefix: fd00:0:fb01:1::/64
Network Key: 00112233445566778899aabbccddeeff
Network Name: OpenThreadCes
PAN ID: 0xfb00
PSKc: 286c037075bb69e42f3635675fd3bb46
Security Policy: 672 onrc 0
Done

I think some routes are missing, in the readme i found.

Configuring the route is out of scope of this document, but it must be done, or joining Thread devices will fail.

Which routes i have to add manually?

Or do i have some firewall settings missing?

Thx for your help,

Greetings Tom

brada4 commented 5 months ago

Start by examining documentation? Usage query is not a bug report, forums can help you. https://openwrt.org/docs/guide-user/network/routing/routes_configuration