IPv6 not working after a day

Have had an ongoing issue with IPv6 since installing OpenWrt at one location... seems IPv6 is lost to all clients on LAN after about one day, reboot it and it works fine until the next day. There is nothing out of ordinary about the configuration, the router is installed as the main gateway and is not behind any other firewalls. IPv6 on the router continues to work, even when all clients will not work...

I am unsure how to approach this issue. I could post config elements but I have changed nothing with routing or firewall aside from some port forwards...

Tips? Where should I be looking to discover an error? dmesg and logread show no error at the time this occurs.

Thanks for reading

I assume DHCPv6 is being used for the wan? Sounds sort of like the PD isn't being renewed. There are probably easier ways, but I use

$ ubus call network.interface dump | jsonfilter -e '$.interface[@.interface = "wan6"]["route"].*'
{ "target": "::", "mask": 0, "nexthop": "fe80::1fe:c8ff:fe01:c119", "metric": 512, "valid": 1796, "source": "2601:1802:1801:b100::\/56" }

which shows the remaining lease in seconds as the "valid" entry (Cox updates mine every 2-3 seconds).

You can monitor various DHCPv6 events by adding some logging to /etc/odhcp6c.user, like this. For your case, maybe you should change that conditional I've got below to include all events and not ignore those "ra-updated" ones, at least to start.

$ cat /etc/odhcp6c.user
# This script is sourced by odhcp6c's dhcpv6.script at every DHCPv6 event.
# For "action" values, see  https://github.com/openwrt/odhcp6c
# down in the "States:" description section.

if [ "$action" != "ra-updated" ]; then
    jshn -i -w | logger -t dhcp6-json

Then you do logread -e dhcp6 and see all the events it recorded...

1 Like