Configuration file for event accumulator settings now adjusts according to specific test
diff --git a/TestON/tests/TopoConvNext/TopoConvNext.params b/TestON/tests/TopoConvNext/TopoConvNext.params
index a7a5ac6..f96123a 100644
--- a/TestON/tests/TopoConvNext/TopoConvNext.params
+++ b/TestON/tests/TopoConvNext/TopoConvNext.params
@@ -1,5 +1,5 @@
<PARAMS>
- <testcases>1,2,3,2,3,2</testcases>
+ <testcases>1,2,3,2,3,2,4,2,3,2,3,2,4,2,3,2,3,2</testcases>
<ENV>
<cellName>topo_conv_test</cellName>
@@ -43,9 +43,20 @@
#Number of times to iterate each case
<numIter>10</numIter>
- <numSwitch>100</numSwitch>
+ <numSwitch1>100</numSwitch1>
+ <numSwitch2>200</numSwitch2>
+ <numSwitch3>500</numSwitch3>
#Number of iterations to ignore initially
- <iterIgnore>0</iterIgnore>
+ <iterIgnore>2</iterIgnore>
+cp single_topo_event_accumulator.cfg ~/ONOS/tools/package/etc/org.onlab.onos.net.topology.impl.DefaultTopologyProvider.cfg
+
+ <topo_accumulator_config>
+ large_topo_event_accumulator.cfg
+ </topo_accumulator_config>
+ <topo_config_name>
+ org.onlab.onos.net.topology.impl.DefaultTopologyProvider.cfg
+ </topo_config_name>
+
<swDisc100Threshold>0,100000</swDisc100Threshold>
</TEST>
diff --git a/TestON/tests/TopoConvNext/TopoConvNext.py b/TestON/tests/TopoConvNext/TopoConvNext.py
index c0f2415..4b8042c 100644
--- a/TestON/tests/TopoConvNext/TopoConvNext.py
+++ b/TestON/tests/TopoConvNext/TopoConvNext.py
@@ -47,6 +47,16 @@
BENCH_ip = main.params['BENCH']['ip']
main.case("Setting up test environment")
+ main.step("copying topology event accumulator config file"+
+ " to ONOS package/etc/ directory")
+ topo_config_name = main.params['TEST']['topo_config_name']
+ topo_config =\
+ main.params['TEST']['topo_accumulator_config']
+ main.ONOSbench.handle.sendline("cp ~/"+topo_config+
+ " ~/ONOS/tools/package/etc/"+
+ topo_config_name)
+ main.ONOSbench.handle.expect("\$")
+
main.log.info("Uninstalling previous instances")
#main.ONOSbench.onos_uninstall(node_ip = ONOS1_ip)
#main.ONOSbench.onos_uninstall(node_ip = ONOS2_ip)
@@ -159,7 +169,8 @@
#Number of iterations of case
num_iter = main.params['TEST']['numIter']
-
+ iter_ignore = int(main.params['TEST']['iterIgnore'])
+
#***********
#Global number of switches that change
#throughout the test
@@ -197,7 +208,8 @@
for node in range(1, cluster_count+1):
report_str += (str(node) + " ")
main.log.report(report_str)
-
+ main.log.report("Topology size: "+str(num_sw)+" switches")
+
main.step("Distributing "+num_sw+" switches to each ONOS")
index = 1
for node in range(1, cluster_count+1):
@@ -461,7 +473,8 @@
int(graph_timestamp_1) - int(t0_system)
if graph_lat_1 > sw_disc_threshold_min\
- and graph_lat_1 < sw_disc_threshold_max:
+ and graph_lat_1 < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
graph_lat_1)
main.log.info("Sw discovery latency of "+
@@ -499,7 +512,8 @@
int(graph_lat_2)) / 2
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -553,7 +567,8 @@
int(graph_lat_3)) / 3
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -607,7 +622,8 @@
int(graph_lat_4)) / 4
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -675,7 +691,8 @@
int(graph_lat_5)) / 5
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -745,7 +762,8 @@
int(graph_lat_6)) / 6
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -830,7 +848,8 @@
int(graph_lat_7)) / 7
if avg_graph_lat > sw_disc_threshold_min\
- and avg_graph_lat < sw_disc_threshold_max:
+ and avg_graph_lat < sw_disc_threshold_max\
+ and int(i) > iter_ignore:
sw_discovery_lat_list.append(
avg_graph_lat)
main.log.info("Sw discovery latency of "+
@@ -947,11 +966,10 @@
"(last sw SYN/ACK time - first sw SYN/ACK time) "+
str(sum(syn_ack_delta_list)/len(syn_ack_delta_list)) +
" ms")
- main.log.report("Switch discovery lat for "+\
- str(cluster_count)+" instance(s), 100 sw each: ")
- main.log.report("Avg: "+str(sw_lat_avg)+" ms")
- main.log.report("Std Deviation: "+
- str(round(sw_lat_dev,1))+" ms")
+ main.log.report(str(num_sw)+" Switch discovery lat for "+\
+ str(cluster_count)+" instance(s): ")
+ main.log.report("Avg: "+str(sw_lat_avg)+" ms "+
+ "Std Deviation: "+str(round(sw_lat_dev,1))+" ms")
utilities.assert_equals(expect=main.TRUE, actual=assertion,
onpass="Switch discovery convergence latency" +\
@@ -987,9 +1005,11 @@
#cluster count and start from 3.
#You can optionally change the increment to
#test steps of node sizes, such as 3,5,7
-
+
global cluster_count
cluster_count += 2
+ main.log.report("Increasing cluster size to "+
+ str(cluster_count))
install_result = main.FALSE
#Supports up to 7 node configuration
@@ -1077,6 +1097,8 @@
'''
Cleanup ONOS nodes and Increase topology size
'''
+ #TODO: use meaningful assertion
+ assertion=main.TRUE
ONOS1_ip = main.params['CTRL']['ip1']
ONOS2_ip = main.params['CTRL']['ip2']
@@ -1099,4 +1121,7 @@
cluster_count = 3
topo_iteration += 1
-
+ main.log.report("Increasing topology size")
+ utilities.assert_equals(expect=main.TRUE, actual=assertion,
+ onpass="Topology size increased successfully",
+ onfail="Topology size was not increased")
diff --git a/TestON/tests/TopoConvNext/TopoConvNext.topo b/TestON/tests/TopoConvNext/TopoConvNext.topo
index 855e688..b7e9e96 100644
--- a/TestON/tests/TopoConvNext/TopoConvNext.topo
+++ b/TestON/tests/TopoConvNext/TopoConvNext.topo
@@ -143,7 +143,7 @@
<type>MininetCliDriver</type>
<connect_order>16</connect_order>
<COMPONENTS>
- <arg1> --custom topo-700sw.py </arg1>
+ <arg1> --custom topo-500sw.py </arg1>
<arg2> --arp --mac --topo mytopo</arg2>
<arg3> </arg3>
<controller> remote </controller>
diff --git a/TestON/tests/TopoPerfNext/TopoPerfNext.params b/TestON/tests/TopoPerfNext/TopoPerfNext.params
index 7eac6ef..42512e8 100644
--- a/TestON/tests/TopoPerfNext/TopoPerfNext.params
+++ b/TestON/tests/TopoPerfNext/TopoPerfNext.params
@@ -1,5 +1,5 @@
<PARAMS>
- <testcases>1,2,3,4</testcases>
+ <testcases>1,2,3</testcases>
<ENV>
<cellName>topo_perf_test</cellName>
@@ -38,6 +38,13 @@
<debugMode>off</debugMode>
<onosLogFile>/opt/onos/log/karaf*</onosLogFile>
+ <topo_config_file>
+ single_topo_event_accumulator.cfg
+ </topo_config_file>
+ <topo_config_name>
+ org.onlab.onos.net.topology.impl.DefaultTopologyProvider.cfg
+ </topo_config_name>
+
#Number of times to iterate each case
<numIter>20</numIter>
<numSwitch>2</numSwitch>
diff --git a/TestON/tests/TopoPerfNext/TopoPerfNext.py b/TestON/tests/TopoPerfNext/TopoPerfNext.py
index 21f5f44..0ec69d2 100644
--- a/TestON/tests/TopoPerfNext/TopoPerfNext.py
+++ b/TestON/tests/TopoPerfNext/TopoPerfNext.py
@@ -42,7 +42,18 @@
MN1_ip = main.params['MN']['ip1']
BENCH_ip = main.params['BENCH']['ip']
+ topo_cfg_file = main.params['TEST']['topo_config_file']
+ topo_cfg_name = main.params['TEST']['topo_config_name']
+
main.case("Setting up test environment")
+ main.step("Copying topology event accumulator config file to "+
+ "ONOS /package/etc")
+ main.ONOSbench.handle.sendline("cp ~/"+
+ topo_cfg_file+
+ "~/ONOS/tools/package/etc/"+
+ topo_cfg_name)
+ main.ONOSbench.handle.expect("\$")
+
main.log.report("Setting up test environment")
main.step("Cleaning previously installed ONOS if any")