Using secureCopy to copy mininet topology to mininet machine
Change-Id: I0ffff4c38d11db188f2c39957e139856e1c67b28
diff --git a/TestON/tests/CHOtest/CHOtest.params b/TestON/tests/CHOtest/CHOtest.params
index 44a9858..fe54e05 100644
--- a/TestON/tests/CHOtest/CHOtest.params
+++ b/TestON/tests/CHOtest/CHOtest.params
@@ -26,7 +26,7 @@
</CTRL>
<TOPO1>
- <topo>~/TestON/tests/CHOtest/Dependencies/topoAtt.py</topo>
+ <topo>topoAtt.py</topo>
<numSwitches>25</numSwitches>
<numHosts>25</numHosts>
<numLinks>114</numLinks>
@@ -34,7 +34,7 @@
</TOPO1>
<TOPO2>
- <topo>~/TestON/tests/CHOtest/Dependencies/topoChordal.py</topo>
+ <topo>topoChordal.py</topo>
<numSwitches>25</numSwitches>
<numHosts>25</numHosts>
<numLinks>600</numLinks>
@@ -42,7 +42,7 @@
</TOPO2>
<TOPO3>
- <topo>~/TestON/tests/CHOtest/Dependencies/topoSpine.py</topo>
+ <topo>topoSpine.py</topo>
<numSwitches>78</numSwitches>
<numHosts>68</numHosts>
<numLinks>284</numLinks>
diff --git a/TestON/tests/CHOtest/CHOtest.py b/TestON/tests/CHOtest/CHOtest.py
index 140d089..6e58b68 100644
--- a/TestON/tests/CHOtest/CHOtest.py
+++ b/TestON/tests/CHOtest/CHOtest.py
@@ -176,7 +176,11 @@
main.step( "Start Mininet with Att topology" )
main.newTopo = main.params['TOPO1']['topo']
- startStatus = main.Mininet1.startNet(topoFile = main.newTopo)
+ mininetDir = main.Mininet1.home + "/custom/"
+ topoPath = main.testDir + "/" + main.TEST + "/Dependencies/" + main.newTopo
+ main.ONOSbench.secureCopy(main.Mininet1.user_name, main.Mininet1.ip_address, topoPath, mininetDir, direction="to")
+ topoPath = mininetDir + main.newTopo
+ startStatus = main.Mininet1.startNet(topoFile = topoPath)
main.step( "Assign switches to controllers" )
for i in range( 1, ( main.numMNswitches + 1 ) ): # 1 to ( num of switches +1 )
@@ -237,8 +241,12 @@
main.step( "Stop any previous Mininet network topology" )
stopStatus = main.Mininet1.stopNet(fileName = "topoAtt" )
- main.step( "Start Mininet with Chordal topology" )
- startStatus = main.Mininet1.startNet(topoFile = main.newTopo)
+ main.step("Start Mininet with Chordal topology")
+ mininetDir = main.Mininet1.home + "/custom/"
+ topoPath = main.testDir + "/" + main.TEST + "/Dependencies/" + main.newTopo
+ main.ONOSbench.secureCopy(main.Mininet1.user_name, main.Mininet1.ip_address, topoPath, mininetDir, direction="to")
+ topoPath = mininetDir + main.newTopo
+ startStatus = main.Mininet1.startNet(topoFile = topoPath)
main.step( "Assign switches to controllers" )
@@ -296,8 +304,14 @@
"Assign and Balance all Mininet switches across controllers" )
main.step( "Stop any previous Mininet network topology" )
stopStatus = main.Mininet1.stopNet(fileName = "topoChordal" )
- main.step( "Start Mininet with Spine topology" )
- startStatus = main.Mininet1.startNet(topoFile = main.newTopo)
+
+ main.step("Start Mininet with Spine topology")
+ mininetDir = main.Mininet1.home + "/custom/"
+ topoPath = main.testDir + "/" + main.TEST + "/Dependencies/" + main.newTopo
+ main.ONOSbench.secureCopy(main.Mininet1.user_name, main.Mininet1.ip_address, topoPath, mininetDir, direction="to")
+ topoPath = mininetDir + main.newTopo
+ startStatus = main.Mininet1.startNet(topoFile = topoPath)
+
time.sleep(60)
main.step( "Assign switches to controllers" )
@@ -2123,6 +2137,7 @@
def CASE10( self ):
import time
+ import re
"""
Remove all Intents
"""