Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support to VLAN range #18

Closed
ajoaoff opened this issue Jun 8, 2021 · 2 comments · Fixed by #407
Closed

Add support to VLAN range #18

ajoaoff opened this issue Jun 8, 2021 · 2 comments · Fixed by #407
Assignees
Labels
epic_mef_eline_vlan_range mef_eline VLAN range

Comments

@ajoaoff
Copy link

ajoaoff commented Jun 8, 2021

Original issue opened by @italovalcy at kytos#241.

Starting on OpenFlow 1.2, many matching fields started to support the usage of field value + mask (sometimes called Bitwise match). In other words, specific bits in the field must have specified values; for example, only source IP addresses in a particular subnet (e.g., nw_src=10.1.0.0/255.255.0.0 means that the OF rule will match 10.1.0.1 and also 10.1.24.252, etc).

The VLAN_id field supports Mask and that can be used to define matches for "VLAN range". Accordingly, instead of having N OpenFlow rules for matching N vlans, range matches can be expressed as a collection of bitwise matches and end up with Z<=N flows (Z tends to be much lower than N, but the worst case they will be equal). For example, let's say that you want to create EVCs for VLANs from 1000 to 1023, the standard way of doing so is by creating 24 rules with matches including:

vlan_id=1000,
vlan_id=1001,
...
vlan_id=1023,

However, using bitwise matches, you can define this with only 2 flows:

vlan_id=0x03e8/0xfff8
vlan_id=0x03f0/0xfff0

@ajoaoff
Copy link
Author

ajoaoff commented Dec 1, 2021

@italovalcy I was reviewing this issue and was thinking about a use case. Let's say we want to create an EVC between endpoints A and B. For endpoint A we define a range of vlans, 1008 to 1023 and for endpoint B, 2000 to 2015. When creating the flows from A to B, we can use one flow to match all the vlans. If we use that one flow, the action will have just one vlan, so when it reaches the switch where B belongs, the flow there will send the packet to the port defined by endpoint B on one fixed vlan. Is that the desired behavior?

@viniarck
Copy link
Member

viniarck commented Feb 9, 2023

cc'ing @Alopalao and @gretelliz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epic_mef_eline_vlan_range mef_eline VLAN range
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants