Tagged wan and lan on AX3600

I have ssh access to a Xiaomi AX3600 based on openwrt. I need a port to be used as both wan (vlan tagged) and lan. The current configuration file is at the end of this post, which allows the use of the wan port without lan.

A curious thing is the fact that I configured the wan interface as tagged (option ifname 'eth1.6') but after /etc/init.d/network restart or reload it didn't take effect. So, I reboot the router and it worked BUT the configuration was changed automatically to (option ifname 'eth1') but the PPPoE connection is established. Maybe, the PPPoE is not required to be tagged on the unified router working as ONT.

The problem comes if I add eth1 to lan interface as "option ifname 'eth1 eth2 eth3 eth4' ", the bridge work as expected but the wan interfaces stops working, the PPPoE connection is not stablished.

Any clue about what is happening? and Is there any way to achieve a tagged wan and lan in the same port with the minor modfications?

Many thanks in advance.

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

config switch
	option name 'switch0'

config interface 'lan'
	option ifname 'eth2 eth3 eth4'
	option force_link '1'
	option type 'bridge'
	option proto 'static'
	option netmask '255.255.255.0'
	option ipv6 '0'
	option multicast_querier '0'
	option igmp_snooping '0'
	option macaddr '28:d1:27:4c:db:44'
	option ieee1905managed '1'
	option ipaddr '192.168.1.2'

config interface 'eth1'
	option ifname 'eth1.6'
	option keepup '1'

config interface 'wan'
	option proto 'pppoe'
	list dns '1.1.1.3'
	list dns '1.0.0.3'
	option mtu '1500'
	option peerdns '0'
	option username 'adslppp@telefonicanetpa'
	option special '0'
	option password 'adslppp'
	option ifname 'eth1'

config interface 'dhcp'
	option ifname 'eth1.6'
	option proto 'dhcp'

Delete these.

Fix this.

1 Like

I see,

I will try but, does bridging eth1.6 in the lan allow untagged traffic among eth1 and the other interfaces?

eth1.6 is sending tagged frames in vlan 6.
eth1 is sending untagged frames and is configured already as wan.

1 Like

What I need is untagged lan traffic (eth1) and tagged wan traffic (eth1.6). That is reason of code:

config interface 'dhcp'
	option ifname 'eth1.6'
	option proto 'dhcp'

The point is that I don't know why PPPoE is established after reboot. I think that it shoudn't (the ISP requires tagged traffic in VLAN 6). The reboot removes the desired setup fo the tag in the wan section (from eth1.6 to eth1 as it is seen in the original post). That is the reason why you sea the wan interface without the tag 6 :frowning: Rebooting the router changes de setup (the file itself) by removing the tag 6 but the PPPoE connection is stablished anyway.

Eth1 is already connected to some upstream modem and runs pppoe. Or do you have some managed switch on eth1 to separate the traffic?

It is directly connected to an upstream router in bridge mode acting as ONT

Then you don't have much control there.
Moreover what you mention here will not have any effect in your lan.

As eth1 interface is connected to the modem.

Maybe the modem is tagging it, if it is really a requirement from the ISP.
But let's take a step back and tell me what is it you are trying to achieve. Don't tell me that you want to bridge eth1 with eth1.6, tell me something like I want to connect one host on lan port eth3 to the wan on eth1.6.

The figure below is what I want to achieve. What I don't understand is why with current config after reboot PPPoE is untagged (forced by the router, I don't know why) but it connects with the ISP. ISP requires VLAN 6 link (Images are in English language). The link shows Askey 3505VW configuration.

router_cheme

config interface 'lan'
	option ifname 'eth1 eth2 eth3 eth4'
	option force_link '1'
	option type 'bridge'
	option proto 'static'
	option netmask '255.255.255.0'
	option ipv6 '0'
	option multicast_querier '0'
	option igmp_snooping '0'
	option macaddr '28:d1:27:4c:db:44'
	option ieee1905managed '1'
	option ipaddr '192.168.1.2'

config interface 'wan'
	option proto 'pppoe'
	list dns '1.1.1.3'
	list dns '1.0.0.3'
	option mtu '1500'
	option peerdns '0'
	option username 'adslppp@telefonicanetpa'
	option special '0'
	option password 'adslppp'
	option ifname 'eth1'

config interface 'dhcp'
	option ifname 'eth1.6 eth2.6 eth3.6 eth4.6'
	option type 'bridge'
	option proto 'dhcp'

This is what I understand from the diagram.
However you need to make sure the 3505 has switched off dhcp server and accepts tagged frames on its lan ports.

1 Like

I will test it, it make sense, let see if it works. However, Is it normal to have untagged the PPPoE dialog traffic (link establishment) to later tag the traffic trough the interface configured with PPPoE?