Router has IPv6 and IPv6 PD from ISP, cannot assign v6 addresses to LAN

I have my network setup where I have fiber connected to my ISP's modem. The modem is set to Bridge, and it's connected to my OpenWrt router's WAN port.

I've managed to setup PPPoE after talking with customer support to obtain the credentials, and now I'm trying to setup IPv6 connection. I noticed none of my connected devices (desktop, phone) have a v6 address assigned.

I checked the wiki on how to configure IPv6 and tried to follow the base configuration settings listed on the troubleshooting page:

  • ULA assignment: disabled (see Network > Interfaces > Global network options)
  • “Request IPv6-address”: try
  • “Request IPv6-prefix of length”: set to /64, verify that a block is assigned; set to /60, see if a block is still assigned; repeat until largest possible block is determined. Alternatively, set to automatic to use the default from the ISP
  • “Do not send a Release when restarting”: enable
  • “Delegate IPv6 prefixes”: enable on wan6, disable everywhere else
  • “IPv6 assignment length”: disable on wan6, enable and set to 64 on lan and other local subnetworks
  • “IPv6 assignment hint”: set to successive integers on each local subnetwork (this determines the /64 ranges that will be assigned to each subnetwork from your prefix delegation)
  • “RA-Service”: disable on wan6, set to server mode on lan and other subnetworks
  • “DHCPv6-Service”: disable on wan6, set to server mode on lan and other subnetworks
  • “NDP-Proxy”: set to relay mode

I followed these steps, and I had partial success. wan6 gets assigned a IPv6-PD with a /56, and eventually a /64 IPv6 address. However, my lan interface shows up with two IPv6 addresses set to undefined/0:

I also noticed that the following line appears frequently in my system log:

Wed Jun 11 23:50:03 2025 daemon.err odhcpd[1853]: setsockopt(PACKET_ADD_MEMBERSHIP): Invalid argument

I'm not sure what's going on and would like to know what's happening. For example, I noticed that I need to set the wan6 device to pppoe-wan for it to get the PD address assigned from my ISP, otherwise it doesn't get any v6 addresses.

Here are my configs:

# /etc/config/network

config globals 'globals'
        option ula_prefix 'fd20:3837:99c8::/48'
        option packet_steering '1'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '64'
        option delegate '0'

config interface 'wan'
        option device 'wan'
        option proto 'pppoe'
        option username 'pppoe username'
        option password 'pppoe password'
        option ipv6 '1'
        option keepalive '5 1'
        option peerdns '0'
        option delegate '0'
        list dns '9.9.9.9'
        list dns '149.112.112.112'
        option sourcefilter '0'

config interface 'wan6'
        option proto 'dhcpv6'
        option reqaddress 'try'
        option reqprefix 'auto'
        option norelease '1'
        option device 'pppoe-wan'
# /etc/config/dhcp

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option ra 'server'
        option dhcpv6 'server'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'
        option ndp 'relay'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'

config dhcp 'wan6'
        option interface 'wan6'
        option ndp 'relay'

No guarantee that it's the same problem, but another user just recently had the same symptom (LAN IPv6 addresses showing as "Undefined/0"). In that user's case, the cause was that IPv6 was disabled on the "br-lan" bridge device.

You've trimmed down your /etc/config/network so that device's settings are not visible to us, but it's the first thing I'd check.

Yes computa. Post is not empty.

Why? If you have 256 subnets why did you want ndp proxy. That looks plain wrong.

Remove the ndp option.

Remove this whole section.

2 Likes

My bad, this was my device config:

config device
        option name 'br-lan'
        option type 'bridge'
        option ipv6 '0'
        list ports 'lan1'
        list ports 'lan2'
        list ports 'lan3'

turns out you were right. I had IPv6 disabled, now that I've enabled it I have v6 assigned to my devices.

Remove this-- since you want delegation to occur. Though it probably has no effect in the wan section which is mostly about IPv4. Once the pppoe tunnel is established, the wan6 section should send dhcp/ra to the ISP, inside the tunnel. Does wan6 have a v6 address and prefix? ifstatus wan6 is useful to check that.

In the wan block I think ipv6 1 means use a manually configured interface inside the tunnel (typically wan6, though it could have any name) while ipv6 auto means to spawn a wan_6 automatically.

1 Like

Now this is interesting, after enabling IPv6, I now get assigned a total of 4 v6 addresses: 2 with the ULA prefix, and 2 with my public prefix. However, one of each is a /64, and the other is a /128.

Why is this happening? Is it normal or should I only have a /128 or /64?

On a LAN device you mean? It is normal to get two of each kind, one from SLAAC and one from DHCPv6. (DHCPv6 isn't really necessary in a typical home network, and the same for ULAs). But SLAAC leaves the lan endpoint free to randomly choose and use as many IPs as it wants within the /64. This can enhance privacy some by rotating addresses frequently and using different addresses for different applications.

3 Likes

Is there a way to find out which one assigns the /128?

This is my ip config:

2: enp6s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 3c:7c:3f:7b:7a:d5 brd ff:ff:ff:ff:ff:ff
    altname enx3c7c3f7b7ad5
    inet 192.168.1.217/24 brd 192.168.1.255 scope global dynamic noprefixroute enp6s0
       valid_lft 43196sec preferred_lft 43196sec
    inet6 fd20:3837:99c8::1fe/128 scope global dynamic noprefixroute 
       valid_lft 43197sec preferred_lft 2784sec
    inet6 2001:4c4d:1e03:9000::1fe/128 scope global dynamic noprefixroute 
       valid_lft 2784sec preferred_lft 2784sec
    inet6 2001:4c4d:1e03:9000:8c0b:b147:4fef:eba/64 scope global dynamic noprefixroute 
       valid_lft 2784sec preferred_lft 2784sec
    inet6 fd20:3837:99c8:0:1e55:6c79:1366:c6c4/64 scope global noprefixroute 
       valid_lft forever preferred_lft 604797sec
    inet6 fe80::9c10:eea2:8d09:539e/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

you can see that there's an address with a chain of 0s, (the /128). Is this configured via the ip6hint option?

also would it be possible to stop attributing the /128 as a whole?

You get it from dhcpv6.

Edit. A /128 is just a single address.

2 Likes

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.