Stop Karaf logging INFO messages to the console
Change-Id: I770ccbd852958f7ef543ac8f62f3a2edb0c12bcd
diff --git a/TestON/tests/HA/HAbackupRecover/HAbackupRecover.py b/TestON/tests/HA/HAbackupRecover/HAbackupRecover.py
index 7010f93..e6ba11e 100644
--- a/TestON/tests/HA/HAbackupRecover/HAbackupRecover.py
+++ b/TestON/tests/HA/HAbackupRecover/HAbackupRecover.py
@@ -88,14 +88,15 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
+ applyFuncs = [ main.HA.removeKarafConsoleLogging ]
+
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
- applyFuncs = None
else:
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
except (KeyError, IndexError):
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
main.testSetUp.ONOSSetUp( main.Cluster, cellName=cellName, extraApply=applyFuncs )
diff --git a/TestON/tests/HA/HAclusterRestart/HAclusterRestart.py b/TestON/tests/HA/HAclusterRestart/HAclusterRestart.py
index 14a0898..35800d2 100644
--- a/TestON/tests/HA/HAclusterRestart/HAclusterRestart.py
+++ b/TestON/tests/HA/HAclusterRestart/HAclusterRestart.py
@@ -88,14 +88,15 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
+ applyFuncs = [ main.HA.removeKarafConsoleLogging ]
+
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
- applyFuncs = None
else:
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
except (KeyError, IndexError):
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
main.testSetUp.ONOSSetUp( main.Cluster, cellName=cellName, extraApply=applyFuncs )
diff --git a/TestON/tests/HA/HAcontinuousStopNodes/HAcontinuousStopNodes.py b/TestON/tests/HA/HAcontinuousStopNodes/HAcontinuousStopNodes.py
index 277e098..d770e83 100644
--- a/TestON/tests/HA/HAcontinuousStopNodes/HAcontinuousStopNodes.py
+++ b/TestON/tests/HA/HAcontinuousStopNodes/HAcontinuousStopNodes.py
@@ -91,8 +91,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.customizeOnosGenPartitions, main.HA.copyBackupConfig ]
- applyArgs = [ None, None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.customizeOnosGenPartitions, main.HA.copyBackupConfig ]
+ applyArgs = [ None, None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAfullNetPartition/HAfullNetPartition.py b/TestON/tests/HA/HAfullNetPartition/HAfullNetPartition.py
index e3daf8e..9020edc 100644
--- a/TestON/tests/HA/HAfullNetPartition/HAfullNetPartition.py
+++ b/TestON/tests/HA/HAfullNetPartition/HAfullNetPartition.py
@@ -90,8 +90,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.customizeOnosGenPartitions ]
- applyArgs = [ None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.customizeOnosGenPartitions ]
+ applyArgs = [ None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAkillNodes/HAkillNodes.py b/TestON/tests/HA/HAkillNodes/HAkillNodes.py
index 560b785..1be271f 100644
--- a/TestON/tests/HA/HAkillNodes/HAkillNodes.py
+++ b/TestON/tests/HA/HAkillNodes/HAkillNodes.py
@@ -88,10 +88,11 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.customizeOnosGenPartitions,
+ applyFuncs = [ main.HA.removeKarafConsoleLogging,
+ main.HA.customizeOnosGenPartitions,
main.HA.copyBackupConfig,
main.ONOSbench.preventAutoRespawn ]
- applyArgs = [ None, None, None ]
+ applyArgs = [ None, None, None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HApowerFailure/HApowerFailure.py b/TestON/tests/HA/HApowerFailure/HApowerFailure.py
index 85801e0..aa04792 100644
--- a/TestON/tests/HA/HApowerFailure/HApowerFailure.py
+++ b/TestON/tests/HA/HApowerFailure/HApowerFailure.py
@@ -88,10 +88,11 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.customizeOnosGenPartitions,
+ applyFuncs = [ main.HA.removeKarafConsoleLogging,
+ main.HA.customizeOnosGenPartitions,
main.HA.copyBackupConfig,
main.ONOSbench.preventAutoRespawn ]
- applyArgs = [ None, None, None ]
+ applyArgs = [ None, None, None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAsanity/HAsanity.py b/TestON/tests/HA/HAsanity/HAsanity.py
index b6d00c0..eecd0f1 100644
--- a/TestON/tests/HA/HAsanity/HAsanity.py
+++ b/TestON/tests/HA/HAsanity/HAsanity.py
@@ -87,14 +87,15 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
+ applyFuncs = [ main.HA.removeKarafConsoleLogging ]
+
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
- applyFuncs = None
else:
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
except (KeyError, IndexError):
- applyFuncs = main.HA.startingMininet
+ applyFuncs.append( main.HA.startingMininet )
main.testSetUp.ONOSSetUp( main.Cluster, cellName=cellName,
extraApply=applyFuncs, stopAtomix=True,
diff --git a/TestON/tests/HA/HAscaling/HAscaling.py b/TestON/tests/HA/HAscaling/HAscaling.py
index 6929ae7..19b0ec3 100644
--- a/TestON/tests/HA/HAscaling/HAscaling.py
+++ b/TestON/tests/HA/HAscaling/HAscaling.py
@@ -97,8 +97,8 @@
main.log.debug( scale )
main.Cluster.setRunningNode( int( re.search( "\d+", scale ).group( 0 ) ) )
- applyFuncs = []
- applyArgs = []
+ applyFuncs = [ main.HA.removeKarafConsoleLogging ]
+ applyArgs = [ None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAsingleInstanceRestart/HAsingleInstanceRestart.py b/TestON/tests/HA/HAsingleInstanceRestart/HAsingleInstanceRestart.py
index af383f1..c23284b 100644
--- a/TestON/tests/HA/HAsingleInstanceRestart/HAsingleInstanceRestart.py
+++ b/TestON/tests/HA/HAsingleInstanceRestart/HAsingleInstanceRestart.py
@@ -92,9 +92,9 @@
main.testSetUp.evnSetupConclusion( stepResult )
cellApps = str( main.params["ENV"]["appString"] )
- cellNAme = str( main.params["ENV"]["appString"] )
- applyFuncs = [ main.testSetUp.createApplyCell ]
- applyArgs = [ [ main.Cluster, True, cellName , cellApps, "", True, main.Cluster.runningNodes[ 0 ].ipAddress ] ]
+ cellName = str( main.params["ENV"]["appString"] )
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.testSetUp.createApplyCell ]
+ applyArgs = [ None, [ main.Cluster, True, cellName , cellApps, "", True, main.Cluster.runningNodes[ 0 ].ipAddress ] ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAstopNodes/HAstopNodes.py b/TestON/tests/HA/HAstopNodes/HAstopNodes.py
index 998f29c..0c6c7d0 100644
--- a/TestON/tests/HA/HAstopNodes/HAstopNodes.py
+++ b/TestON/tests/HA/HAstopNodes/HAstopNodes.py
@@ -88,8 +88,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.customizeOnosGenPartitions, main.HA.copyBackupConfig ]
- applyArgs = [ None, None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.customizeOnosGenPartitions, main.HA.copyBackupConfig ]
+ applyArgs = [ None, None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAswapNodes/HAswapNodes.py b/TestON/tests/HA/HAswapNodes/HAswapNodes.py
index 52da8ed..e2efe92 100644
--- a/TestON/tests/HA/HAswapNodes/HAswapNodes.py
+++ b/TestON/tests/HA/HAswapNodes/HAswapNodes.py
@@ -89,8 +89,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.swapNodeMetadata ]
- applyArgs = [ None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.swapNodeMetadata ]
+ applyArgs = [ None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAupgrade/HAupgrade.py b/TestON/tests/HA/HAupgrade/HAupgrade.py
index f71cf79..cea03c8 100644
--- a/TestON/tests/HA/HAupgrade/HAupgrade.py
+++ b/TestON/tests/HA/HAupgrade/HAupgrade.py
@@ -92,8 +92,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.copyBackupConfig ]
- applyArgs = [ None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.copyBackupConfig ]
+ applyArgs = [ None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/HAupgradeRollback/HAupgradeRollback.py b/TestON/tests/HA/HAupgradeRollback/HAupgradeRollback.py
index db5e503..f5ae894 100644
--- a/TestON/tests/HA/HAupgradeRollback/HAupgradeRollback.py
+++ b/TestON/tests/HA/HAupgradeRollback/HAupgradeRollback.py
@@ -92,8 +92,8 @@
main.testSetUp.envSetupException( e )
main.testSetUp.evnSetupConclusion( stepResult )
- applyFuncs = [ main.HA.copyBackupConfig ]
- applyArgs = [ None ]
+ applyFuncs = [ main.HA.removeKarafConsoleLogging, main.HA.copyBackupConfig ]
+ applyArgs = [ None, None ]
try:
if main.params[ 'topology' ][ 'topoFile' ]:
main.log.info( 'Skipping start of Mininet in this case, make sure you start it elsewhere' )
diff --git a/TestON/tests/HA/dependencies/HA.py b/TestON/tests/HA/dependencies/HA.py
index 4342f96..c809ffe 100644
--- a/TestON/tests/HA/dependencies/HA.py
+++ b/TestON/tests/HA/dependencies/HA.py
@@ -30,6 +30,12 @@
self.default = ''
main.topoMappings = {}
+ def removeKarafConsoleLogging( self ):
+ main.ONOSbench.handle.sendline( "cd " + main.ONOSbench.home )
+ main.ONOSbench.handle.expect( main.ONOSbench.prompt )
+ main.ONOSbench.handle.sendline( "sed -i 's/-Dkaraf.log.console=INFO //g' tools/package/bin/onos-service" )
+ main.ONOSbench.handle.expect( main.ONOSbench.prompt )
+
def customizeOnosGenPartitions( self ):
# copy gen-partions file to ONOS
# NOTE: this assumes TestON and ONOS are on the same machine