V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
shom
V2EX  ›  Linux

Linux 下 lacp bond 模式的疑问

  •  
  •   shom ·
    shom · 2017-04-24 08:08:39 +08:00 · 5664 次点击
    这是一个创建于 2767 天前的主题,其中的信息可能已经有所发展或是发生改变。
    Transmit Hash Policy 无论是 layer2 layer2+3 layer3+4 流量只走端口 1 ,如果有另一台设备连接才会走端口 2
    我想问一下是哪里配置错了吗?

    Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)

    Bonding Mode: IEEE 802.3ad Dynamic link aggregation
    Transmit Hash Policy: layer2+3 (2)
    MII Status: up
    MII Polling Interval (ms): 100
    Up Delay (ms): 0
    Down Delay (ms): 0

    802.3ad info
    LACP rate: fast
    Min links: 0
    Aggregator selection policy (ad_select): stable
    System priority: 65535
    System MAC address: 1c:98:ec:0e:11:08
    Active Aggregator Info:
    Aggregator ID: 1
    Number of ports: 2
    Actor Key: 9
    Partner Key: 77
    Partner Mac Address: 80:c1:6e:d0:b4:f0

    Slave Interface: eno1
    MII Status: up
    Speed: 1000 Mbps
    Duplex: full
    Link Failure Count: 1
    Permanent HW addr: 1c:98:ec:0e:11:08
    Slave queue ID: 0
    Aggregator ID: 1
    Actor Churn State: none
    Partner Churn State: none
    Actor Churned Count: 0
    Partner Churned Count: 0
    details actor lacp pdu:
    system priority: 65535
    system mac address: 1c:98:ec:0e:11:08
    port key: 9
    port priority: 255
    port number: 1
    port state: 63
    details partner lacp pdu:
    system priority: 46320
    system mac address: 80:c1:6e:d0:b4:f0
    oper key: 77
    port priority: 0
    port number: 1
    port state: 61

    Slave Interface: eno2
    MII Status: up
    Speed: 1000 Mbps
    Duplex: full
    Link Failure Count: 1
    Permanent HW addr: 1c:98:ec:0e:11:09
    Slave queue ID: 0
    Aggregator ID: 1
    Actor Churn State: none
    Partner Churn State: none
    Actor Churned Count: 0
    Partner Churned Count: 0
    details actor lacp pdu:
    system priority: 65535
    system mac address: 1c:98:ec:0e:11:08
    port key: 9
    port priority: 255
    port number: 2
    port state: 63
    details partner lacp pdu:
    system priority: 46320
    system mac address: 80:c1:6e:d0:b4:f0
    oper key: 77
    port priority: 0
    port number: 2
    port state: 61
    3 条回复    2017-04-24 12:40:15 +08:00
    ceyes
        1
    ceyes  
       2017-04-24 10:26:00 +08:00
    是怎么“确认”流量只走端口 1 的呢?
    记得一个 TCP stream 是不会被分发到多个 NIC 上的,始终走同一个 NIC (我认为不然的话开销太大,得不偿失)。
    你试试多个 TCP stream ,多个不同的目标地址。

    Ref:
    - https://serverfault.com/questions/569721/can-bonding-2-interfaces-double-the-speed
    - https://serverfault.com/questions/569060/link-aggregation-lacp-802-3ad-max-throughput/569125#569125
    shom
        2
    shom  
    OP
       2017-04-24 12:24:24 +08:00
    @ceyes HP 的交换机 web 界面可以看每个端口的流量,用 iperf 测试的;同样的物理连接 Linux 下配置 mode=0(balance-rr)是可以正常负载均衡的
    shom
        3
    shom  
    OP
       2017-04-24 12:40:15 +08:00
    @ceyes 看来是我对 LACP 的理解有点问题(捂脸中)
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   5558 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 24ms · UTC 01:33 · PVG 09:33 · LAX 17:33 · JFK 20:33
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.