VLAN help - FibreOp


I'm switching from a Asus RT-N66U running Tomato to a WRT32X running OpenWrt (18.06.1). In my current configuration I have 3 vlan used by my ISP. I have tried to replicate the configuration but I have been unabled.

This is what I currently have:

Though not familiar with the UI you've shown, it looks like it is 35 that is the VLAN tag (VID) in use for the 3rd VLAN configured.

It looks like your modem supplies Internet on VLAN 35 and some proprietary service such as TV on VLAN 34, which you just want to pass through the hardware switch to a proprietary box on Ethernet port 4.

The OpenWrt switch page is similar though when you want a VLAN to be usable by a network in the router's CPU, it is set up in two places. First you would switch it to the CPU port tagged. Then go to the network configuration and select the VLAN in the physical settings with the notation eth0.X (or maybe eth1.X if there are multiple CPU ports.)

The OpenWrt wiki page for the device should be consulted to confirm logical port numbering and CPU assignments. The port numbers on the setup page don't always correspond with the numbers the manufacturer marked on the ports and LEDs.

The issue I have is that this new router has 2x CPU (eth0, eth1) and no bridging or default interface. could someone help me configure my new WRT32x running OpenWrt please? I have tried a few configuration but I could not get it to work.

This is where I'm currently at... but my wan interface it unable to get a ip from the ISP

In your wan interface settings are you telling it to use eth0.34 or 35 as the case may be.

There is no link shown on the WAN port. Is the modem plugged in to it?

The CPU ports always show linked at 1000 because that hardware is permanently connected.

Yes as @dlakelan said, you need to go to Network--Interfaces--WAN--Physical Settings and select eth0.35. If the WAN is pppoe you also need to configure that.

The Tomato configuration you posted has no CPU connection to VLAN 34. That will not make a difference in operation but you should do that with your final configuration so the router CPU doesn't waste time receiving IPTV traffic only to ignore it.

Some router switches do not support VLAN numbers higher than 16 without special manual configuration, but I doubt the WRT32x is one of those. The gigabit switch chips are usually usable up to at least 128.

I managed to get the internet working on VLAN35, now the problem I have is that VLAN34 seems to be on the same network as VLAN36. That's the TV VLAN where the provider assigns the IP to the Top Box. So It should not be on my network.

I have port 4 configured as VLAN34 but it's still getting a IP from the DHCP on VLAN3601%20PM

Under Network > Interface > Lan, I see that it's assigned to the Switch VLAN eth0.36 and the 3x built in wireless network (eth0,36, radio0.network1, wlan1, radio2.network1.

What am I missing?

Here are my config files:


config interface 'loopback'                                                                                                                   
        option ifname 'lo'                                                                                                                    
        option proto 'static'                                                                                                                 
        option ipaddr ''                                                                                                             
        option netmask ''                                                                                                            
config globals 'globals'                                                                                                                      
        option ula_prefix 'fdbf:f701:5a61::/48'                                                                                               
config interface 'lan'                                                                                                                        
        option type 'bridge'                                                                                                                  
        option proto 'static'                                                                                                                 
        option ipaddr ''                                                                                                           
        option netmask ''                                                                                                        
        option ip6assign '60'                                                                                                                 
        option ifname 'eth0.36'                                                                                                               
config interface 'wan'                                                                                                                        
        option proto 'dhcp'                                                                                                                   
        option ifname 'eth1.35'                                                                                                               
        option macaddr 'A8:39:44:88:C2:62'                                                                                                    
config interface 'wan6'                                                                                                                       
        option proto 'dhcpv6'                                                                                                                 
        option ifname 'eth1.35'                                                                                                               
config switch                                                                                                                                 
        option name 'switch0'                                                                                                                 
        option reset '1'                                                                                                                      
        option enable_vlan '1'                                                                                                                
config switch_vlan                                                                                                                            
        option device 'switch0'                                                                                                               
        option vlan '1'                                                                                                                       
        option ports '0 1 2t 3 5t'                                                                                                            
        option vid '36'                                                                                                                       
config switch_vlan                                                                                                                            
        option device 'switch0'                                                                                                               
        option vlan '2'                                                                                                                       
        option vid '35'                                                                                                                       
        option ports '4t 6t'                                                                                                                  
config switch_vlan                                                                                                                            
        option device 'switch0'                                                                                                               
        option vlan '3'                                                                                                                       
        option vid '34'                                                                                                                       
        option ports '0t'


config dnsmasq
        option domainneeded '1'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'
        option logqueries '1'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv6 'server'
        option ra 'server'

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

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

If port 4 is exclusively for TV don't add it to any other vlan.

But how would would the traffic be tag as vlan34 and router to the wan?

You have the port untagged in 36, get rid of that and just make it tagged for 34, or untagged for 34 whichever is needed with your TV box. You will not route 34 through the router, just bridge it in the switch.

Yes change LAN4 from "untagged" to "off" in VLAN36. In general, it is seldom desirable to have untagged and tagged packets on the same port.

As @dlakelan said, the hardware switch will see packets related to the TV service on VLAN 34 and forward them directly between the TV box and the modem. The router CPU should never need to communicate with the TV box.