Allow Atomix logging configuration to be overridden in stc tests
Change-Id: I67c4365859f380dd8c89c645b1a52f382c2595a4
diff --git a/tools/test/bin/atomix-config b/tools/test/bin/atomix-config
index f7decba..84b69fe 100755
--- a/tools/test/bin/atomix-config
+++ b/tools/test/bin/atomix-config
@@ -36,6 +36,5 @@
atomix-gen-config $node $CDEF_FILE
scp -q $CDEF_FILE $remote:$ATOMIX_INSTALL_DIR/atomix.json
-ssh -tt $ONOS_USER@$node "
- sed -i -e $'s/<logger name=\"io.atomix\" level=\"INFO\" \/>/<logger name=\"io.atomix\" level=\"INFO\" \/>\\\n <logger name=\"io.atomix.protocols.raft\" level=\"DEBUG\" \/>/g' /opt/atomix/conf/logback.xml
-"
+LOGBACK_FILE="$ONOS_ROOT"/tools/test/configs/atomix/logback.xml
+scp -q $LOGBACK_FILE $remote:/opt/atomix/conf/logback.xml
diff --git a/tools/test/bin/onos-config b/tools/test/bin/onos-config
index 65df721..6c9ad04 100755
--- a/tools/test/bin/onos-config
+++ b/tools/test/bin/onos-config
@@ -43,10 +43,8 @@
>> $ONOS_INSTALL_DIR/$KARAF_DIST/etc/system.properties
# Drop copycat related log level for the console
- echo "log4j.logger.io.atomix=INFO" \
- >> $ONOS_INSTALL_DIR/$KARAF_DIST/etc/org.ops4j.pax.logging.cfg
- echo "log4j.logger.io.atomix.cluster.messaging=ERROR" \
- >> $ONOS_INSTALL_DIR/$KARAF_DIST/etc/org.ops4j.pax.logging.cfg
+ echo "log4j2.logger.atomix.name = io.atomix.protocols.raft" >> $ONOS_INSTALL_DIR/$KARAF_DIST/etc/org.ops4j.pax.logging.cfg
+ echo "log4j2.logger.atomix.level = INFO" >> $ONOS_INSTALL_DIR/$KARAF_DIST/etc/org.ops4j.pax.logging.cfg
# Patch the Apache Karaf distribution file to load ONOS boot features
perl -pi.old -e \"s|^(featuresBoot=.*,management)(,webconsole,.*)|\1,$ONOS_BOOT_FEATURES|\" \