Don’t set up any ip6addr nor ip6prefix to the lan interface. They all belong to wan6. IPv6 address of lan interface is automagically configured by ip6assign out of ip6prefix of other interface(s).
As far as I know, the ::1 address is hardcoded in OpenWRT netifd and cannot be changed. For further information, refer to OpenWRT native IPv6-stack wikipage.
Ok, thank you.
What is supposed to happen if proto is static (necessary for IPv4), and I give no ip6addr?
Anyway, I forced ip6addr to [prefix]::1, and it’s ok!
Isn’t it a problem that the same [prefix]::1 is assigned once on the DSL router (default gateway on WAN interface) and once on the LAN interface ?
It will get assigned automatically out of the ip6prefix of other interfaces (usually wan6). See ifstatus wan6 output to see the assignment.
Setting ip6addr to different address will not help, because there are filters set up by OpenWRT IPv6 stack, which would prevent forwarding of any unknown IP prefixes.
It is. You should have different prefix on WAN and LAN side. Usually, you get the LAN prefix leased using DHCPv6 Prefix delegation. But if your DSL router doesn’t do prefix delegation, you have to delegate a route statically (if DSL router supports it and your provider gives you short enough prefix) or switch DSL router to bridge mode.
On the WAN side, the DSL router is (prefix)::1, and let me configure next hop to (prefix)::2, which is the address I assigned to the Omnia WAN interface. The WAN network is (prefix)::/126. I added a static default route to the fe80 address of the DSL router.
Interesting solution. If it is possible to choose address of the DSL modem, I would change it to something like ::1:10/127 and use a /127 on the WAN link. This would be somehow cleaner solution. But if it works like this, then then I think it’s OK.
is there an option, to use static ipv6 for downstream? Ive got /63 on wan6, but ip6hint doesnt work for me, interfaces got two subnets (via ip6assign), avaible from assigned /63, and thats end of ipv6 options for the rest of interfaces.
I would like to setup downstream as one subnet for lan+wifi, and second one for the VPN.
Although you can set static IPv6 for a downstream port, it would not work due to ingress filtrering of IPv6 traffic. You should let netifd assign IPv6 to downstream ports according to ip6assign option. ip6hint should work, although I’m not sure what should be the proper contents for such long assignment as /63.
If you have only /63 on wan6, that means only at most two /64 subnets. If you have more than two subnets with ip6assign option, any extra interfaces will not get any IPv6. So just delete ip6assign option from those interfaces and it should work as expected.