Community discussions

MikroTik App
 
silviub
newbie
Topic Author
Posts: 38
Joined: Tue May 14, 2024 3:45 pm

MVRP usage

Sun Jun 02, 2024 11:53 am

Hello,

I saw some posts of people asking for MVRP. Now, I do see the usage of this protocol if you're not in an all Mikrotik environment. But my question is: how does this help in an all Mikrotik environment? I mean, on Mikrotik, you have to "define" the VLAN and add the tagged/untagged ports to it. This means that, having MVRP propagate VLANs across devices doesn't really do much, except adding the trunk ports to those VLANs as tagged. Am I missing something?

What I mean:
I've got two switches, connected via ether1
On the first device I defined:
/interface/bridge/add name=test vlan-filtering=yes pvid=1 mvrp=yes
/interface/bridge/port add bridge=test interface=ether1 pvid=1
/interface/bridge/vlan add bridge=test vlan-ids=10,20 tagged=test,ether1
On the 2nd switch (after creating the bridge and adding the port to it) I do see VLAN1, 10 and 20, but the only port that's tagged to that VLAN is ether1 (which is normal) so, if I want to add another port to VLAN 10, let's say ether2, as untagged, I'd have to run:
/interface/bridge/vlan add bridge=test vlan-ids=10 tagged=test,ether1, untagged=ether2
So while MVRP is useful in environments where not all the devices are Mikrotiks, I fail to see how it helps in all-Mikrotik environments.
Also, a related question: from what I know/tested/worked with, in order to be able to use a VLAN in a bridge, you'd have to have that bridge as a tagged port. Since MVRP only adds the ether1 as tagged, I can't really use it in the bridge unless I manually define it, right? Output of
/interface/bridge/vlan print
on Sw02 - the one with no defined VLANs on it:
[admin@Sw02] > /interface/bridge/vlan/print
Flags: D - DYNAMIC
Columns: BRIDGE, VLAN-IDS, CURRENT-TAGGED, CURRENT-UNTAGGED
#   BRIDGE  VLAN-IDS  CURRENT-TAGGED  CURRENT-UNTAGGED
0 D test           1                  test
                                      ether1
1 D test          10  ether1
                  20
This means that even if I run
# --- Sw01 --- 
[admin@Sw01] > # Set ether2 as untagged via VLAN10 - a pc is connected here
[admin@Sw01] > /interface/bridge/port add bridge=test pvid=10 interface=ether2
# --- Sw02 ---
[admin@Sw02] > # Set ether2 as untagged via VLAN10 - a pc is connected here
[admin@Sw02] > /interface/bridge/port add bridge=test pvid=10 interface=ether2
I wouldn't be able to reach the device connected in Sw01-ether2 from a device connected in Sw02-ether2, right?

Please, don't take this post as a "bashing" or something. I am really failing to understand how people use MVRP in environments where all the switches/routers are Mikrotik devices.
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 13126
Joined: Thu Mar 03, 2016 10:23 pm

Re: MVRP usage

Sun Jun 02, 2024 3:25 pm

The basic logic behind VLANs is that ports are either trunk (carrying many/all VLANs tagged and optionally one - native - untagged) or access (carrying one VLAN untagged). It's clear that for the later some nanual config is necessary, somebody has to decide for a port of which VLANs (available) it's going to be a member. Not sure how MVRP could help here?

For trunk ports (interconnecting switches) MVRP is useful as it automatically adds any VLAN newly introduced on one of member switches.

So in your particular case: if you add another VLAN on one of switches (e.g. access port to VLAN 666), you don't have to configure trunk port explicitly ... on both switches. If you had a third switch, connected to one of existing switches with a trunk port with mvrp=yes, VLANs would "propagate" between all switches.

And that's the extent of "magic" you can expect to happen.
 
silviub
newbie
Topic Author
Posts: 38
Joined: Tue May 14, 2024 3:45 pm

Re: MVRP usage

Sun Jun 02, 2024 8:42 pm

The basic logic behind VLANs is that ports are either trunk (carrying many/all VLANs tagged and optionally one - native - untagged) or access (carrying one VLAN untagged). It's clear that for the later some nanual config is necessary, somebody has to decide for a port of which VLANs (available) it's going to be a member. Not sure how MVRP could help here?

For trunk ports (interconnecting switches) MVRP is useful as it automatically adds any VLAN newly introduced on one of member switches.

So in your particular case: if you add another VLAN on one of switches (e.g. access port to VLAN 666), you don't have to configure trunk port explicitly ... on both switches. If you had a third switch, connected to one of existing switches with a trunk port with mvrp=yes, VLANs would "propagate" between all switches.

And that's the extent of "magic" you can expect to happen.
Well yes, but if I have three switches, let's say, Sw01, 02 and 03, and I define the bridges on all of them with vlan filtering and mvrp, I define the VLANs on Sw01, I do get the VLANs on the 2nd switch, but as I said, the only tagged interface for those VLANs will be the connection to Sw01. Now, if Sw03 is connected to Sw02, will it propagate the VLANs to Sw03, right? But the "issue" still exists, in terms of not being able to really use the VLAN with an untagged port, until I also tag the bridge for that VLAN, right?

Thank you!

P.S. I just used GNS3 to simulate this, three chained switches, all with a bridge, mvrp on and defining the VLANs on the first switch will propagate them to all other switches. The issue is that, even if I have an VLAN interface on the bridge, I can't reach it until I set the bridge as tagged for that specific VLAN. I think it would be great to automatically add the bridge as tagged...? This way, if for example, I have VLAN10 defined on the first switch, and VLAN ID 10 interfaces defined on Sw02 and Sw03, I could reach those interfaces by just adding the VLAN to MVRP.
 
User avatar
Larsa
Forum Guru
Forum Guru
Posts: 1651
Joined: Sat Aug 29, 2015 7:40 pm
Location: The North Pole, Santa's Workshop

Re: MVRP usage

Sun Jun 02, 2024 11:15 pm

MVRP and similar protocols are often used in SDN switches to manage VLANs in virtual environments.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 22202
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: MVRP usage

Mon Jun 03, 2024 2:19 am

The point being its a trunk port to trunk port activity.
It does nothing to change the fact that one would have to manually untag the vlan for any specific port on a switch
 
User avatar
nichky
Forum Guru
Forum Guru
Posts: 1397
Joined: Tue Jun 23, 2015 2:35 pm

Re: MVRP usage

Mon Jun 03, 2024 4:42 am

with other words what mvrp-registrar-state does?

Not sure if i understadse the explanation on the wiki.
 
silviub
newbie
Topic Author
Posts: 38
Joined: Tue May 14, 2024 3:45 pm

Re: MVRP usage

Mon Jun 03, 2024 6:43 am

with other words what mvrp-registrar-state does?

Not sure if i understadse the explanation on the wiki.
From https://help.mikrotik.com/docs/display/ ... +Switching
MVRP registrar options:
fixed - port ignores all MRP messages, and remains Registered (IN) in all configured vlans.
normal - port receives MRP messages and handles them according to the standard.
---
It does nothing to change the fact that one would have to manually untag the vlan for any specific port on a switch
Untag the port and tag the bridge, I guess?
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 13126
Joined: Thu Mar 03, 2016 10:23 pm

Re: MVRP usage

Mon Jun 03, 2024 9:01 am

It does nothing to change the fact that one would have to manually untag the vlan for any specific port on a switch
Untag the port and tag the bridge, I guess?
[/quote]


Setting bridge as tagged/untagged under /interface/bridge/vlan doesn't affect functionality of bridge the switch-like entity, it affects the bridge CPU-facing bridge port (check this excellent explanation of different bridge personalities).

The above has the same effect as setting VID/PVID on any other (physical) bridge port. So per-se it doesn't affect the way MVRP operates.
 
silviub
newbie
Topic Author
Posts: 38
Joined: Tue May 14, 2024 3:45 pm

Re: MVRP usage

Mon Jun 03, 2024 9:40 am

Setting bridge as tagged/untagged under /interface/bridge/vlan doesn't affect functionality of bridge the switch-like entity, it affects the bridge CPU-facing bridge port (check this excellent explanation of different bridge personalities).
I have read the above document a few times and I still don't get it... ? What I kind of understood is that you don't really need to add the Bridge as tagged, unless you want to have a Layer 3 (vlan interface) in that bridge? Is that correct?

Thank you!
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 13126
Joined: Thu Mar 03, 2016 10:23 pm

Re: MVRP usage  [SOLVED]

Mon Jun 03, 2024 11:12 am

What I kind of understood is that you don't really need to add the Bridge as tagged, unless you want to have a Layer 3 (vlan interface) in that bridge? Is that correct?

Exactly.
Bridge port can be also set as untagged member of one VLAN by setting pvid property on bridge (the confusing part is that it's done under /interface/bridge, so it may seem as if this was some kind of "magic" property of the bridge - switch like entity, but in reailty it's about bridge CPU facing port).
 
silviub
newbie
Topic Author
Posts: 38
Joined: Tue May 14, 2024 3:45 pm

Re: MVRP usage

Mon Jun 03, 2024 2:20 pm

I appreciate all the help! Finally understood why the bridge "needs" to be tagged/untagged and how MVRP should be used.

Thank you guys!