What i want:
eth1 = wan with dhcp client + incoming tagged vlan2
eth2 = untagged vlan2
How do i accomplish this with switch vlan functions instead of bridge vlan?
I have no problem doing it with /interface vlan and /bridge but that uses cpu instead of switch.
/HW
Add VLAN
/int vl add vlan-id=2 name=vlan2 interface=ether2
Add VLAN in switching table
/int ethernet switch vlan
add vlan-id=2 ports=switch1-cpu,ether2 switch=switch1
Set to untagged on ether2
/int ethernet switch port
set ether2 default-vlan-id=2 vlan-header=always-strip vlan-mode=secure
I didn't test the commands, but it should work.
That menas? Export configuration, post error messages, …
I will do what but meanwhile look at your config, is it really complete? There is nothing telling eth1 what to do with the incoming vlan2…
This is the working solution:
/interface ethernet switch port
set eth1 default-vlan-id=2 vlan-header=add-if-missing vlan-mode=secure
set eth2 default-vlan-id=2 vlan-header=always-strip vlan-mode=secure
/interface ethernet switch vlan
add ports=eth1,eth2 switch=switch1 vlan-id=2
Simple as that. What i did wrong was NOT to add eth2 to vlan2 since i wanted it untagged. Its supposed to belong to 2 but “always-strip”, so it becomes untagged.
Also the ports shoult be master-slave connected.
/HW