Vlans on an CM4 with DFRobot

Hi, I'm trying to get some to get somem vlans working. Vlan 1 10.10.0.0 and Vlan 20 192.168.20.0.
The switch i use is a TL-SG105E and connected from port 5 to eth1 on my OPNWrt router(CM4+dfrobot).
I created a bridge(br-lan) from eth1 and set the vlans up like you see in the pictures below.
Then i configured the switch so that an port 1 and 4 i get vlan1 and on 2 and 3 i get vlan20. But only vlan 1 is working, so what did i do wrong?
I'musing OpenWrt 23.05

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:
grafik
Remember to redact passwords, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
2 Likes

config interface 'loopback'
option device 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'

config globals 'globals'
option ula_prefix 'fdfe:e647:bf2b::/48'

config device
option name 'br-lan'
option type 'bridge'
list ports 'eth1'
option ipv6 '0'

config interface 'lan'
option device 'br-lan.1'
option proto 'static'
option ipaddr '10.10.0.1'
option netmask '255.255.255.248'
list dns '10.10.0.1'

config interface 'wan'
option device 'eth0'
option proto 'dhcp'
option type 'bridge'

config device
option name 'br-lan.20'
option type '8021q'
option ifname 'br-lan'
option vid '20'
option ipv6 '0'

config device
option name 'br-lan.1'
option type '8021q'
option ifname 'br-lan'
option vid '1'
option ipv6 '0'

config interface 'VLAN20'
option proto 'static'
option ipaddr '192.168.20.1'
option netmask '255.255.255.0'
option device 'br-lan.20'

config bridge-vlan
option device 'br-lan'
option vlan '1'
list ports 'eth1:t'

config bridge-vlan
option device 'br-lan'
option vlan '20'
list ports 'eth1:t'

Delete these. Then reboot your router.

Also, make sure that you’ve set the pvid on the ports correctly. Ports 1 and 4 should have pvid 1; ports 2 and 3 should be pvid 20.

Yes i forgot to set the pvid in my switch.
Also i deleted the bridge and its vlans and set them up directly from eth1. Now it works

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