[PATCH 4/4] recipes: make netperf confidence level an alias in phase1 and phase2 regression tests
by Jan Tluka
The phase1 and phase2 regression tests now take an optional alias
nperf_confidence with default value 99,5.
This patch also enhances how the timeout for netperf test is calculated.
The value is now (netperf_duration + nperf_reserve)*nperf_max_runs. The
value of nperf_max_runs is taken from nperf_confidence alias.
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
recipes/regression_tests/phase1/3_vlans.py | 26 +++++++++---------
recipes/regression_tests/phase1/3_vlans.xml | 1 +
.../regression_tests/phase1/3_vlans_over_bond.py | 26 +++++++++---------
recipes/regression_tests/phase1/bonding_test.py | 26 +++++++++---------
.../phase1/virtual_bridge_2_vlans_over_bond.py | 30 +++++++++++----------
.../phase1/virtual_bridge_vlan_in_guest.py | 30 +++++++++++----------
.../phase1/virtual_bridge_vlan_in_host.py | 31 ++++++++++++----------
.../regression_tests/phase2/3_vlans_over_team.py | 27 ++++++++++---------
recipes/regression_tests/phase2/team_test.py | 22 ++++++++-------
...l_ovs_bridge_2_vlans_over_active_backup_bond.py | 30 +++++++++++----------
.../phase2/virtual_ovs_bridge_vlan_in_guest.py | 30 +++++++++++----------
.../phase2/virtual_ovs_bridge_vlan_in_host.py | 30 +++++++++++----------
12 files changed, 166 insertions(+), 143 deletions(-)
diff --git a/recipes/regression_tests/phase1/3_vlans.py b/recipes/regression_tests/phase1/3_vlans.py
index 2be04e7..6e04f67 100644
--- a/recipes/regression_tests/phase1/3_vlans.py
+++ b/recipes/regression_tests/phase1/3_vlans.py
@@ -43,6 +43,8 @@ ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
m1_phy1 = m1.get_interface("eth1")
m1_phy1.set_mtu(mtu)
@@ -81,28 +83,28 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
for vlan1 in vlans:
@@ -118,16 +120,16 @@ for vlan1 in vlans:
netperf_srv6.update_options({"bind": m1.get_ip(vlan1, 1)})
netperf_cli_tcp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_udp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_tcp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
netperf_cli_udp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
if vlan1 == vlan2:
# These tests should pass
@@ -196,9 +198,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and\
@@ -280,9 +282,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/3_vlans.xml b/recipes/regression_tests/phase1/3_vlans.xml
index ee4eab5..86b82b6 100644
--- a/recipes/regression_tests/phase1/3_vlans.xml
+++ b/recipes/regression_tests/phase1/3_vlans.xml
@@ -4,6 +4,7 @@
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
<alias name="nperf_reserve" value="20" />
+ <alias name="nperf_confidence" value="99,5" />
<alias name="mapping_file" value="3_vlans.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/3_vlans_over_bond.py b/recipes/regression_tests/phase1/3_vlans_over_bond.py
index feb9302..95936d1 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/3_vlans_over_bond.py
@@ -43,6 +43,8 @@ ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
m1_bond = m1.get_interface("test_bond")
m1_bond.set_mtu(mtu)
@@ -81,28 +83,28 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
for vlan1 in vlans:
@@ -118,16 +120,16 @@ for vlan1 in vlans:
netperf_srv6.update_options({"bind": m1.get_ip(vlan1, 1)})
netperf_cli_tcp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_udp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_tcp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
netperf_cli_udp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
if vlan1 == vlan2:
# These tests should pass
@@ -198,9 +200,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and\
@@ -282,9 +284,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/bonding_test.py b/recipes/regression_tests/phase1/bonding_test.py
index cefea0d..a343b9e 100644
--- a/recipes/regression_tests/phase1/bonding_test.py
+++ b/recipes/regression_tests/phase1/bonding_test.py
@@ -42,6 +42,8 @@ ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -83,8 +85,8 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : m1.get_ip("test_if", 0),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" % m2.get_ip("test_if", 0)
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" % (nperf_max_runs, m2.get_ip("test_if", 0))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -93,8 +95,8 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : m1.get_ip("test_if", 0),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" % m2.get_ip("test_if", 0)
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" % (nperf_max_runs, m2.get_ip("test_if", 0))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -104,9 +106,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
m1.get_ip("test_if", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % m2.get_ip("test_if", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip("test_if", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
options={
@@ -115,9 +117,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
m1.get_ip("test_if", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % m2.get_ip("test_if", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip("test_if", 1))
})
ctl.wait(15)
@@ -177,9 +179,9 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and\
@@ -255,9 +257,9 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
index dd55166..8226fc4 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
@@ -48,6 +48,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -102,9 +104,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- g3.get_ip("guestnic")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, g3.get_ip("guestnic"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -113,9 +115,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- g3.get_ip("guestnic")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, g3.get_ip("guestnic"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -125,9 +127,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % g3.get_ip("guestnic", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, g3.get_ip("guestnic", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -137,9 +139,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % g3.get_ip("guestnic", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, g3.get_ip("guestnic", 1))
})
ping_mod_bad = ctl.get_module("IcmpPing",
@@ -272,10 +274,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = g3.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
if enable_udp_perf is not None:
udp_res_data = g3.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and\
@@ -359,10 +361,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = g3.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
if enable_udp_perf is not None:
udp_res_data = g3.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
index af66655..0c7ffa4 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
@@ -42,6 +42,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -81,9 +83,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("vlan10"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -92,9 +94,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("vlan10"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -104,9 +106,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("vlan10", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -116,9 +118,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("vlan10", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
# configure mtu
@@ -195,10 +197,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
if enable_udp_perf is not None:
udp_res_data = h2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
@@ -280,9 +282,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
index 30979cb..509ea57 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
@@ -42,6 +42,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -81,9 +83,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -92,9 +94,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -104,9 +106,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -116,9 +118,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
# configure mtu
@@ -195,10 +197,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
if enable_udp_perf is not None:
udp_res_data = h2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
@@ -280,9 +282,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
+
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/3_vlans_over_team.py b/recipes/regression_tests/phase2/3_vlans_over_team.py
index 7f9a767..157da14 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_team.py
+++ b/recipes/regression_tests/phase2/3_vlans_over_team.py
@@ -42,6 +42,8 @@ ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
m1_team = m1.get_interface("test_if")
m1_team.set_mtu(mtu)
@@ -81,28 +83,28 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
netperf_cli_udp6 = ctl.get_module("Netperf",
options={
"role" : "client",
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5"
+ "confidence" : nperf_confidence
})
for vlan1 in vlans:
@@ -118,17 +120,16 @@ for vlan1 in vlans:
netperf_srv6.update_options({"bind": m1.get_ip(vlan1, 1)})
netperf_cli_tcp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_udp.update_options({"netperf_server": m1.get_ip(vlan1, 0),
- "netperf_opts": "-i 5 -L %s" % m2.get_ip(vlan1, 0)})
+ "netperf_opts": "-i %s -L %s" % (nperf_max_runs, m2.get_ip(vlan1, 0))})
netperf_cli_tcp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
netperf_cli_udp6.update_options({"netperf_server": m1.get_ip(vlan1, 1),
- "netperf_opts": "-i 5 -L %s -6" % m2.get_ip(vlan1, 1)})
-
+ "netperf_opts": "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip(vlan1, 1))})
if vlan1 == vlan2:
# These tests should pass
@@ -199,9 +200,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and\
@@ -282,9 +283,9 @@ for vlan1 in vlans:
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/team_test.py b/recipes/regression_tests/phase2/team_test.py
index 259505b..d569aaa 100644
--- a/recipes/regression_tests/phase2/team_test.py
+++ b/recipes/regression_tests/phase2/team_test.py
@@ -42,6 +42,8 @@ ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -84,8 +86,8 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : m1.get_ip("test_if", 0),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" % m2.get_ip("test_if", 0)
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" % (nperf_max_runs, m2.get_ip("test_if", 0))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -94,8 +96,8 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : m1.get_ip("test_if", 0),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" % m2.get_ip("test_if", 0)
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" % (nperf_max_runs, m2.get_ip("test_if", 0))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -105,9 +107,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
m1.get_ip("test_if", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % m2.get_ip("test_if", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip("test_if", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
options={
@@ -116,9 +118,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
m1.get_ip("test_if", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % m2.get_ip("test_if", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, m2.get_ip("test_if", 1))
})
ctl.wait(15)
@@ -183,9 +185,9 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = m2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = m2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
index 3d0a828..6e6aa10 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
@@ -48,6 +48,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -100,9 +102,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- g3.get_ip("guestnic")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, g3.get_ip("guestnic"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -111,9 +113,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- g3.get_ip("guestnic")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, g3.get_ip("guestnic"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -123,9 +125,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % g3.get_ip("guestnic", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, g3.get_ip("guestnic", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -135,9 +137,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % g3.get_ip("guestnic", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, g3.get_ip("guestnic", 1))
})
ping_mod_bad = ctl.get_module("IcmpPing",
@@ -245,9 +247,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = g3.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = g3.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and\
@@ -326,9 +328,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = g3.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = g3.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
index 7a5b710..1ce8b36 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
@@ -42,6 +42,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -78,9 +80,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("vlan10"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -89,9 +91,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("vlan10"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -101,9 +103,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("vlan10", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -113,9 +115,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("vlan10", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
ctl.wait(15)
@@ -177,9 +179,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
@@ -256,9 +258,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
index c418ad1..24be22a 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
@@ -42,6 +42,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+nperf_confidence = ctl.get_alias("nperf_confidence")
+nperf_max_runs = int(nperf_confidence.split(",")[1])
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -78,9 +80,9 @@ netperf_cli_tcp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_udp = ctl.get_module("Netperf",
@@ -89,9 +91,9 @@ netperf_cli_udp = ctl.get_module("Netperf",
"netperf_server" : g1.get_ip("guestnic"),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
- "netperf_opts" : "-i 5 -L %s" %
- h2.get_ip("vlan10")
+ "confidence" : nperf_confidence,
+ "netperf_opts" : "-i %s -L %s" %
+ (nperf_max_runs, h2.get_ip("vlan10"))
})
netperf_cli_tcp6 = ctl.get_module("Netperf",
@@ -101,9 +103,9 @@ netperf_cli_tcp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "TCP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
netperf_cli_udp6 = ctl.get_module("Netperf",
@@ -113,9 +115,9 @@ netperf_cli_udp6 = ctl.get_module("Netperf",
g1.get_ip("guestnic", 1),
"duration" : netperf_duration,
"testname" : "UDP_STREAM",
- "confidence" : "99,5",
+ "confidence" : nperf_confidence,
"netperf_opts" :
- "-i 5 -L %s -6" % h2.get_ip("vlan10", 1)
+ "-i %s -L %s -6" % (nperf_max_runs, h2.get_ip("vlan10", 1))
})
ctl.wait(15)
@@ -176,9 +178,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and\
@@ -254,9 +256,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
tcp_res_data = h2.run(netperf_cli_tcp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
udp_res_data = h2.run(netperf_cli_udp6,
- timeout = (netperf_duration + nperf_reserve)*5)
+ timeout = (netperf_duration + nperf_reserve)*nperf_max_runs)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
--
2.1.0
8 years, 7 months
[PATCH 1/4] recipes: extend timeout for all tests in phase1 and phase2
by Jan Tluka
In the recent test runs we have seen timeout issues while running
netperf on baremetal setups. This patch extends the timeout in these
setups as we did in virtual setups.
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
recipes/regression_tests/phase1/3_vlans.py | 8 ++++----
recipes/regression_tests/phase1/3_vlans_over_bond.py | 8 ++++----
recipes/regression_tests/phase1/bonding_test.py | 8 ++++----
.../phase1/virtual_bridge_2_vlans_over_bond.py | 4 ++--
.../phase1/virtual_bridge_vlan_in_guest.py | 8 ++++----
.../phase1/virtual_bridge_vlan_in_host.py | 8 ++++----
recipes/regression_tests/phase2/3_vlans_over_team.py | 8 ++++----
recipes/regression_tests/phase2/team_test.py | 16 ++++++++--------
...virtual_ovs_bridge_2_vlans_over_active_backup_bond.py | 4 ++--
.../phase2/virtual_ovs_bridge_vlan_in_guest.py | 8 ++++----
.../phase2/virtual_ovs_bridge_vlan_in_host.py | 8 ++++----
11 files changed, 44 insertions(+), 44 deletions(-)
diff --git a/recipes/regression_tests/phase1/3_vlans.py b/recipes/regression_tests/phase1/3_vlans.py
index 158816f..e950721 100644
--- a/recipes/regression_tests/phase1/3_vlans.py
+++ b/recipes/regression_tests/phase1/3_vlans.py
@@ -194,8 +194,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -276,8 +276,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/3_vlans_over_bond.py b/recipes/regression_tests/phase1/3_vlans_over_bond.py
index 372c689..92d2344 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/3_vlans_over_bond.py
@@ -196,8 +196,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +278,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/bonding_test.py b/recipes/regression_tests/phase1/bonding_test.py
index 5c4777b..1ed02c0 100644
--- a/recipes/regression_tests/phase1/bonding_test.py
+++ b/recipes/regression_tests/phase1/bonding_test.py
@@ -175,8 +175,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -251,8 +251,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
index c2e9280..860d418 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
@@ -354,9 +354,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = g3.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ udp_res_data = g3.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
index 79cddd3..936ef0e 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
@@ -192,9 +192,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
@@ -275,8 +275,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
index 9a0b6bf..92ba7bb 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
@@ -192,9 +192,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
@@ -275,8 +275,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/3_vlans_over_team.py b/recipes/regression_tests/phase2/3_vlans_over_team.py
index a6dbd49..59e32a6 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_team.py
+++ b/recipes/regression_tests/phase2/3_vlans_over_team.py
@@ -197,8 +197,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +278,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/team_test.py b/recipes/regression_tests/phase2/team_test.py
index 95dcfd8..80cc6e4 100644
--- a/recipes/regression_tests/phase2/team_test.py
+++ b/recipes/regression_tests/phase2/team_test.py
@@ -181,8 +181,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -261,8 +261,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
@@ -370,8 +370,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m1.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m1.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m1.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -450,8 +450,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = m1.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = m1.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = m1.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
index 1f37c55..d7cf68d 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
@@ -322,8 +322,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = g3.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
index fc1f015..7d6d8de 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
@@ -175,8 +175,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
@@ -252,8 +252,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
index 5a6ec5f..d1b407b 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
@@ -174,8 +174,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -250,8 +250,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = int(netperf_duration)*5 + 20)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = int(netperf_duration)*5 + 20)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
--
2.1.0
8 years, 7 months
[PATCH 3/4] recipes: use variable instead of hard coded value for extending timeout of netperf run
by Jan Tluka
The phase1 and phase2 regression tests now take optional alias nperf_reserve
with default value of 20 seconds. Using this alias adds additional reserve to
every netperf run.
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
recipes/regression_tests/phase1/3_vlans.py | 13 +++++++++----
recipes/regression_tests/phase1/3_vlans.xml | 1 +
.../phase1/3_vlans_over_active_backup_bond.xml | 1 +
.../regression_tests/phase1/3_vlans_over_bond.py | 13 +++++++++----
.../phase1/3_vlans_over_round_robin_bond.xml | 1 +
.../regression_tests/phase1/active_backup_bond.xml | 1 +
.../phase1/active_backup_double_bond.xml | 1 +
recipes/regression_tests/phase1/bonding_test.py | 13 +++++++++----
.../regression_tests/phase1/round_robin_bond.xml | 1 +
.../phase1/round_robin_double_bond.xml | 1 +
...rtual_bridge_2_vlans_over_active_backup_bond.xml | 1 +
.../phase1/virtual_bridge_2_vlans_over_bond.py | 14 ++++++++++----
.../phase1/virtual_bridge_vlan_in_guest.py | 14 ++++++++++----
.../phase1/virtual_bridge_vlan_in_guest.xml | 1 +
.../phase1/virtual_bridge_vlan_in_host.py | 14 ++++++++++----
.../phase1/virtual_bridge_vlan_in_host.xml | 1 +
.../phase2/3_vlans_over_active_backup_team.xml | 1 +
.../phase2/3_vlans_over_round_robin_team.xml | 1 +
.../regression_tests/phase2/3_vlans_over_team.py | 13 +++++++++----
.../phase2/active_backup_double_team.xml | 1 +
.../regression_tests/phase2/active_backup_team.xml | 1 +
.../active_backup_team_vs_active_backup_bond.xml | 1 +
.../active_backup_team_vs_round_robin_bond.xml | 1 +
.../phase2/round_robin_double_team.xml | 1 +
.../regression_tests/phase2/round_robin_team.xml | 1 +
.../round_robin_team_vs_active_backup_bond.xml | 1 +
.../phase2/round_robin_team_vs_round_robin_bond.xml | 1 +
recipes/regression_tests/phase2/team_test.py | 21 +++++++++++++--------
...al_ovs_bridge_2_vlans_over_active_backup_bond.py | 13 +++++++++----
...l_ovs_bridge_2_vlans_over_active_backup_bond.xml | 1 +
.../phase2/virtual_ovs_bridge_vlan_in_guest.py | 13 +++++++++----
.../phase2/virtual_ovs_bridge_vlan_in_guest.xml | 1 +
.../phase2/virtual_ovs_bridge_vlan_in_host.py | 13 +++++++++----
.../phase2/virtual_ovs_bridge_vlan_in_host.xml | 1 +
34 files changed, 129 insertions(+), 48 deletions(-)
diff --git a/recipes/regression_tests/phase1/3_vlans.py b/recipes/regression_tests/phase1/3_vlans.py
index 1307162..2be04e7 100644
--- a/recipes/regression_tests/phase1/3_vlans.py
+++ b/recipes/regression_tests/phase1/3_vlans.py
@@ -42,6 +42,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
m1_phy1 = m1.get_interface("eth1")
m1_phy1.set_mtu(mtu)
@@ -194,8 +195,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -276,8 +279,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/3_vlans.xml b/recipes/regression_tests/phase1/3_vlans.xml
index fbbc583..ee4eab5 100644
--- a/recipes/regression_tests/phase1/3_vlans.xml
+++ b/recipes/regression_tests/phase1/3_vlans.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="3_vlans.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/3_vlans_over_active_backup_bond.xml b/recipes/regression_tests/phase1/3_vlans_over_active_backup_bond.xml
index 925d9f1..6101f4c 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_active_backup_bond.xml
+++ b/recipes/regression_tests/phase1/3_vlans_over_active_backup_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="3_vlans_over_active_backup_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/3_vlans_over_bond.py b/recipes/regression_tests/phase1/3_vlans_over_bond.py
index e495d9f..feb9302 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/3_vlans_over_bond.py
@@ -42,6 +42,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
m1_bond = m1.get_interface("test_bond")
m1_bond.set_mtu(mtu)
@@ -196,8 +197,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +281,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/3_vlans_over_round_robin_bond.xml b/recipes/regression_tests/phase1/3_vlans_over_round_robin_bond.xml
index 2fd3ede..da729c2 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_round_robin_bond.xml
+++ b/recipes/regression_tests/phase1/3_vlans_over_round_robin_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="3_vlans_over_round_robin_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/active_backup_bond.xml b/recipes/regression_tests/phase1/active_backup_bond.xml
index cfd44fc..db2772e 100644
--- a/recipes/regression_tests/phase1/active_backup_bond.xml
+++ b/recipes/regression_tests/phase1/active_backup_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/active_backup_double_bond.xml b/recipes/regression_tests/phase1/active_backup_double_bond.xml
index cf83e7a..b9f3006 100644
--- a/recipes/regression_tests/phase1/active_backup_double_bond.xml
+++ b/recipes/regression_tests/phase1/active_backup_double_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_double_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/bonding_test.py b/recipes/regression_tests/phase1/bonding_test.py
index 8217f26..cefea0d 100644
--- a/recipes/regression_tests/phase1/bonding_test.py
+++ b/recipes/regression_tests/phase1/bonding_test.py
@@ -41,6 +41,7 @@ offloads = ["tso", "gro", "gso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -175,8 +176,10 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -251,8 +254,10 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/round_robin_bond.xml b/recipes/regression_tests/phase1/round_robin_bond.xml
index ec43383..66e010c 100644
--- a/recipes/regression_tests/phase1/round_robin_bond.xml
+++ b/recipes/regression_tests/phase1/round_robin_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/round_robin_double_bond.xml b/recipes/regression_tests/phase1/round_robin_double_bond.xml
index c283826..e9003d3 100644
--- a/recipes/regression_tests/phase1/round_robin_double_bond.xml
+++ b/recipes/regression_tests/phase1/round_robin_double_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_double_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_active_backup_bond.xml b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_active_backup_bond.xml
index d11d88a..e5d9d1d 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_active_backup_bond.xml
+++ b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_active_backup_bond.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mtu" value="1500" />
<alias name="mapping_file" value="virtual_bridge_2_vlans_over_active_backup_bond.mapping" />
</define>
diff --git a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
index 8958cb3..dd55166 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
@@ -47,6 +47,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -269,9 +271,11 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
if enable_udp_perf is not None:
- udp_res_data = g3.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -354,9 +358,11 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
if enable_udp_perf is not None:
- udp_res_data = g3.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
index 924e270..af66655 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
@@ -41,6 +41,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -192,9 +194,11 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
@@ -275,8 +279,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.xml b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.xml
index 0e11fbf..a3bfb9f 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.xml
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mtu" value="1500" />
<alias name="mapping_file" value="virtual_bridge_vlan_in_guest.mapping" />
</define>
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
index feb9e54..30979cb 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
@@ -41,6 +41,8 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
+
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -192,9 +194,11 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
@@ -275,8 +279,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.xml b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.xml
index 138ad6d..2d8b862 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.xml
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mtu" value="1500" />
<alias name="mapping_file" value="virtual_bridge_vlan_in_host.mapping" />
</define>
diff --git a/recipes/regression_tests/phase2/3_vlans_over_active_backup_team.xml b/recipes/regression_tests/phase2/3_vlans_over_active_backup_team.xml
index f2cd757..c2eb6f8 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_active_backup_team.xml
+++ b/recipes/regression_tests/phase2/3_vlans_over_active_backup_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="3_vlans_over_active_backup_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/3_vlans_over_round_robin_team.xml b/recipes/regression_tests/phase2/3_vlans_over_round_robin_team.xml
index a03ef5e..daec70b 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_round_robin_team.xml
+++ b/recipes/regression_tests/phase2/3_vlans_over_round_robin_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="3_vlans_over_round_robin_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/3_vlans_over_team.py b/recipes/regression_tests/phase2/3_vlans_over_team.py
index 2188052..7f9a767 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_team.py
+++ b/recipes/regression_tests/phase2/3_vlans_over_team.py
@@ -41,6 +41,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
m1_team = m1.get_interface("test_if")
m1_team.set_mtu(mtu)
@@ -197,8 +198,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +281,10 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/active_backup_double_team.xml b/recipes/regression_tests/phase2/active_backup_double_team.xml
index 900fa0d..2cc911a 100644
--- a/recipes/regression_tests/phase2/active_backup_double_team.xml
+++ b/recipes/regression_tests/phase2/active_backup_double_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_double_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/active_backup_team.xml b/recipes/regression_tests/phase2/active_backup_team.xml
index c3bc6fe..8e5a6ad 100644
--- a/recipes/regression_tests/phase2/active_backup_team.xml
+++ b/recipes/regression_tests/phase2/active_backup_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/active_backup_team_vs_active_backup_bond.xml b/recipes/regression_tests/phase2/active_backup_team_vs_active_backup_bond.xml
index 78fefc1..c373bd1 100644
--- a/recipes/regression_tests/phase2/active_backup_team_vs_active_backup_bond.xml
+++ b/recipes/regression_tests/phase2/active_backup_team_vs_active_backup_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_team_vs_active_backup_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/active_backup_team_vs_round_robin_bond.xml b/recipes/regression_tests/phase2/active_backup_team_vs_round_robin_bond.xml
index 8b438b7..fcfa46a 100644
--- a/recipes/regression_tests/phase2/active_backup_team_vs_round_robin_bond.xml
+++ b/recipes/regression_tests/phase2/active_backup_team_vs_round_robin_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="active_backup_team_vs_round_robin_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/round_robin_double_team.xml b/recipes/regression_tests/phase2/round_robin_double_team.xml
index 817ea72..2a680f5 100644
--- a/recipes/regression_tests/phase2/round_robin_double_team.xml
+++ b/recipes/regression_tests/phase2/round_robin_double_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_double_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/round_robin_team.xml b/recipes/regression_tests/phase2/round_robin_team.xml
index 5834c63..cc3702c 100644
--- a/recipes/regression_tests/phase2/round_robin_team.xml
+++ b/recipes/regression_tests/phase2/round_robin_team.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_team.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/round_robin_team_vs_active_backup_bond.xml b/recipes/regression_tests/phase2/round_robin_team_vs_active_backup_bond.xml
index e3f9b4e..1f18459 100644
--- a/recipes/regression_tests/phase2/round_robin_team_vs_active_backup_bond.xml
+++ b/recipes/regression_tests/phase2/round_robin_team_vs_active_backup_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_team_vs_active_backup_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/round_robin_team_vs_round_robin_bond.xml b/recipes/regression_tests/phase2/round_robin_team_vs_round_robin_bond.xml
index 9ba661a..bcdd111 100644
--- a/recipes/regression_tests/phase2/round_robin_team_vs_round_robin_bond.xml
+++ b/recipes/regression_tests/phase2/round_robin_team_vs_round_robin_bond.xml
@@ -3,6 +3,7 @@
<alias name="ipv" value="both" />
<alias name="mtu" value="1500" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="round_robin_team_vs_round_robin_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/team_test.py b/recipes/regression_tests/phase2/team_test.py
index 20c7ee1..259505b 100644
--- a/recipes/regression_tests/phase2/team_test.py
+++ b/recipes/regression_tests/phase2/team_test.py
@@ -41,6 +41,7 @@ offloads = ["tso", "gro", "gso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -181,8 +182,10 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -261,8 +264,10 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
@@ -370,8 +375,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = m1.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m1.run(netperf_cli_tcp, timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m1.run(netperf_cli_udp, timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -450,8 +455,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = m1.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = m1.run(netperf_cli_tcp6, timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = m1.run(netperf_cli_udp6, timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
index 8297a58..3d0a828 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
@@ -47,6 +47,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -243,8 +244,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = g3.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = g3.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -322,8 +325,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = g3.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = g3.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.xml b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.xml
index 95e1c20..07e0d14 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.xml
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="virtual_ovs_bridge_2_vlans_over_active_backup_bond.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
index 1d26410..7a5b710 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
@@ -41,6 +41,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -175,8 +176,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
@@ -252,8 +255,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.xml b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.xml
index beb75d2..eead7a9 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.xml
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="virtual_ovs_bridge_vlan_in_guest.mapping" />
</define>
<network>
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
index 86cb460..c418ad1 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
@@ -41,6 +41,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
netperf_duration = int(ctl.get_alias("netperf_duration"))
+nperf_reserve = int(ctl.get_alias("nperf_reserve"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -174,8 +175,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -250,8 +253,10 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
+ udp_res_data = h2.run(netperf_cli_udp6,
+ timeout = (netperf_duration + nperf_reserve)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.xml b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.xml
index e931335..b31f8e1 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.xml
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.xml
@@ -2,6 +2,7 @@
<define>
<alias name="ipv" value="both" />
<alias name="netperf_duration" value="60" />
+ <alias name="nperf_reserve" value="20" />
<alias name="mapping_file" value="virtual_ovs_bridge_vlan_in_host.mapping" />
</define>
<network>
--
2.1.0
8 years, 7 months
[PATCH 2/4] recipes: convert netperf_duration to integer in regression tests sooner
by Jan Tluka
Moving the conversion of netperf_duration alias to the beginning of the
python task. Looks prettier and does not have to be done every time the
variable gets referenced.
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
recipes/regression_tests/phase1/3_vlans.py | 10 +++++-----
recipes/regression_tests/phase1/3_vlans_over_bond.py | 10 +++++-----
recipes/regression_tests/phase1/bonding_test.py | 10 +++++-----
.../phase1/virtual_bridge_2_vlans_over_bond.py | 10 +++++-----
.../phase1/virtual_bridge_vlan_in_guest.py | 10 +++++-----
.../phase1/virtual_bridge_vlan_in_host.py | 10 +++++-----
recipes/regression_tests/phase2/3_vlans_over_team.py | 10 +++++-----
recipes/regression_tests/phase2/team_test.py | 18 +++++++++---------
...rtual_ovs_bridge_2_vlans_over_active_backup_bond.py | 10 +++++-----
.../phase2/virtual_ovs_bridge_vlan_in_guest.py | 10 +++++-----
.../phase2/virtual_ovs_bridge_vlan_in_host.py | 10 +++++-----
11 files changed, 59 insertions(+), 59 deletions(-)
diff --git a/recipes/regression_tests/phase1/3_vlans.py b/recipes/regression_tests/phase1/3_vlans.py
index e950721..1307162 100644
--- a/recipes/regression_tests/phase1/3_vlans.py
+++ b/recipes/regression_tests/phase1/3_vlans.py
@@ -41,7 +41,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
m1_phy1 = m1.get_interface("eth1")
m1_phy1.set_mtu(mtu)
@@ -194,8 +194,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -276,8 +276,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/3_vlans_over_bond.py b/recipes/regression_tests/phase1/3_vlans_over_bond.py
index 92d2344..e495d9f 100644
--- a/recipes/regression_tests/phase1/3_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/3_vlans_over_bond.py
@@ -41,7 +41,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
m1_bond = m1.get_interface("test_bond")
m1_bond.set_mtu(mtu)
@@ -196,8 +196,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +278,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/bonding_test.py b/recipes/regression_tests/phase1/bonding_test.py
index 1ed02c0..8217f26 100644
--- a/recipes/regression_tests/phase1/bonding_test.py
+++ b/recipes/regression_tests/phase1/bonding_test.py
@@ -40,7 +40,7 @@ offloads = ["tso", "gro", "gso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -175,8 +175,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -251,8 +251,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
index 860d418..8958cb3 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_2_vlans_over_bond.py
@@ -46,7 +46,7 @@ g4.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -269,9 +269,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = g3.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -354,9 +354,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = g3.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
index 936ef0e..924e270 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_guest.py
@@ -40,7 +40,7 @@ h2.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -192,9 +192,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
@@ -275,8 +275,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
index 92ba7bb..feb9e54 100644
--- a/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase1/virtual_bridge_vlan_in_host.py
@@ -40,7 +40,7 @@ h2.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
mtu = ctl.get_alias("mtu")
enable_udp_perf = ctl.get_alias("enable_udp_perf")
@@ -192,9 +192,9 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
if enable_udp_perf is not None:
- udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
@@ -275,8 +275,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/3_vlans_over_team.py b/recipes/regression_tests/phase2/3_vlans_over_team.py
index 59e32a6..2188052 100644
--- a/recipes/regression_tests/phase2/3_vlans_over_team.py
+++ b/recipes/regression_tests/phase2/3_vlans_over_team.py
@@ -40,7 +40,7 @@ offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
m1_team = m1.get_interface("test_if")
m1_team.set_mtu(mtu)
@@ -197,8 +197,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and\
@@ -278,8 +278,8 @@ for vlan1 in vlans:
# Netperf test (both TCP and UDP)
srv_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
srv_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/team_test.py b/recipes/regression_tests/phase2/team_test.py
index 80cc6e4..20c7ee1 100644
--- a/recipes/regression_tests/phase2/team_test.py
+++ b/recipes/regression_tests/phase2/team_test.py
@@ -40,7 +40,7 @@ offloads = ["tso", "gro", "gso"]
ipv = ctl.get_alias("ipv")
mtu = ctl.get_alias("mtu")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
test_if1 = m1.get_interface("test_if")
test_if1.set_mtu(mtu)
@@ -181,8 +181,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -261,8 +261,8 @@ for offload in offloads:
server_proc = m1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
@@ -370,8 +370,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m1.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m1.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m1.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -450,8 +450,8 @@ for offload in offloads:
server_proc = m2.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = m1.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = m1.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = m1.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = m1.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
index d7cf68d..8297a58 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_2_vlans_over_active_backup_bond.py
@@ -46,7 +46,7 @@ g4.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -243,8 +243,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = g3.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -322,8 +322,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = g3.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = g3.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = g3.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
index 7d6d8de..1d26410 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_guest.py
@@ -40,7 +40,7 @@ h2.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -175,8 +175,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
@@ -252,8 +252,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
diff --git a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
index d1b407b..86cb460 100644
--- a/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
+++ b/recipes/regression_tests/phase2/virtual_ovs_bridge_vlan_in_host.py
@@ -40,7 +40,7 @@ h2.sync_resources(modules=["IcmpPing", "Icmp6Ping", "Netperf"])
offloads = ["gso", "gro", "tso"]
ipv = ctl.get_alias("ipv")
-netperf_duration = ctl.get_alias("netperf_duration")
+netperf_duration = int(ctl.get_alias("netperf_duration"))
ping_mod = ctl.get_module("IcmpPing",
options={
@@ -174,8 +174,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and\
@@ -250,8 +250,8 @@ for offload in offloads:
server_proc = g1.run(netperf_srv6, bg=True)
ctl.wait(2)
- tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (int(netperf_duration) + 20)*5)
- udp_res_data = h2.run(netperf_cli_udp6, timeout = (int(netperf_duration) + 20)*5)
+ tcp_res_data = h2.run(netperf_cli_tcp6, timeout = (netperf_duration + 20)*5)
+ udp_res_data = h2.run(netperf_cli_udp6, timeout = (netperf_duration + 20)*5)
server_proc.intr()
if result_tcp is not None and tcp_res_data.get_result() is not None and\
--
2.1.0
8 years, 7 months
[PATCH] NetConfigDevice: don't set loopback device down
by Jan Tluka
We do not want to bring loopback device down in root namespace as
this might have an unpredictable impact on further testing.
In case of non-root namespace leaving loopback device up is not
a problem since the namespace will get destroyed after recipe is
finished anyway.
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
lnst/Slave/NetConfigDevice.py | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/lnst/Slave/NetConfigDevice.py b/lnst/Slave/NetConfigDevice.py
index 0fbc3f0..1422850 100644
--- a/lnst/Slave/NetConfigDevice.py
+++ b/lnst/Slave/NetConfigDevice.py
@@ -97,6 +97,14 @@ class NetConfigDeviceLoopback(NetConfigDeviceGeneric):
def configure(self):
config = self._dev_config
+ def down(self):
+ # We do not want to bring loopback device down in root namespace as
+ # this might have an unpredictable impact on further testing.
+ # In case of non-root namespace leaving loopback device up is not
+ # a problem since the namespace will get destroyed after recipe is
+ # finished
+ pass
+
class NetConfigDeviceBond(NetConfigDeviceGeneric):
_modulename = "bonding"
_moduleparams = "max_bonds=0"
--
2.1.0
8 years, 7 months
[PATCH 1/2] Controller: Add get_driver method to the Interface class
by Jiri Prochazka
We want to be able to get driver info in non-virtual interfaces as well,
so we can add get_driver method to the Interface class
Signed-off-by: Jiri Prochazka <jprochaz(a)redhat.com>
---
lnst/Controller/Machine.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lnst/Controller/Machine.py b/lnst/Controller/Machine.py
index 14a8061..bdb4d84 100644
--- a/lnst/Controller/Machine.py
+++ b/lnst/Controller/Machine.py
@@ -542,6 +542,9 @@ class Interface(object):
def get_id(self):
return self._id
+ def get_driver(self):
+ return self._driver
+
def set_hwaddr(self, hwaddr):
self._hwaddr = normalize_hwaddr(hwaddr)
--
2.4.3
8 years, 7 months
[PATCH v3 1/9] pool-wizard: Add new line in error message of _create_dir method
by Jiri Prochazka
New line was missing in print of an error message of _create_dir method
Signed-off-by: Jiri Prochazka <jprochaz(a)redhat.com>
---
lnst/Controller/Wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lnst/Controller/Wizard.py b/lnst/Controller/Wizard.py
index f2c645c..51856e8 100644
--- a/lnst/Controller/Wizard.py
+++ b/lnst/Controller/Wizard.py
@@ -186,7 +186,7 @@ class Wizard:
print("Dir '%s' has been created" % pool_dir)
return pool_dir
except:
- sys.stderr.write("Failed creating dir")
+ sys.stderr.write("Failed creating dir\n")
return None
def _create_xml(self, machine_interfaces, hostname,
--
2.4.3
8 years, 7 months
[PATCH 1/3] Utils: Add LNST version variable and set it to 8.0
by Jiri Prochazka
This patch introduces new style of versioning of LNST.
We will now use Major+minor style of versions, where major versions
are based on major releases of our RPM packages and minor versions
are only distinguished in devel GIT versions.
The version starts on 8.0
Each time a change is introduced, which may cause invalid behaviour
when used with older version, developer should also increment minor
version in this variable.
Signed-off-by: Jiri Prochazka <jprochaz(a)redhat.com>
---
lnst/Common/Utils.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lnst/Common/Utils.py b/lnst/Common/Utils.py
index cb2272d..ea80a02 100644
--- a/lnst/Common/Utils.py
+++ b/lnst/Common/Utils.py
@@ -24,6 +24,8 @@ import math
from _ast import Call, Attribute
from lnst.Common.ExecCmd import exec_cmd
+LNST_VERSION = 8.0
+
def die_when_parent_die():
try:
import ctypes
--
2.4.3
8 years, 7 months
issue #136 - RFC
by Jiri Prochazka
Hello,
I'd like to ask you about your opinion of the issue #136 [1].
The first idea me and Jan had was this:
- Compute MD5 hash of files lnst-ctl, lnst-slave and all .py files in LNST
modules directory
- Compare it via hello message between Slave and Controller
- If hashes mismatch, end with an error
However, there is a problem with path of the binary and module files.
When we are running LNST from git, lnst-ctl, lnst-slave and modules are all
in the same directory.
When we are running LNST from RPM or installation from git, binaries are in
/usr/bin/ or /bin/ and modules are in /usr/share/lnst/.
I've came up with following approach to this, described in [2]. This way,
mixing of git and RPM is allowed, as long as all the important files are
the same.
When the hashes are calculated, they are compared within the hello() method
on Controller.
If you have any better solution or comments to this, both are very welcome
[1] https://github.com/jpirko/lnst/issues/136
[2] https://ctrlv.cz/7RgT
Best regards,
Jiri Prochazka
LNST Developer
| www.lnst-project.org
+420 532 294 633 | jprochaz(a)redhat.com
Red Hat Czech | Purkyňova 71/99, 612 00 Brno
8 years, 7 months
[PATCH v2 1/8] pool-wizard: Add new line in error message of _create_dir method
by Jiri Prochazka
New line was missing in print of an error message of _create_dir method
Signed-off-by: Jiri Prochazka <jprochaz(a)redhat.com>
---
lnst/Controller/Wizard.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lnst/Controller/Wizard.py b/lnst/Controller/Wizard.py
index f2c645c..51856e8 100644
--- a/lnst/Controller/Wizard.py
+++ b/lnst/Controller/Wizard.py
@@ -186,7 +186,7 @@ class Wizard:
print("Dir '%s' has been created" % pool_dir)
return pool_dir
except:
- sys.stderr.write("Failed creating dir")
+ sys.stderr.write("Failed creating dir\n")
return None
def _create_xml(self, machine_interfaces, hostname,
--
2.4.3
8 years, 7 months