diff options
author | Ben Pfaff <blp@ovn.org> | 2020-06-17 14:16:08 -0700 |
---|---|---|
committer | Ben Pfaff <blp@ovn.org> | 2020-10-21 11:28:24 -0700 |
commit | 91fc374a9c5a2a4d9520aaa3588a7a18338a476e (patch) | |
tree | 36e097d0f7b655e90179c04e21eb7fe4c400889b /tests | |
parent | f51cf36d86e4a51630dc2781034149c13a634d67 (diff) | |
download | openvswitch-91fc374a9c5a2a4d9520aaa3588a7a18338a476e.tar.gz |
Eliminate use of term "slave" in bond, LACP, and bundle contexts.
The new term is "member".
Most of these changes should not change user-visible behavior. One
place where they do is in "ovs-ofctl dump-flows", which will now output
"members:..." inside "bundle" actions instead of "slaves:...". I don't
expect this to cause real problems in most systems. The old syntax
is still supported on input for backward compatibility.
Signed-off-by: Ben Pfaff <blp@ovn.org>
Acked-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/bundle.at | 48 | ||||
-rw-r--r-- | tests/lacp.at | 146 | ||||
-rw-r--r-- | tests/ofp-actions.at | 28 | ||||
-rw-r--r-- | tests/ofproto-dpif.at | 100 | ||||
-rw-r--r-- | tests/ofproto.at | 4 | ||||
-rw-r--r-- | tests/ovs-ofctl.at | 56 | ||||
-rw-r--r-- | tests/test-bundle.c | 112 |
7 files changed, 247 insertions, 247 deletions
diff --git a/tests/bundle.at b/tests/bundle.at index 0a4eadc1e..2c2396cb8 100644 --- a/tests/bundle.at +++ b/tests/bundle.at @@ -9,7 +9,7 @@ AT_BANNER([bundle link selection]) AT_SETUP([hrw bundle link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],slaves:1,2,3,4,5']], +AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],members:1,2,3,4,5']], [0], [ignore]) # 100000: disruption=1.00 (perfect=1.00) 1.00 0.00 0.00 0.00 0.00 0.00 # 110000: disruption=0.50 (perfect=0.50) 0.50 0.50 0.00 0.00 0.00 0.00 @@ -80,7 +80,7 @@ AT_CLEANUP AT_SETUP([active_backup bundle link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,active_backup,ofport,NXM_NX_REG0[],slaves:1,2,3,4,5,6']], +AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,active_backup,ofport,NXM_NX_REG0[],members:1,2,3,4,5,6']], [0], [100000: disruption=1.00 (perfect=1.00) 1.00 0.00 0.00 0.00 0.00 0.00 110000: disruption=0.00 (perfect=0.00) 1.00 0.00 0.00 0.00 0.00 0.00 @@ -152,7 +152,7 @@ AT_CLEANUP AT_SETUP([hrw bundle single link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],slaves:1']], +AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],members:1']], [0], [ignore]) # 1: disruption=1.00 (perfect=1.00) 1.00 # 0: disruption=1.00 (perfect=1.00) 0.00 @@ -161,7 +161,7 @@ AT_CLEANUP AT_SETUP([hrw bundle no link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],slaves:']], +AT_CHECK([[ovstest test-bundle 'symmetric_l4,60,hrw,ofport,NXM_NX_REG0[],members:']], [0], [ignore]) AT_CLEANUP #: disruption=0.00 (perfect=0.00) @@ -176,29 +176,29 @@ AT_CLEANUP AT_SETUP([bundle action bad fields]) AT_KEYWORDS([bundle_action]) -AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(xyzzy,60,hrw,ofport,slaves:1,2))'], [1], [], - [ovs-ofctl: xyzzy,60,hrw,ofport,slaves:1,2: unknown fields `xyzzy' +AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(xyzzy,60,hrw,ofport,members:1,2))'], [1], [], + [ovs-ofctl: xyzzy,60,hrw,ofport,members:1,2: unknown fields `xyzzy' ]) AT_CLEANUP AT_SETUP([bundle action bad algorithm]) AT_KEYWORDS([bundle_action]) -AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(symmetric_l4,60,fubar,ofport,slaves:1,2))'], [1], [], - [ovs-ofctl: symmetric_l4,60,fubar,ofport,slaves:1,2: unknown algorithm `fubar' +AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(symmetric_l4,60,fubar,ofport,members:1,2))'], [1], [], + [ovs-ofctl: symmetric_l4,60,fubar,ofport,members:1,2: unknown algorithm `fubar' ]) AT_CLEANUP -AT_SETUP([bundle action bad slave type]) +AT_SETUP([bundle action bad member type]) AT_KEYWORDS([bundle_action]) -AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(symmetric_l4,60,hrw,robot,slaves:1,2))'], [1], [], - [ovs-ofctl: symmetric_l4,60,hrw,robot,slaves:1,2: unknown slave_type `robot' +AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(symmetric_l4,60,hrw,robot,members:1,2))'], [1], [], + [ovs-ofctl: symmetric_l4,60,hrw,robot,members:1,2: unknown member_type `robot' ]) AT_CLEANUP -AT_SETUP([bundle action bad slave delimiter]) +AT_SETUP([bundle action bad member delimiter]) AT_KEYWORDS([bundle_action]) AT_CHECK([ovs-ofctl parse-flow 'actions=bundle(symmetric_l4,60,hrw,ofport,robot:1,2))'], [1], [], - [ovs-ofctl: symmetric_l4,60,hrw,ofport,robot:1,2: missing slave delimiter, expected `slaves' got `robot' + [ovs-ofctl: symmetric_l4,60,hrw,ofport,robot:1,2: missing member delimiter, expected `members', got `robot' ]) AT_CLEANUP @@ -211,9 +211,9 @@ dnl Valgrind warnings for use-after-free bugs. AT_SETUP([bundle action with many ports]) AT_KEYWORDS([bundle_action]) OVS_VSWITCHD_START -AT_CHECK([ovs-ofctl add-flow br0 'actions=set_field:0x1->metadata,set_field:0x2->metadata,set_field:0x3->metadata,set_field:0x4->metadata,bundle(symmetric_l4,0,hrw,ofport,slaves:[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]])']) +AT_CHECK([ovs-ofctl add-flow br0 'actions=set_field:0x1->metadata,set_field:0x2->metadata,set_field:0x3->metadata,set_field:0x4->metadata,bundle(symmetric_l4,0,hrw,ofport,members:[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]])']) AT_CHECK([ovs-ofctl dump-flows br0 --no-stats], [0], [dnl - actions=load:0x1->OXM_OF_METADATA[[]],load:0x2->OXM_OF_METADATA[[]],load:0x3->OXM_OF_METADATA[[]],load:0x4->OXM_OF_METADATA[[]],bundle(symmetric_l4,0,hrw,ofport,slaves:1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40) + actions=load:0x1->OXM_OF_METADATA[[]],load:0x2->OXM_OF_METADATA[[]],load:0x3->OXM_OF_METADATA[[]],load:0x4->OXM_OF_METADATA[[]],bundle(symmetric_l4,0,hrw,ofport,members:1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40) ]) OVS_VSWITCHD_STOP AT_CLEANUP @@ -226,7 +226,7 @@ OVS_VSWITCHD_START([dnl add-port br0 p2 -- set Interface p2 type=dummy -- \ set Interface p2 ofport_request=2 ]) -AT_CHECK([ovs-ofctl add-flow br0 'actions=bundle(eth_src,50,active_backup,ofport,slaves:1,2)']) +AT_CHECK([ovs-ofctl add-flow br0 'actions=bundle(eth_src,50,active_backup,ofport,members:1,2)']) AT_CHECK([ovs-ofctl mod-port br0 p1 up]) AT_CHECK([ovs-ofctl mod-port br0 p2 up]) AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=LOCAL,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06'], [0], [stdout]) @@ -264,7 +264,7 @@ OVS_VSWITCHD_START([dnl add-port br0 p2 -- set Interface p2 type=dummy -- \ set Interface p2 ofport_request=2 ]) -AT_CHECK([ovs-ofctl add-flow br0 'actions=bundle_load(eth_src,50,hrw,ofport,OXM_OF_ETH_SRC[[0..15]],slaves:1,2)']) +AT_CHECK([ovs-ofctl add-flow br0 'actions=bundle_load(eth_src,50,hrw,ofport,OXM_OF_ETH_SRC[[0..15]],members:1,2)']) AT_CHECK([ovs-ofctl mod-port br0 p1 down]) AT_CHECK([ovs-ofctl mod-port br0 p2 down]) AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=LOCAL,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:06'], [0], [stdout]) @@ -276,7 +276,7 @@ AT_CLEANUP AT_SETUP([hrw bundle symmetric_l3 link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],slaves:1,2,3,4,5']], +AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],members:1,2,3,4,5']], [0], [ignore]) # 100000: disruption=1.00 (perfect=1.00) 1.00 0.00 0.00 0.00 0.00 0.00 # 110000: disruption=0.50 (perfect=0.50) 0.50 0.50 0.00 0.00 0.00 0.00 @@ -347,7 +347,7 @@ AT_CLEANUP AT_SETUP([active_backup bundle symmetric_l3 link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,active_backup,ofport,NXM_NX_REG0[],slaves:1,2,3,4,5,6']], +AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,active_backup,ofport,NXM_NX_REG0[],members:1,2,3,4,5,6']], [0], [100000: disruption=1.00 (perfect=1.00) 1.00 0.00 0.00 0.00 0.00 0.00 110000: disruption=0.00 (perfect=0.00) 1.00 0.00 0.00 0.00 0.00 0.00 @@ -419,7 +419,7 @@ AT_CLEANUP AT_SETUP([hrw bundle symmetric_l3 single link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],slaves:1']], +AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],members:1']], [0], [ignore]) # 1: disruption=1.00 (perfect=1.00) 1.00 # 0: disruption=1.00 (perfect=1.00) 0.00 @@ -428,7 +428,7 @@ AT_CLEANUP AT_SETUP([hrw bundle symmetric_l3 single link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],slaves:1']], +AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],members:1']], [0], [ignore]) # 1: disruption=1.00 (perfect=1.00) 1.00 # 0: disruption=1.00 (perfect=1.00) 0.00 @@ -437,7 +437,7 @@ AT_CLEANUP AT_SETUP([hrw bundle symmetric_l3 no link selection]) AT_KEYWORDS([bundle_action]) -AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],slaves:']], +AT_CHECK([[ovstest test-bundle 'symmetric_l3,60,hrw,ofport,NXM_NX_REG0[],members:']], [0], [ignore]) AT_CLEANUP #: disruption=0.00 (perfect=0.00) @@ -446,9 +446,9 @@ AT_CLEANUP AT_SETUP([bundle symmetric_l3 action with many ports]) AT_KEYWORDS([bundle_action]) OVS_VSWITCHD_START -AT_CHECK([ovs-ofctl add-flow br0 'actions=set_field:0x1->metadata,set_field:0x2->metadata,set_field:0x3->metadata,set_field:0x4->metadata,bundle(symmetric_l3,0,hrw,ofport,slaves:[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]])']) +AT_CHECK([ovs-ofctl add-flow br0 'actions=set_field:0x1->metadata,set_field:0x2->metadata,set_field:0x3->metadata,set_field:0x4->metadata,bundle(symmetric_l3,0,hrw,ofport,members:[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40]])']) AT_CHECK([ovs-ofctl dump-flows br0 --no-stats], [0], [dnl - actions=load:0x1->OXM_OF_METADATA[[]],load:0x2->OXM_OF_METADATA[[]],load:0x3->OXM_OF_METADATA[[]],load:0x4->OXM_OF_METADATA[[]],bundle(symmetric_l3,0,hrw,ofport,slaves:1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40) + actions=load:0x1->OXM_OF_METADATA[[]],load:0x2->OXM_OF_METADATA[[]],load:0x3->OXM_OF_METADATA[[]],load:0x4->OXM_OF_METADATA[[]],bundle(symmetric_l3,0,hrw,ofport,members:1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40) ]) OVS_VSWITCHD_STOP AT_CLEANUP diff --git a/tests/lacp.at b/tests/lacp.at index 5257f0cce..f44331e85 100644 --- a/tests/lacp.at +++ b/tests/lacp.at @@ -5,9 +5,9 @@ m4_define([STRIP_RECIRC_ID], [[sed ' s/Recirc-ID.*$/<del>/ ' ]]) -# Strips out active slave mac address since it may change over time. -m4_define([STRIP_ACTIVE_SLAVE_MAC], [[sed ' - s/active slave mac.*$/<active slave mac del>/ +# Strips out active member mac address since it may change over time. +m4_define([STRIP_ACTIVE_MEMBER_MAC], [[sed ' + s/active member mac.*$/<active member mac del>/ ' ]]) AT_SETUP([lacp - config]) @@ -27,7 +27,7 @@ AT_CHECK([ovs-appctl lacp/show], [0], [dnl aggregation key: 1 lacp_time: slow -slave: p1: expired attached +member: p1: expired attached port_id: 1 port_priority: 65535 may_enable: false @@ -78,7 +78,7 @@ AT_CHECK([sed -e 's/aggregation key:.*/aggregation key: <omitted>/' < stdout], [ aggregation key: <omitted> lacp_time: fast -slave: p1: expired attached +member: p1: expired attached port_id: 11 port_priority: 111 may_enable: false @@ -97,7 +97,7 @@ slave: p1: expired attached partner key: 0 partner state: timeout -slave: p2: expired attached +member: p2: expired attached port_id: 22 port_priority: 222 may_enable: false @@ -127,12 +127,12 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -active slave mac: 00:00:00:00:00:00(none) +active member mac: 00:00:00:00:00:00(none) -slave p1: disabled +member p1: disabled may_enable: false -slave p2: disabled +member p2: disabled may_enable: false ]) @@ -140,8 +140,8 @@ OVS_VSWITCHD_STOP AT_CLEANUP AT_SETUP([lacp - negotiation]) -# Create bond0 on br0 with interfaces p0 and p1 -# and bond1 on br1 with interfaces p2 and p3 +# Create bond0 on br0 with members p0 and p1 +# and bond1 on br1 with members p2 and p3 # with p0 patched to p2 and p1 patched to p3. OVS_VSWITCHD_START( [add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \ @@ -193,9 +193,9 @@ done AT_CHECK( [ovs-appctl lacp/show bond0 ovs-appctl lacp/show bond1 -ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC -ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [stdout]) -AT_CHECK([sed '/active slave/d' stdout], [0], [dnl +ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC +ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC ], [0], [stdout]) +AT_CHECK([sed '/active member/d' stdout], [0], [dnl ---- bond0 ---- status: active negotiated sys_id: aa:55:aa:55:00:00 @@ -203,7 +203,7 @@ AT_CHECK([sed '/active slave/d' stdout], [0], [dnl aggregation key: 2 lacp_time: fast -slave: p0: current attached +member: p0: current attached port_id: 1 port_priority: 65535 may_enable: true @@ -222,7 +222,7 @@ slave: p0: current attached partner key: 4 partner state: activity timeout aggregation synchronized collecting distributing -slave: p1: current attached +member: p1: current attached port_id: 2 port_priority: 65535 may_enable: true @@ -247,7 +247,7 @@ slave: p1: current attached aggregation key: 4 lacp_time: fast -slave: p2: current attached +member: p2: current attached port_id: 3 port_priority: 65535 may_enable: true @@ -266,7 +266,7 @@ slave: p2: current attached partner key: 2 partner state: activity timeout aggregation synchronized collecting distributing -slave: p3: current attached +member: p3: current attached port_id: 4 port_priority: 65535 may_enable: true @@ -295,10 +295,10 @@ lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -slave p0: enabled +member p0: enabled may_enable: true -slave p1: enabled +member p1: enabled may_enable: true ---- bond1 ---- @@ -312,16 +312,16 @@ lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled +member p3: enabled may_enable: true ]) -AT_CHECK([grep 'active slave$' stdout], [0], [dnl - active slave - active slave +AT_CHECK([grep 'active member$' stdout], [0], [dnl + active member + active member ]) # Redirect the patch link between p0 and p2 so that no packets get @@ -335,8 +335,8 @@ ovs-appctl time/warp 4100 100 AT_CHECK( [ovs-appctl lacp/show bond0 ovs-appctl lacp/show bond1 -ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC -ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [dnl +ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC +ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC ], [0], [dnl ---- bond0 ---- status: active negotiated sys_id: aa:55:aa:55:00:00 @@ -344,7 +344,7 @@ ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [d aggregation key: 2 lacp_time: fast -slave: p0: expired attached +member: p0: expired attached port_id: 1 port_priority: 65535 may_enable: false @@ -363,7 +363,7 @@ slave: p0: expired attached partner key: 4 partner state: activity timeout aggregation collecting distributing -slave: p1: current attached +member: p1: current attached port_id: 2 port_priority: 65535 may_enable: true @@ -388,7 +388,7 @@ slave: p1: current attached aggregation key: 4 lacp_time: fast -slave: p2: expired attached +member: p2: expired attached port_id: 3 port_priority: 65535 may_enable: false @@ -407,7 +407,7 @@ slave: p2: expired attached partner key: 2 partner state: activity timeout aggregation collecting distributing -slave: p3: current attached +member: p3: current attached port_id: 4 port_priority: 65535 may_enable: true @@ -435,13 +435,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p0: disabled +member p0: disabled may_enable: false -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true ---- bond1 ---- @@ -454,13 +454,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p2: disabled +member p2: disabled may_enable: false -slave p3: enabled - active slave +member p3: enabled + active member may_enable: true ]) @@ -471,8 +471,8 @@ ovs-appctl time/warp 4100 100 AT_CHECK( [ovs-appctl lacp/show bond0 ovs-appctl lacp/show bond1 -ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC -ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [dnl +ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC +ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC ], [0], [dnl ---- bond0 ---- status: active negotiated sys_id: aa:55:aa:55:00:00 @@ -480,7 +480,7 @@ ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [d aggregation key: 2 lacp_time: fast -slave: p0: defaulted detached +member: p0: defaulted detached port_id: 1 port_priority: 65535 may_enable: false @@ -499,7 +499,7 @@ slave: p0: defaulted detached partner key: 0 partner state: -slave: p1: current attached +member: p1: current attached port_id: 2 port_priority: 65535 may_enable: true @@ -524,7 +524,7 @@ slave: p1: current attached aggregation key: 4 lacp_time: fast -slave: p2: defaulted detached +member: p2: defaulted detached port_id: 3 port_priority: 65535 may_enable: false @@ -543,7 +543,7 @@ slave: p2: defaulted detached partner key: 0 partner state: -slave: p3: current attached +member: p3: current attached port_id: 4 port_priority: 65535 may_enable: true @@ -571,13 +571,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p0: disabled +member p0: disabled may_enable: false -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true ---- bond1 ---- @@ -590,13 +590,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p2: disabled +member p2: disabled may_enable: false -slave p3: enabled - active slave +member p3: enabled + active member may_enable: true ]) @@ -612,8 +612,8 @@ ovs-appctl time/warp 30100 100 AT_CHECK( [ovs-appctl lacp/show bond0 ovs-appctl lacp/show bond1 -ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC -ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [dnl +ovs-appctl bond/show bond0 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC +ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC ], [0], [dnl ---- bond0 ---- status: active negotiated sys_id: aa:55:aa:55:00:00 @@ -621,7 +621,7 @@ ovs-appctl bond/show bond1 | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC ], [0], [d aggregation key: 2 lacp_time: fast -slave: p0: current attached +member: p0: current attached port_id: 1 port_priority: 65535 may_enable: true @@ -640,7 +640,7 @@ slave: p0: current attached partner key: 4 partner state: activity timeout aggregation synchronized collecting distributing -slave: p1: current attached +member: p1: current attached port_id: 2 port_priority: 65535 may_enable: true @@ -665,7 +665,7 @@ slave: p1: current attached aggregation key: 4 lacp_time: fast -slave: p2: current attached +member: p2: current attached port_id: 3 port_priority: 65535 may_enable: true @@ -684,7 +684,7 @@ slave: p2: current attached partner key: 2 partner state: activity timeout aggregation synchronized collecting distributing -slave: p3: current attached +member: p3: current attached port_id: 4 port_priority: 65535 may_enable: true @@ -712,13 +712,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p0: enabled +member p0: enabled may_enable: true -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true ---- bond1 ---- @@ -731,13 +731,13 @@ downdelay: 0 ms lacp_status: negotiated lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled - active slave +member p3: enabled + active member may_enable: true ]) @@ -771,8 +771,8 @@ ovs-appctl -t ovs-ofctl ofctl/set-output-file monitor.log # Set miss_send_len to 128, enabling port_status messages to our service connection. ovs-appctl -t ovs-ofctl ofctl/send 0409000c0123456700000080 -# Create bond0 on br0 with interfaces p0 and p1 -# and bond1 on br1 with interfaces p2 and p3 +# Create bond0 on br0 with members p0 and p1 +# and bond1 on br1 with members p2 and p3 # with p0 patched to p2 and p1 patched to p3. AT_CHECK([ovs-vsctl add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \ other-config:lacp-time=fast \ @@ -866,8 +866,8 @@ ovs-appctl -t ovs-ofctl ofctl/set-output-file monitor.log # Set miss_send_len to 128, enabling port_status messages to our service connection. ovs-appctl -t ovs-ofctl ofctl/send 0509000c0123456700000080 -# Create bond0 on br0 with interfaces p0 and p1 -# and bond1 on br1 with interfaces p2 and p3 +# Create bond0 on br0 with members p0 and p1 +# and bond1 on br1 with members p2 and p3 # with p0 patched to p2 and p1 patched to p3. AT_CHECK([ovs-vsctl add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \ other-config:lacp-time=fast \ @@ -961,8 +961,8 @@ ovs-appctl -t ovs-ofctl ofctl/set-output-file monitor.log # Set miss_send_len to 128, enabling port_status messages to our service connection. ovs-appctl -t ovs-ofctl ofctl/send 0609000c0123456700000080 -# Create bond0 on br0 with interfaces p0 and p1 -# and bond1 on br1 with interfaces p2 and p3 +# Create bond0 on br0 with members p0 and p1 +# and bond1 on br1 with members p2 and p3 # with p0 patched to p2 and p1 patched to p3. AT_CHECK([ovs-vsctl add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \ other-config:lacp-time=fast \ diff --git a/tests/ofp-actions.at b/tests/ofp-actions.at index c79d7d0e2..199db8ed0 100644 --- a/tests/ofp-actions.at +++ b/tests/ofp-actions.at @@ -80,11 +80,11 @@ ffff 0020 00002320 0016 000000000000 fedcba9876543210 ffff0000ffff0000 # actions=multipath(eth_src,50,modulo_n,1,0,NXM_NX_REG0[]) ffff 0020 00002320 000a 0000 0032 0000 0000 0000 0000 0000 0000 001f 00010004 -# actions=bundle(eth_src,0,hrw,ofport,slaves:4,8) +# actions=bundle(eth_src,0,hrw,ofport,members:4,8) ffff 0028 00002320 000c 0001 0000 0000 00000002 0002 0000 00000000 00000000 dnl 0004 0008 00000000 -# actions=bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[],slaves:4,8) +# actions=bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[],members:4,8) ffff 0028 00002320 000d 0001 0000 0000 00000002 0002 001f 00010004 00000000 dnl 0004 0008 00000000 @@ -444,11 +444,11 @@ ffff 0020 00002320 0016 000000000000 fedcba9876543210 ffffffffffffffff # actions=multipath(eth_src,50,modulo_n,1,0,NXM_NX_REG0[]) ffff 0020 00002320 000a 0000 0032 0000 0000 0000 0000 0000 0000 001f 00010004 -# actions=bundle(eth_src,0,hrw,ofport,slaves:4,8) +# actions=bundle(eth_src,0,hrw,ofport,members:4,8) ffff 0028 00002320 000c 0001 0000 0000 00000002 0002 0000 00000000 00000000 dnl 0004 0008 00000000 -# actions=bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[],slaves:4,8) +# actions=bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[],members:4,8) ffff 0028 00002320 000d 0001 0000 0000 00000002 0002 001f 00010004 00000000 dnl 0004 0008 00000000 @@ -958,17 +958,17 @@ bad_action 'enqueue:asdf:123' 'asdf: enqueue to unknown port' # bundle bad_action 'bundle:123' '123: not enough arguments to bundle action' bad_action 'bundle(symmetric_l4,60,hrw,ofport,ports:1,2,3,4,5)' \ - "symmetric_l4,60,hrw,ofport,ports:1,2,3,4,5: missing slave delimiter, expected \`slaves' got \`ports'" -bad_action 'bundle(symmetric_l4,60,hrw,ofport,slaves:xyzzy,2,3,4,5)' \ + "symmetric_l4,60,hrw,ofport,ports:1,2,3,4,5: missing member delimiter, expected \`members', got \`ports'" +bad_action 'bundle(symmetric_l4,60,hrw,ofport,members:xyzzy,2,3,4,5)' \ 'xyzzy: bad port number' -bad_action 'bundle(asymmetric_l4,60,hrw,ofport,slaves:1,2,3,4,5)' \ - "asymmetric_l4,60,hrw,ofport,slaves:1,2,3,4,5: unknown fields \`asymmetric_l4'" -bad_action 'bundle(symmetric_l4,60,hrt,ofport,slaves:1,2,3,4,5)' \ - "symmetric_l4,60,hrt,ofport,slaves:1,2,3,4,5: unknown algorithm \`hrt'" -bad_action 'bundle(symmetric_l4,60,hrw,odpport,slaves:1,2,3,4,5)' \ - "symmetric_l4,60,hrw,odpport,slaves:1,2,3,4,5: unknown slave_type \`odpport'" -bad_action 'bundle_load(symmetric_l4,60,hrw,ofport,actset_output,slaves:1,2,3,4,5)' \ - "symmetric_l4,60,hrw,ofport,actset_output,slaves:1,2,3,4,5: experimenter OXM field 'actset_output' not supported" +bad_action 'bundle(asymmetric_l4,60,hrw,ofport,members:1,2,3,4,5)' \ + "asymmetric_l4,60,hrw,ofport,members:1,2,3,4,5: unknown fields \`asymmetric_l4'" +bad_action 'bundle(symmetric_l4,60,hrt,ofport,members:1,2,3,4,5)' \ + "symmetric_l4,60,hrt,ofport,members:1,2,3,4,5: unknown algorithm \`hrt'" +bad_action 'bundle(symmetric_l4,60,hrw,odpport,members:1,2,3,4,5)' \ + "symmetric_l4,60,hrw,odpport,members:1,2,3,4,5: unknown member_type \`odpport'" +bad_action 'bundle_load(symmetric_l4,60,hrw,ofport,actset_output,members:1,2,3,4,5)' \ + "symmetric_l4,60,hrw,ofport,actset_output,members:1,2,3,4,5: experimenter OXM field 'actset_output' not supported" # mod_vlan_vid bad_action 'mod_vlan_vid:6000' '6000: not a valid VLAN VID' diff --git a/tests/ofproto-dpif.at b/tests/ofproto-dpif.at index 88dd434e4..31064ed95 100644 --- a/tests/ofproto-dpif.at +++ b/tests/ofproto-dpif.at @@ -31,8 +31,8 @@ AT_CLEANUP AT_SETUP([ofproto-dpif - active-backup bonding (with primary)]) -dnl Create br0 with interfaces p1, p2 and p7, creating bond0 with p1 and -dnl p2 (p1 as primary) and br1 with interfaces p3, p4 and p8. +dnl Create br0 with members p1, p2 and p7, creating bond0 with p1 and +dnl p2 (p1 as primary) and br1 with members p3, p4 and p8. dnl toggle p1,p2 of bond0 up and down to test bonding in active-backup mode. dnl With p1 down and p2 up/active, bring p1 back up. Since p1 is the primary, dnl it should become active. @@ -81,7 +81,7 @@ recirc_id(0),in_port(4),packet_type(ns=0,id=0),eth(src=50:54:00:00:00:0b,dst=ff: ovs-appctl netdev-dummy/set-admin-state p1 up ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC], [0], [dnl +OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ---- bond0 ---- bond_mode: active-backup bond may use recirculation: no, <del> @@ -91,13 +91,13 @@ downdelay: 0 ms lacp_status: off lacp_fallback_ab: false active-backup primary: p1 -<active slave mac del> +<active member mac del> -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true -slave p2: enabled +member p2: enabled may_enable: true ]) @@ -118,18 +118,18 @@ OVS_VSWITCHD_START( add-port br0 p7 -- set interface p7 ofport_request=7 type=dummy --]) AT_CHECK([ovs-appctl vlog/set dpif:dbg dpif_netdev:dbg]) -dnl Make sure the initial primary interface is set +dnl Make sure the initial primary member is set OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | grep 'active-backup primary: p1'`"]) -dnl Down the primary interface and verify that we switched. Then +dnl Down the primary member and verify that we switched. Then dnl bring the primary back and verify that we switched back to the dnl primary. ovs-appctl netdev-dummy/set-admin-state p1 down ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | fgrep 'slave p1: disabled'`"]) +OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | fgrep 'member p1: disabled'`"]) ovs-appctl netdev-dummy/set-admin-state p1 up ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC], [0], [dnl +OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ---- bond0 ---- bond_mode: active-backup bond may use recirculation: no, <del> @@ -139,39 +139,39 @@ downdelay: 0 ms lacp_status: off lacp_fallback_ab: false active-backup primary: p1 -<active slave mac del> +<active member mac del> -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled +member p3: enabled may_enable: true ]) dnl Now delete the primary and verify that the output shows that the -dnl primary is no longer enslaved +dnl primary is no longer an member ovs-vsctl --id=@p1 get Interface p1 -- remove Port bond0 interfaces @p1 ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | fgrep 'active-backup primary: p1 (no such slave)'`"]) +OVS_WAIT_UNTIL([test -n "`ovs-appctl bond/show | fgrep 'active-backup primary: p1 (no such member)'`"]) dnl Now re-add the primary and verify that the output shows that the dnl primary is available again. dnl -dnl First, get the UUIDs of the interfaces that exist on bond0. +dnl First, get the UUIDs of the members that exist on bond0. dnl Strip the trailing ] so that we can add a new UUID to the end. uuids=`ovs-vsctl get Port bond0 interfaces | sed -e 's/]//'` -dnl Create a new port "p1" and add its UUID to the set of interfaces +dnl Create a new port "p1" and add its UUID to the set of members dnl on bond0. ovs-vsctl \ --id=@p1 create Interface name=p1 type=dummy options:pstream=punix:$OVS_RUNDIR/p1.sock ofport_request=1 -- \ set Port bond0 interfaces="$uuids, @p1]" ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC], [0], [dnl +OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ---- bond0 ---- bond_mode: active-backup bond may use recirculation: no, <del> @@ -181,16 +181,16 @@ downdelay: 0 ms lacp_status: off lacp_fallback_ab: false active-backup primary: p1 -<active slave mac del> +<active member mac del> -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled +member p3: enabled may_enable: true ]) @@ -198,7 +198,7 @@ slave p3: enabled dnl Switch to another primary ovs-vsctl set port bond0 other_config:bond-primary=p2 ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC], [0], [dnl +OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ---- bond0 ---- bond_mode: active-backup bond may use recirculation: no, <del> @@ -208,16 +208,16 @@ downdelay: 0 ms lacp_status: off lacp_fallback_ab: false active-backup primary: p2 -<active slave mac del> +<active member mac del> -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled +member p3: enabled may_enable: true ]) @@ -225,7 +225,7 @@ slave p3: enabled dnl Remove the "bond-primary" config directive from the bond. AT_CHECK([ovs-vsctl remove Port bond0 other_config bond-primary]) ovs-appctl time/warp 100 -OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_SLAVE_MAC], [0], [dnl +OVS_WAIT_UNTIL([ovs-appctl bond/show | STRIP_RECIRC_ID | STRIP_ACTIVE_MEMBER_MAC], [0], [dnl ---- bond0 ---- bond_mode: active-backup bond may use recirculation: no, <del> @@ -235,16 +235,16 @@ downdelay: 0 ms lacp_status: off lacp_fallback_ab: false active-backup primary: <none> -<active slave mac del> +<active member mac del> -slave p1: enabled - active slave +member p1: enabled + active member may_enable: true -slave p2: enabled +member p2: enabled may_enable: true -slave p3: enabled +member p3: enabled may_enable: true ]) @@ -253,8 +253,8 @@ OVS_VSWITCHD_STOP AT_CLEANUP AT_SETUP([ofproto-dpif - active-backup bonding (without primary)]) -dnl Create br0 with interfaces p1, p2 and p7, creating bond0 with p1 and p2 -dnl and br1 with interfaces p3, p4 and p8. +dnl Create br0 with members p1, p2 and p7, creating bond0 with p1 and p2 +dnl and br1 with members p3, p4 and p8. dnl toggle p1,p2 of bond0 up and down to test bonding in active-backup mode. OVS_VSWITCHD_START( [add-bond br0 bond0 p1 p2 bond_mode=active-backup --\ @@ -300,8 +300,8 @@ OVS_VSWITCHD_STOP AT_CLEANUP AT_SETUP([ofproto-dpif - balance-slb bonding]) -# Create br0 with interfaces bond0(p1, p2, p3) and p7, -# and br1 with interfaces p4, p5, p6 and p8. +# Create br0 with members bond0(p1, p2, p3) and p7, +# and br1 with members p4, p5, p6 and p8. # p1 <-> p4, p2 <-> p5, p3 <-> p6 # Send some traffic, make sure the traffic are spread based on source mac. OVS_VSWITCHD_START( @@ -343,8 +343,8 @@ OVS_VSWITCHD_STOP AT_CLEANUP AT_SETUP([ofproto-dpif - balance-tcp bonding]) -# Create br0 with interfaces bond0(p1, p2, p3) and p7, -# and br1 with interfaces bond1(p4, p5, p6) and p8. +# Create br0 with members bond0(p1, p2, p3) and p7, +# and br1 with members bond1(p4, p5, p6) and p8. # bond0 <-> bond1 # Send some traffic, make sure the traffic are spread based on L4 headers. OVS_VSWITCHD_START( @@ -2185,7 +2185,7 @@ cookie=0xd dl_src=60:66:66:66:00:02 actions=pop_mpls:0x0800,load:0xa000001->OXM_ cookie=0xd dl_src=60:66:66:66:00:03 actions=pop_mpls:0x0800,move:OXM_OF_IPV4_DST[[]]->OXM_OF_IPV4_SRC[[]],controller cookie=0xd dl_src=60:66:66:66:00:04 actions=pop_mpls:0x0800,push:OXM_OF_IPV4_DST[[]],pop:OXM_OF_IPV4_SRC[[]],controller cookie=0xd dl_src=60:66:66:66:00:05 actions=pop_mpls:0x0800,multipath(eth_src,50,modulo_n,1,0,OXM_OF_IPV4_SRC[[0..7]]),controller -cookie=0xd dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,OXM_OF_IPV4_SRC[[0..15]],slaves:1,2),controller +cookie=0xd dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,OXM_OF_IPV4_SRC[[0..15]],members:1,2),controller cookie=0xd dl_src=60:66:66:66:00:07 actions=pop_mpls:0x0800,learn(table=1,hard_timeout=60,eth_type=0x800,nw_proto=6,OXM_OF_IPV4_SRC[[]]=OXM_OF_IPV4_DST[[]]),controller cookie=0xd dl_src=60:66:66:66:00:08 actions=pop_mpls:0x0806,resubmit(1,1) @@ -3183,7 +3183,7 @@ AT_CHECK([ovs-ofctl dump-flows br0 | ofctl_strip | sort], [0], [dnl cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:03 actions=pop_mpls:0x0800,move:NXM_OF_IP_DST[[]]->NXM_OF_IP_SRC[[]],CONTROLLER:65535 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:04 actions=pop_mpls:0x0800,push:NXM_OF_IP_DST[[]],pop:NXM_OF_IP_SRC[[]],CONTROLLER:65535 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:05 actions=pop_mpls:0x0800,multipath(eth_src,50,modulo_n,1,0,NXM_OF_IP_SRC[[0..7]]),CONTROLLER:65535 - cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,NXM_OF_IP_SRC[[0..15]],slaves:1,2),CONTROLLER:65535 + cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:06 actions=pop_mpls:0x0800,bundle_load(eth_src,50,hrw,ofport,NXM_OF_IP_SRC[[0..15]],members:1,2),CONTROLLER:65535 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:07 actions=pop_mpls:0x0800,learn(table=1,hard_timeout=60,eth_type=0x800,nw_proto=6,NXM_OF_IP_SRC[[]]=NXM_OF_IP_DST[[]]),CONTROLLER:65535 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:09 actions=resubmit(,2),CONTROLLER:65535 cookie=0xd, n_packets=3, n_bytes=186, dl_src=60:66:66:66:00:0a actions=pop_mpls:0x0800,mod_nw_dst:10.0.0.1,CONTROLLER:65535 @@ -8634,8 +8634,8 @@ OVS_VSWITCHD_STOP AT_CLEANUP AT_SETUP([ofproto-dpif megaflow - normal, balance-tcp bonding]) -# Create bond0 on br0 with interfaces p0 and p1 -# and bond1 on br1 with interfaces p2 and p3 +# Create bond0 on br0 with members p0 and p1 +# and bond1 on br1 with members p2 and p3 # with p0 patched to p2 and p1 patched to p3. OVS_VSWITCHD_START( [add-bond br0 bond0 p0 p1 bond_mode=balance-tcp lacp=active \ @@ -9023,7 +9023,7 @@ AT_CHECK([ovs-appctl bfd/show | sed -n '/^.*Session State:.*/p'], [0], [dnl Local Session State: up Remote Session State: up ]) -# bond/show should show 'may-enable: true' for all slaves. +# bond/show should show 'may-enable: true' for all members. AT_CHECK([ovs-appctl bond/show | sed -n '/^.*may_enable:.*/p'], [0], [dnl may_enable: true may_enable: true @@ -11027,7 +11027,7 @@ AT_CHECK([ovs-vsctl add-port br0 p2 -- set int p2 type=dummy mtu_request=1600]) AT_CHECK([ovs-vsctl wait-until Interface p2 mtu=1600]) AT_CHECK([ovs-vsctl wait-until Interface br0 mtu=1600]) -# Explicitly set mtu_request on the internal interface. This should prevent +# Explicitly set mtu_request on the internal member. This should prevent # the MTU from being overriden. AT_CHECK([ovs-vsctl set int br0 mtu_request=1700]) AT_CHECK([ovs-vsctl wait-until Interface br0 mtu=1700]) diff --git a/tests/ofproto.at b/tests/ofproto.at index f56673625..08c0a20b6 100644 --- a/tests/ofproto.at +++ b/tests/ofproto.at @@ -6322,12 +6322,12 @@ AT_CHECK([strip_xids < stderr | sed '/FLOW_MOD/,$d'], [0], [dnl OFPT_ERROR: OFPBAC_BAD_SET_LEN ]) -AT_CHECK([ovs-ofctl add-flow br0 "in_port=2 actions=bundle_load(eth_src,50,hrw,ofport,tun_metadata1[[0..31]], slaves:4,8)"], [1], [], [stderr]) +AT_CHECK([ovs-ofctl add-flow br0 "in_port=2 actions=bundle_load(eth_src,50,hrw,ofport,tun_metadata1[[0..31]], members:4,8)"], [1], [], [stderr]) AT_CHECK([strip_xids < stderr | sed '/FLOW_MOD/,$d'], [0], [dnl OFPT_ERROR: NXFMFC_INVALID_TLV_FIELD ]) -AT_CHECK([ovs-ofctl add-flow br0 "in_port=2 actions=bundle_load(eth_src,50,hrw,ofport,tun_metadata0[[32..63]], slaves:4,8)"], [1], [], [stderr]) +AT_CHECK([ovs-ofctl add-flow br0 "in_port=2 actions=bundle_load(eth_src,50,hrw,ofport,tun_metadata0[[32..63]], members:4,8)"], [1], [], [stderr]) AT_CHECK([strip_xids < stderr | sed '/FLOW_MOD/,$d'], [0], [dnl OFPT_ERROR: OFPBAC_BAD_SET_LEN ]) diff --git a/tests/ovs-ofctl.at b/tests/ovs-ofctl.at index c8062c8ac..b6951f404 100644 --- a/tests/ovs-ofctl.at +++ b/tests/ovs-ofctl.at @@ -413,20 +413,20 @@ actions=multipath(eth_src, 50, hrw, 12, 0, NXM_NX_REG0[0..3]),multipath(symmetri table=1,actions=drop tun_id=0x1234000056780000/0xffff0000ffff0000,actions=drop metadata=0x1234ffff5678ffff/0xffff0000ffff0000,actions=drop -actions=bundle(eth_src,50,active_backup,ofport,slaves:1) -actions=bundle(symmetric_l4,60,hrw,ofport,slaves:2,3) -actions=bundle(symmetric_l4,60,hrw,ofport,slaves:) -actions=bundle(symmetric_l3,60,hrw,ofport,slaves:2,3) -actions=bundle(symmetric_l3,60,hrw,ofport,slaves:) -actions=output:1,bundle(eth_src,0,hrw,ofport,slaves:1),output:2 -actions=bundle_load(eth_src,50,active_backup,ofport,reg0,slaves:1) -actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -actions=bundle_load(symmetric_l4,60,hrw,ofport,reg0[0..15],slaves:[2,3]) -actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..30],slaves:) -actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -actions=bundle_load(symmetric_l3,60,hrw,ofport,reg0[0..15],slaves:[2,3]) -actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..30],slaves:) -actions=output:1,bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[16..31],slaves:1),output:2 +actions=bundle(eth_src,50,active_backup,ofport,members:1) +actions=bundle(symmetric_l4,60,hrw,ofport,members:2,3) +actions=bundle(symmetric_l4,60,hrw,ofport,members:) +actions=bundle(symmetric_l3,60,hrw,ofport,members:2,3) +actions=bundle(symmetric_l3,60,hrw,ofport,members:) +actions=output:1,bundle(eth_src,0,hrw,ofport,members:1),output:2 +actions=bundle_load(eth_src,50,active_backup,ofport,reg0,members:1) +actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +actions=bundle_load(symmetric_l4,60,hrw,ofport,reg0[0..15],members:[2,3]) +actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..30],members:) +actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +actions=bundle_load(symmetric_l3,60,hrw,ofport,reg0[0..15],members:[2,3]) +actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..30],members:) +actions=output:1,bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[16..31],members:1),output:2 actions=resubmit:1,resubmit(2),resubmit(,3),resubmit(2,3) send_flow_rem,actions=output:1,output:NXM_NX_REG0,output:2,output:reg1[16..31],output:3 check_overlap,actions=output:1,exit,output:2 @@ -469,20 +469,20 @@ NXT_FLOW_MOD: ADD table:255 actions=multipath(eth_src,50,hrw,12,0,NXM_NX_REG0[0. NXT_FLOW_MOD: ADD table:1 actions=drop NXT_FLOW_MOD: ADD table:255 tun_id=0x1234000056780000/0xffff0000ffff0000 actions=drop NXT_FLOW_MOD: ADD table:255 metadata=0x1234000056780000/0xffff0000ffff0000 actions=drop -NXT_FLOW_MOD: ADD table:255 actions=bundle(eth_src,50,active_backup,ofport,slaves:1) -NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l4,60,hrw,ofport,slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l4,60,hrw,ofport,slaves:) -NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l3,60,hrw,ofport,slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l3,60,hrw,ofport,slaves:) -NXT_FLOW_MOD: ADD table:255 actions=output:1,bundle(eth_src,0,hrw,ofport,slaves:1),output:2 -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(eth_src,50,active_backup,ofport,NXM_NX_REG0[],slaves:1) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..30],slaves:) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],slaves:2,3) -NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..30],slaves:) -NXT_FLOW_MOD: ADD table:255 actions=output:1,bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[16..31],slaves:1),output:2 +NXT_FLOW_MOD: ADD table:255 actions=bundle(eth_src,50,active_backup,ofport,members:1) +NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l4,60,hrw,ofport,members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l4,60,hrw,ofport,members:) +NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l3,60,hrw,ofport,members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle(symmetric_l3,60,hrw,ofport,members:) +NXT_FLOW_MOD: ADD table:255 actions=output:1,bundle(eth_src,0,hrw,ofport,members:1),output:2 +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(eth_src,50,active_backup,ofport,NXM_NX_REG0[],members:1) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l4,60,hrw,ofport,NXM_NX_REG0[0..30],members:) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..15],members:2,3) +NXT_FLOW_MOD: ADD table:255 actions=bundle_load(symmetric_l3,60,hrw,ofport,NXM_NX_REG0[0..30],members:) +NXT_FLOW_MOD: ADD table:255 actions=output:1,bundle_load(eth_src,0,hrw,ofport,NXM_NX_REG0[16..31],members:1),output:2 NXT_FLOW_MOD: ADD table:255 actions=resubmit:1,resubmit:2,resubmit(,3),resubmit(2,3) NXT_FLOW_MOD: ADD table:255 send_flow_rem actions=output:1,output:NXM_NX_REG0[],output:2,output:NXM_NX_REG1[16..31],output:3 NXT_FLOW_MOD: ADD table:255 check_overlap actions=output:1,exit,output:2 diff --git a/tests/test-bundle.c b/tests/test-bundle.c index 124ad5b43..53f78e86f 100644 --- a/tests/test-bundle.c +++ b/tests/test-bundle.c @@ -25,28 +25,28 @@ #include "util.h" #define N_FLOWS 50000 -#define MAX_SLAVES 8 /* Maximum supported by this test framework. */ +#define MAX_MEMBERS 8 /* Maximum supported by this test framework. */ -struct slave { - ofp_port_t slave_id; +struct member { + ofp_port_t member_id; bool enabled; size_t flow_count; }; -struct slave_group { - size_t n_slaves; - struct slave slaves[MAX_SLAVES]; +struct member_group { + size_t n_members; + struct member members[MAX_MEMBERS]; }; -static struct slave * -slave_lookup(struct slave_group *sg, ofp_port_t slave_id) +static struct member * +member_lookup(struct member_group *sg, ofp_port_t member_id) { size_t i; - for (i = 0; i < sg->n_slaves; i++) { - if (sg->slaves[i].slave_id == slave_id) { - return &sg->slaves[i]; + for (i = 0; i < sg->n_members; i++) { + if (sg->members[i].member_id == member_id) { + return &sg->members[i]; } } @@ -54,12 +54,12 @@ slave_lookup(struct slave_group *sg, ofp_port_t slave_id) } static bool -slave_enabled_cb(ofp_port_t slave_id, void *aux) +member_enabled_cb(ofp_port_t member_id, void *aux) { - struct slave *slave; + struct member *member; - slave = slave_lookup(aux, slave_id); - return slave ? slave->enabled : false; + member = member_lookup(aux, member_id); + return member ? member->enabled : false; } static struct ofpact_bundle * @@ -80,8 +80,8 @@ parse_bundle_actions(char *actions) bundle = ofpact_get_BUNDLE(xmemdup(action, action->len)); ofpbuf_uninit(&ofpacts); - if (bundle->n_slaves > MAX_SLAVES) { - ovs_fatal(0, "At most %u slaves are supported", MAX_SLAVES); + if (bundle->n_members > MAX_MEMBERS) { + ovs_fatal(0, "At most %u members are supported", MAX_MEMBERS); } return bundle; @@ -109,7 +109,7 @@ test_bundle_main(int argc, char *argv[]) struct ofpact_bundle *bundle; struct flow *flows; size_t i, n_permute, old_n_enabled; - struct slave_group sg; + struct member_group sg; int old_active; set_program_name(argv[0]); @@ -120,17 +120,17 @@ test_bundle_main(int argc, char *argv[]) bundle = parse_bundle_actions(argv[1]); - /* Generate 'slaves' array. */ - sg.n_slaves = 0; - for (i = 0; i < bundle->n_slaves; i++) { - ofp_port_t slave_id = bundle->slaves[i]; + /* Generate 'members' array. */ + sg.n_members = 0; + for (i = 0; i < bundle->n_members; i++) { + ofp_port_t member_id = bundle->members[i]; - if (slave_lookup(&sg, slave_id)) { - ovs_fatal(0, "Redundant slaves are not supported. "); + if (member_lookup(&sg, member_id)) { + ovs_fatal(0, "Redundant members are not supported. "); } - sg.slaves[sg.n_slaves].slave_id = slave_id; - sg.n_slaves++; + sg.members[sg.n_members].member_id = member_id; + sg.n_members++; } /* Generate flows. */ @@ -141,14 +141,14 @@ test_bundle_main(int argc, char *argv[]) } /* Cycles through each possible liveness permutation for the given - * n_slaves. The initial state is equivalent to all slaves down, so we + * n_members. The initial state is equivalent to all members down, so we * skip it by starting at i = 1. We do one extra iteration to cover * transitioning from the final state back to the initial state. */ old_n_enabled = 0; old_active = -1; - n_permute = 1 << sg.n_slaves; + n_permute = 1 << sg.n_members; for (i = 1; i <= n_permute + 1; i++) { - struct slave *slave; + struct member *member; size_t j, n_enabled, changed; double disruption, perfect; uint8_t mask; @@ -156,27 +156,27 @@ test_bundle_main(int argc, char *argv[]) mask = i % n_permute; - /* Gray coding ensures that in each iteration exactly one slave + /* Gray coding ensures that in each iteration exactly one member * changes its liveness. This makes the expected disruption a bit * easier to calculate, and is likely similar to how failures will be * experienced in the wild. */ mask = mask ^ (mask >> 1); - /* Initialize slaves. */ + /* Initialize members. */ n_enabled = 0; - for (j = 0; j < sg.n_slaves; j++) { - slave = &sg.slaves[j]; - slave->flow_count = 0; - slave->enabled = ((1 << j) & mask) != 0; + for (j = 0; j < sg.n_members; j++) { + member = &sg.members[j]; + member->flow_count = 0; + member->enabled = ((1 << j) & mask) != 0; - if (slave->enabled) { + if (member->enabled) { n_enabled++; } } active = -1; - for (j = 0; j < sg.n_slaves; j++) { - if (sg.slaves[j].enabled) { + for (j = 0; j < sg.n_members; j++) { + if (sg.members[j].enabled) { active = j; break; } @@ -185,19 +185,19 @@ test_bundle_main(int argc, char *argv[]) changed = 0; for (j = 0; j < N_FLOWS; j++) { struct flow *flow = &flows[j]; - ofp_port_t old_slave_id, ofp_port; + ofp_port_t old_member_id, ofp_port; struct flow_wildcards wc; - old_slave_id = u16_to_ofp(flow->regs[0]); - ofp_port = bundle_execute(bundle, flow, &wc, slave_enabled_cb, + old_member_id = u16_to_ofp(flow->regs[0]); + ofp_port = bundle_execute(bundle, flow, &wc, member_enabled_cb, &sg); flow->regs[0] = ofp_to_u16(ofp_port); if (ofp_port != OFPP_NONE) { - slave_lookup(&sg, ofp_port)->flow_count++; + member_lookup(&sg, ofp_port)->flow_count++; } - if (old_slave_id != ofp_port) { + if (old_member_id != ofp_port) { changed++; } } @@ -208,23 +208,23 @@ test_bundle_main(int argc, char *argv[]) if (old_n_enabled || n_enabled) { perfect = 1.0 / MAX(old_n_enabled, n_enabled); } else { - /* This will happen when 'sg.n_slaves' is 0. */ + /* This will happen when 'sg.n_members' is 0. */ perfect = 0; } } disruption = changed / (double)N_FLOWS; printf("%s: disruption=%.2f (perfect=%.2f)", - mask_str(mask, sg.n_slaves), disruption, perfect); + mask_str(mask, sg.n_members), disruption, perfect); - for (j = 0 ; j < sg.n_slaves; j++) { - slave = &sg.slaves[j]; + for (j = 0 ; j < sg.n_members; j++) { + member = &sg.members[j]; double flow_percent; - flow_percent = slave->flow_count / (double)N_FLOWS; + flow_percent = member->flow_count / (double)N_FLOWS; printf( " %.2f", flow_percent); - if (slave->enabled) { + if (member->enabled) { double perfect_fp; if (bundle->algorithm == NX_BD_ALG_ACTIVE_BACKUP) { @@ -234,16 +234,16 @@ test_bundle_main(int argc, char *argv[]) } if (fabs(flow_percent - perfect_fp) >= .01) { - fprintf(stderr, "%s: slave %d: flow_percentage=%.5f for" + fprintf(stderr, "%s: member %d: flow_percentage=%.5f for" " differs from perfect=%.5f by more than .01\n", - mask_str(mask, sg.n_slaves), slave->slave_id, + mask_str(mask, sg.n_members), member->member_id, flow_percent, perfect_fp); ok = false; } - } else if (slave->flow_count) { - fprintf(stderr, "%s: slave %d: disabled slave received" - " flows.\n", mask_str(mask, sg.n_slaves), - slave->slave_id); + } else if (member->flow_count) { + fprintf(stderr, "%s: member %d: disabled member received" + " flows.\n", mask_str(mask, sg.n_members), + member->member_id); ok = false; } } @@ -251,7 +251,7 @@ test_bundle_main(int argc, char *argv[]) if (fabs(disruption - perfect) >= .01) { fprintf(stderr, "%s: disruption=%.5f differs from perfect=%.5f by" - " more than .01\n", mask_str(mask, sg.n_slaves), + " more than .01\n", mask_str(mask, sg.n_members), disruption, perfect); ok = false; } |