IPv6 connection through PPPoE with tagged VLAN

Hello.

I'm a new user of OpenWrt. I'm trying to configure connection to my ISP which requires to have tagged VLAN on connection through PPPoE (sorry if that's not technically correct statement, but more-or-less I hope everyone will understand that.)

"Somewhat working" configuration below:

config device
        option name 'wan.35'
        option type '8021q'
        option ifname 'wan'
        option vid '35'

config device
        option name 'eth0.4'
        option type '8021q'
        option ifname 'eth0'
        option vid '4'

config device
        option name 'br-wan'
        option type 'bridge'
        list ports 'wan.35'
        list ports 'eth0.4'
        option mtu '1492'
        option multicast '0'
        option ipv6 '0'

config interface 'wan'
        option device 'br-wan'
        option proto 'pppoe'
        option username 'myusername@myisp.tld'
        option password 's3cr3t'
        option ipv6 '0'

config interface 'wan6'
        option device 'br-wan'
        option proto 'pppoe'
        option username 'myusername@myisp.tld/ipv6'
        option password 's3cr3t'
        option ipv6 'auto'

By "somewhat working" I mean PPPoE session takes several minutes to establish (it depends, can be 1-2 minutes, or even up to 15) with pretty frequent pppoe-wan and pppoe-wan6 dissappearing and appearing all the time. Also, my br-lan interface gets IPv6 addresses that are being flagged as deprecated, don't know why. All in all, connection gets established, but with hiccups mentioned above, so I would really appreciate if someone could help me verify correctness of my /etc/config/network. I guess that configuration is not the best outcome that I can get.

I'm not sure if I understand the part with bridging wan and eth VLANs, doesn't make sense to me.

Also, I've seen configurations utilizing switch0 in similar configuration scenarios, not sure if that's still supported by newer OpenWrt releases, or config device with option type '8021q' is the recommended way?

I would be very thankful for helping with this, as I'm running out of ideas how to properly tie these things into a working, comprehensive configuration. Thank you!

Delete all of this:

And edit the device used to simply be wan.35 like so:

config interface 'wan'
        option device 'wan.35'
        option proto 'pppoe'
        option username 'myusername@myisp.tld'
        option password 's3cr3t'
        option ipv6 '0'

config interface 'wan6'
        option device 'wan.35'
        option proto 'pppoe'
        option username 'myusername@myisp.tld/ipv6'
        option password 's3cr3t'
        option ipv6 'auto'

Thanks for your reply, but I'm not sure that helped the way I wanted. Connection still takes some time to establish, unfortunately.

That's where I got the idea for my config: https://forum.openwrt.org/t/is-pppoe-over-vlan-possible/222508/8

There must be a reason people are doing it like this way.

The device I have that is connected to WAN port is the ONT device where fiber is connected to.

I am not an expert on pppoe issues, so I can't really help you debug/resolve the time that it is taking for the connection to be established.

I am confident in the wan.35 device and the fact that the 802.1q stanza and the br-wan are not necessary (not only that, they were not correctly formed, anyway).

We can take a look at the rest of your config to make sure that there aren't any other errors:

Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button (red circle; this works best in the 'Markdown' composer view in the blue oval):

Screenshot 2025-10-20 at 8.14.14 PM

Remember to redact passwords, VPN keys, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
cat /etc/config/wireless
cat /etc/config/dhcp
cat /etc/config/firewall

Try this config in the place of the one you have posted

config device
    option type '8021q'
    option ifname 'wan'
    option vid '35'
    option name 'wan.35'

config interface 'wan'
    option device 'wan.35'
    option proto 'pppoe'
    option username 'pppoe_username'
    option password 'pppoe_password'
    option ipv6 '1'

config interface 'wan6'
    option device '@wan'
    option proto 'dhcpv6'
    option reqaddress 'try'
    option reqprefix '56'

BTW is the WAN port "wan or "eth0"?
Does your ISP require WAN VLAN ID to be 35 or 4?

Unfortnately this config doesn't successfully assign IPv6 address. IPv4 is working tho. The important part is that /ipv6 at the end of the username, which I have to provide. So I'm not sure if that mapping for wan6 configured like above will work. Can I somehow provide username and password credentials to the wan6 interface in your example?

Also:

BTW is the WAN port "wan or "eth0"?
Does your ISP require WAN VLAN ID to be 35 or 4?

WAN port is just wan, yes.

My ISP requires WAN's VLAN ID to be 35, that's correct.

From all configuration files that you have mentioned I've only edited /etc/config/network with appropriate WAN configuration and /etc/config/wireless to enable radio for 5GHz and my WiFi network password. I did not mess with dhcp or firewall settings, at least for now.

ok... well, let's see the complete output of:

/etc/config/network with changes suggested by @ka2107 (IPv6 not being properly requested/assigned with it, unfortunately)

root@OpenWrt:~# cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        list ipaddr '127.0.0.1/8'

config globals 'globals'
        option dhcp_default_duid '0004485c754f3e4547478cbcffb65c4601cc'
        option ula_prefix 'fdd8:194e:f540::/48'

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

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        list ipaddr '192.168.1.1/24'
        option ip6assign '60'

config device
        option type '8021q'
        option ifname 'wan'
        option vid '35'
        option name 'wan.35'

config interface 'wan'
        option device 'wan.35'
        option proto 'pppoe'
        option username 'XXXX'
        option password 'XXXX'
        option ipv6 '1'

config interface 'wan6'
        option device '@wan'
        option proto 'dhcpv6'
        option reqaddress 'try'
        option reqprefix '56'

That's a weird way your ISP is providing IPv6. Which ISP and Country is this?

I don't know if OpenWrt's netifd supports directly requesting DHCPv6 IPv6 IA-NA and IA-PD addresses on the PPPoE wan6 interface.

Maybe try this config:

## ISP requires WAN VLAN ID 35
config device
    option type '8021q'
    option ifname 'wan'
    option vid '35'
    option name 'wan.35'

## PPPoE: IPv4
## IPv6 disabled on the netifd interface "wan"
config interface 'wan'
    option device 'wan.35'
    option proto 'pppoe'
    option username 'pppoe_ipv4_username'
    option password 'pppoe_ipv4_password'
    option ipv6 '0'

## PPPoE: IPv6
## This netifd interface "wan6" only obtains link-local IPv6 address via IPV6CP aka IPCP6 (RFC 5072). 
## The next netifd interface "wan6_" obtains the actual IPv6 WAN address via DHCPv6.
config interface 'wan6'
    option device 'wan.35'
    option proto 'pppoe'
    option username 'pppoe_ipv6_username'
    option password 'pppoe_ipv6_password'
    option ipv6 '1'

## DHCPv6 over PPPoE IPv6 interface
## This netifd interface "wan6_" obtains the actual IPv6 WAN address via DHCPv6.
## This will only work if netifd interface "wan6" is "active" and has a link-local IPv6 address assigned to it.
config interface 'wan6_'
    option device '@wan6'
    option proto 'dhcpv6'
    option reqaddress 'try'
    option reqprefix '56'

Also please make sure wan, wan6 and wan6_ interfaces are part of the wan firewall zone in /etc/config/firewall.

With that config I am able to connect, it just takes a very long time, like ~5 minutes to establish PPPoE session. pppoe-wan and pppoe-wan6 interfaces are being created and disappearing from ip a output very frequently. Any points on how to debug this further?

Look at the System Log. If the v4 interface is also going up and down v6 is not the real problem.

Is your modem / ONT in Bridge Mode? Looks like that device is handling PPPoE. AFAIK only one PPPoE session can be active for a particular username.

There are some fonfiguration available with dual-stack on the wiki.

I have PPPoE + VLAN35 in T-mobile Poland and to be honest, it does not work. Maybe one day when I will have more time will take a look more.

Thanks for link to the Wiki. There's a lot of useful information there and I'm impressed how good OpenWrt's Wiki is, but there's lacking configuration template for Orange FTTH. What helped in my case was @ka2107 config as a starting point + several options for DHCP (IPv4 and IPV6) to supplement the PPPoE connection process and to mimic the original Funbox/Livebox router behaviour. Here's the link to the original topic on french forum where I got the options. I'm still trying to figure out what options are strictly necessary to pass to the ISP as the part of IP addresses negotiation, but at least that helped with establishing the session faster than before.

No, this particular ONT it just a transparent device that is allowed (by the MAC address, I guess) on the ISP side to connect your device instead of ISP's original router. It's not trying to authenticate or establish any connection through PPPoE.

That french guide seems to be interesting! Maybe it would help @RafalB82 to replace Orange device again with BPi-R4 :slight_smile: