Megaflow is an OpenVSwitch (OVS) feature than enables us to install flows for which some fields are wildcarded (the input port field is never wildcarded, as a totally wildcarded flow would be of little use). We do this by providing OVS with a flow mask upon creating a new flow. A mask is comprised of a subset of the flow's keys, where each field is either 0 or ~0, respectively specifying a wildcard or an exact match; the absence of a mask key is considered a total wildcard of all the fields in the flow's corresponding key.

We calculate the mask of a flow by keeping track throughout the simulation of which fields have contributed to that outcome and which have not. This last set of fields can be wildcarded while the previous requires an exact match. A field is considered seen, and thus an exact match in the flow mask, when we call the respective getter in the FlowMatch class. The mask is calculated by the FlowMask class and is triggered by the Flow class, before we serialize it to the datapath.

We don't store the flow mask in user space: flow deletion is done by specifying the flow's specific keys. The OVS module will apply all the masks it knows about to the specified flow and will remove all flows that match the result. This is also how flow lookup is performed. Note that the onus is on us to ensure we don't create overlapping, conflicting wildcarded flows: no guarantees are given as to which flow gets picked when different ones match an incoming packet.

We detect the version of the underlying OVS kernel module and suppress flow masks if megaflow is not supported.

[Mark] openvswitch megaflow的更多相关文章

  1. Openvswitch原理与代码分析(4):网络包的处理过程

      在上一节提到,Openvswitch的内核模块openvswitch.ko会在网卡上注册一个函数netdev_frame_hook,每当有网络包到达网卡的时候,这个函数就会被调用.   stati ...

  2. Openvswitch手册(1): 架构,SSL, Manager, Bridge

    Openvswitch是一个virutal swtich, 支持Open Flow协议,当然也有一些硬件Switch也支持Open Flow协议,他们都可以被统一的Controller管理,从而实现物 ...

  3. OpenvSwitch/OpenFlow 架构解析与实践案例

    目录 文章目录 目录 前言 软件定义网络(SDN) 虚拟交换机(vSwitch) 为什么说云计算时代的 SDN 非常重要 OpenFlow 简介 Open vSwitch Open vSwitch 的 ...

  4. java.io.IOException: mark/reset not supported

    java.io.IOException: mark/reset not supported at java.io.InputStream.reset(InputStream.java:348) at ...

  5. [mark] 使用Sublime Text 2时如何将Tab配置为4个空格

    在Mac OS X系统下,Sublime Text是一款比较赞的编辑器. 作为空格党的自觉,今天mark一下使用Sublime Text 2时如何将Tab配置为4个空格: 方法来自以下两个链接: ht ...

  6. 特邀美国EMC实战专家Mark来华授课

    “轻松搞定EMC-PCB和系统设计”课程介绍 本次课程特邀美国EMC领域权威专家Mark Montrose主讲,将涵盖满足产品电磁兼容性和信号完整性的基本原理.课程涉及多个领域,不仅仅针对PCB设计, ...

  7. 如何撤销 PhpStorm/Clion 等 JetBrains 产品的 “Mark as Plain Text” 操作 ?

    当把某个文件“Mark as Plain Text”时,该文件被当做普通文本,就不会有“代码自动完成提示”功能,如下图所示: 但是呢,右键菜单中貌似没有 相应的撤销 操作, 即使是把它删除,再新建一个 ...

  8. 使用openvswitch 和dnsmasq来实现虚拟机网络隔离

    openvswicth : 开源的网络虚拟化软件,可以划分vlan隔离虚拟机,做流量控制 dnsmasq:小心的dns,dhcp服务器 安装openvswicth wget  http://openv ...

  9. vim - mark

    Using markshttp://vim.wikia.com/wiki/Using_marks1. There is no visible indication of where marks are ...

随机推荐

  1. cp执行命令,如何直接覆盖不提示

    参数说明 -i, --interactive prompt before overwrite (overrides a previous -n option)   #文件存在是,交互式提示是否覆盖 - ...

  2. 安卓工程中定义的app_name等报错解决办法 工程上有叹号

    类似于"app_name" is not translated in af, am, ar, be, bg, ca, cs, da, de, el, en-rGB, es, es- ...

  3. [Q]无矩形外框块参照图形的识别

    该图纸的图框由块参照组成,其外侧图框不是矩形 使用默认设置无法正确识别,需要做以下修改:不勾选“块/外部参照”,勾选“块/外部参照边界”,勾选“制定块”并选择图框(块参照).

  4. IIS 和 各个协议

    1,IIS是Internet information service是internet信息服务的简写,它支持三大服务器,WWW,FTP,SMTP(简单Mail传输协议): 2,NNTP(网络新闻传输协 ...

  5. jetbrain phpstorm 增加或删除一个 live template

    打开\.PhpStorm2016.2\config\templates 将xml文件放入该文件夹中 重启! 单独: setting -> editor -> Live Template +

  6. javascript和jquery比较中学习

    获取input的值: document.getElementById("id").value;这里查的是input的name属性 $('input').val(); 设置input ...

  7. ng-Directive

    伪代码: var myModule = angular.module(...); myModule.directive('namespaceDirectiveName', function facto ...

  8. OOP的方法

    <?php class Computer{ //我要创建一个构造方法 public function __construct(){ echo '我是比较先进的构造方法!'; //构造方法一般用于 ...

  9. libimobiledevice命令

    Mac 安装 1. 安装HomeBrew ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/m ...

  10. Android:View颤抖的动画效果代码

    public void propertyValuesHolderDown(final View view) { PropertyValuesHolder pvhX = PropertyValuesHo ...