• Linux openvswitch性能调优


    Increasing the flow-eviction threshold

    The threshold is a type of limit on the number of flows that are cached in the kernel. OVS will handle as many flows as can be processed through ovs-vswitchd.

    If the number of newly created connections reaches this limit, in a 5 second window, OvS attempts to keep the memory consumption under the limit by evicting older flow entries.

    It is possible to increase this flow-eviction threshold. This is the recommended first step to resolve issues related to the number and frequency of flow entries being created,

    To set the flow-eviction-threshold enter the following:
    ovs-vsctl set bridge <bridgename> other-config:flow-eviction-threshold=<new value>

    To query whether the flow-eviction-threshold was set explicitly:
    ovs-vsctl get bridge <bridgename> other-config:flow-eviction-threshold

    Customers can use the active flow-eviction-threshold value to evaluate the current number of active flows by using the following command:
    watch -n 1 ovs-dpctl show

    This command prints out the bridge statistics every second, until the process is ended.

    The flows counter displays the actual number of current flow entries. If the number of flows approaches the flow-eviction-threshold, OvS has to deal with a lot of flow creations and deletions. In this case increasing the flow-eviction-threshold should help address the issue.

    Increase idleTimeout & hardTimeout

    The idleTimeout is basically a value that determines how long a flow 
    in a switch will last if it doesn't match any traffic.   So if I have 
    a flow in a switch with an idleTimeout of 5 seconds that matches all 
    ICMP traffic on a given switch port, then as long as ICMP traffic is 
    entering that switch port, that flow will continue to exist.  If no 
    ICMP traffic goes through the switch port for 5 seconds, the flow will 
    timeout, and it will be removed from the switch. 

    The hardTimeout, on the other hand, is a hard limit on how long a 
    given flow can exist in the switch.  If I have a flow in a switch with 
    a hardTimeout of 5 seconds that matches all ICMP traffic on a given 
    switch port, then even if ICMP traffic is continuously entering the 
    switch port, that flow will time out after 5 seconds and it will be 
    removed from the switch. 

    "If both idle_timeout and hard_timeout are zero, the entry is 
    considered permanent and will never time out" 

    The idle age is simply how long the flow has not matched any packets. If the idle age is reported at 12, then that means the flow has not matched any packets in 12 seconds. This will be reset automatically back to zero by the switch as soon as the flow matches a packet. The idle age is what triggers an idle timeout if there is an idle timeout set.

  • 相关阅读:
    Cocos Creator 图集 (TexturePacker、自动图集功能 、压缩纹理)
    Cocos Creator 下载不同版本引擎
    Cocos Creator 源码 (位置,阅读、修改)
    Laya3D Unity商店免费下载3D资源使用(Unity插件支持哪些导出)
    三 Laya3D 加载资源 (场景/预设/模型网格/材质/动画文件/贴图/粒子)
    二 Laya3D github demo下载并使用
    一 Laya3D Unity下载和插件安装
    AndroidUI设计之布局-详细解析布局实现
    Android 监听ScrollView的滑动
    【Android进阶】Android程序与JavaScript之间的简单调用
  • 原文地址:https://www.cnblogs.com/scottieyuyang/p/5683656.html
Copyright © 2020-2023  润新知