Community discussions

MikroTik App
 
RainbowDash
just joined
Topic Author
Posts: 7
Joined: Wed Jan 13, 2021 3:10 pm

VLANs, trunk ports and vlan interfaces

Wed Apr 07, 2021 12:48 pm

Hi!

I could do this setup on Cisco in seconds, but I fail on RouterOS.

I have a CRS328-24S+2Q+RM switch running RouterOS 6.45.9

I try to setup the following:

- Port sfp-sfpplus24 is my uplink port, tagged VLANs should include all in range 1000-1100
- Ports sfp-sfpplus1-2 are downlink trunk ports, tagged VLAN 1111 (just one for the beginning)
- Ports sfp-sfpplus3-4 are downlink trunk ports, tagged VLAN 1121 (just one for the beginning)
- Have one VLAN interface on VLAN 1111 with an IP address for SSH access to the switch
- Have no untagged VLANs at all (no default VLAN 1 on all ports)

This is my config so far:
/interface bridge
add admin-mac=xx:xx:xx:xx:xx:xx auto-mac=no name=bridge
/interface vlan
add interface=bridge name=VLAN-1111 use-service-tag=yes vlan-id=1111
/interface bridge port
add bridge=bridge interface=sfp-sfpplus1
add bridge=bridge interface=sfp-sfpplus2
add bridge=bridge interface=sfp-sfpplus3
add bridge=bridge interface=sfp-sfpplus4
add bridge=bridge interface=sfp-sfpplus24
/interface bridge vlan
add bridge=bridge tagged=sfp-sfpplus1,sfp-sfpplus2,sfp-sfpplus24 vlan-ids=1111
add bridge=bridge tagged=sfp-sfpplus3,sfp-sfpplus4,sfp-sfpplus24 vlan-ids=1121
/ip address
add address=10.11.11.250/24 interface=VLAN-1111 network=10.252.11.0
/ip route
add distance=1 gateway=10.11.11.1
The IP address is not pingable and I don't know how to configure the VLAN range on sfp-sfpplus24...
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19099
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: VLANs, trunk ports and vlan interfaces

Wed Apr 07, 2021 2:16 pm

viewtopic.php?f=23&t=143620

Obviously CISCO is obsolete then! ;-)

Also, hot off the press.....
https://www.youtube.com/watch?v=v9GBZMmMBYA.
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11433
Joined: Thu Mar 03, 2016 10:23 pm

Re: VLANs, trunk ports and vlan interfaces

Wed Apr 07, 2021 3:14 pm

/interface vlan
add interface=bridge name=VLAN-1111 use-service-tag=yes vlan-id=1111

The setting I highlited is toggle between using 802.1q ("usual" VLAN) and 802.1ad ("QinQ" VLAN). Most users want to use 802.1q tags and corresponding setting is use-service-tag=no (which is default and thus not show in textual exports).

Another thing is (missing) bridge setting of vlan-filtering=yes under /interface bridge. Without it, bridge won't do anything about VLAN tags and will behave as dumb switch ... in your particular case (with all ports trunk) it wouldn't actually make any difference apart from the fact that VLANs would "bleed" all over the place. OTOH if you wanted to use access port or hybrid port (in Cisco world that's trunk with native VLAN), it wouldn't work as ports would not tag/untag frames when passing it.
 
RainbowDash
just joined
Topic Author
Posts: 7
Joined: Wed Jan 13, 2021 3:10 pm

Re: VLANs, trunk ports and vlan interfaces

Wed Apr 07, 2021 9:36 pm

Thank you!

Works fine!

Who is online

Users browsing this forum: No registered users and 44 guests