DanielLavrushin:b4 的 IPv6 检测提议需先核实路由通告
在 b4 #669 的 IPv6 告警提议中,DanielLavrushin 说明,只有 IPv4 上联的 OpenWrt 仍可为 LAN 分配 ULA;odhcpd 的 Router Lifetime 为 0 时,不会给终端提供 IPv6 默认路由。因此,仅凭主机有非链路本地 IPv6 地址却无默认路由,可能产生误报。他要求核对实际 RA 的 Router Lifetime、终端路由及停止 b4 后的表现,再判断是否应由 b4 告警;尚未确认该用户故障的根因。
作者原文@DanielLavrushinThanks for the detailed write-up and for putting a branch together.
One thing to settle first: "a non-link-local IPv6 address and no IPv6 default route" is the normal state on OpenWrt with an IPv4-only uplink. OpenWrt gives the LAN a ULA prefix by default, and odhcpd then sends router advertisements with Router Lifetime 0, so devices don't get an IPv6 default route from it (RFC 7084, G-4). The check would warn on routers like that. Whether a device gets a default route depends on the Router Lifetime in the RA, which a host can't read from its own addresses and routes.
To tell whether this is what happens on your network, could you send:
- the router model and firmware, the b4 version, and System Info (Settings > System > Service > System Info > Copy JSON) with a b4 trace: https://docs.b4core.app/docs/troubleshooting/reporting
- the Router Lifetime in the LAN's router advertisement, for example from
rdisc6on a Linux device on the same Wi-Fi, or that device'sip -6 route- whether an affected phone still loses internet with b4 stopped
- whether the phone's Wi-Fi details show an IPv6 router while it says "No Internet Connection"
With that it is possible to see whether a default route is being advertised, and only then whether b4 should report it.