Added jstack thread trace to archives 28/43028/3
authorKumar Rishabh <shailrishabh@gmail.com>
Wed, 3 Aug 2016 10:03:36 +0000 (15:33 +0530)
committerKumar Rishabh <shailrishabh@gmail.com>
Wed, 3 Aug 2016 17:37:10 +0000 (23:07 +0530)
Change-Id: I0d9d1e079e6a3797f6cb55461d6797e8c0df21b5
Signed-off-by: Kumar Rishabh <shailrishabh@gmail.com>
jjb/integration/include-raw-integration-deploy-controller-run-test.sh
jjb/integration/include-raw-integration-start-cluster-run-test.sh

index d72e7d2fcf237c14f5b7c0ba9a04149139b34851..fecf5688b5c3e2cc8ae252e051f67a7af2712619 100644 (file)
@@ -138,6 +138,10 @@ if [ ${NUM_OPENSTACK_SYSTEM} -gt 0 ]; then
    exit
 fi
 
+echo "Lets's take the karaf thread dump"
+KARAF_PID=$(ssh ${ODL_SYSTEM_IP} "ps aux | grep 'distribution-karaf' | grep -v grep | tr -s ' ' | cut -f2 -d' '")
+ssh ${ODL_SYSTEM_IP} "jstack $KARAF_PID"> ${WORKSPACE}/karaf_threads_before.log
+
 echo "Locating test plan to use..."
 testplan_filepath="${WORKSPACE}/test/csit/testplans/${STREAMTESTPLAN}"
 if [ ! -f "${testplan_filepath}" ]; then
@@ -162,6 +166,10 @@ pybot -N ${TESTPLAN} -c critical -e exclude -v BUNDLEFOLDER:${BUNDLEFOLDER} -v W
 -v MININET_USER:${USER} -v USER_HOME:${HOME} ${TESTOPTIONS} ${SUITES} || true
 # FIXME: Sort (at least -v) options alphabetically.
 
+echo "Lets's take the karaf thread dump again"
+KARAF_PID=$(ssh ${ODL_SYSTEM_IP} "ps aux | grep 'distribution-karaf' | grep -v grep | tr -s ' ' | cut -f2 -d' '")
+ssh ${ODL_SYSTEM_IP} "jstack $KARAF_PID"> ${WORKSPACE}/karaf_threads_after.log
+
 echo "Killing ODL and fetching Karaf log..."
 set +e  # We do not want to create red dot just because something went wrong while fetching logs.
 ssh "${ODL_SYSTEM_IP}" bash -c 'ps axf | grep karaf | grep -v grep | awk '"'"'{print "kill -9 " $1}'"'"' | sh'
index 0debe1be4652b13c97be5daf9d16a9669538c536..2e39579ad916d6c1f9c034f9f1f1465ce9252ba4 100644 (file)
@@ -85,6 +85,9 @@ for i in `seq 1 ${NUM_ODL_SYSTEM}`
 do
     CONTROLLERIP=ODL_SYSTEM_${i}_IP
     odl_variables=${odl_variables}" -v ${CONTROLLERIP}:${!CONTROLLERIP}"
+    echo "Lets's take the karaf thread dump"
+    KARAF_PID=$(ssh ${!CONTROLLERIP} "ps aux | grep 'distribution-karaf' | grep -v grep | tr -s ' ' | cut -f2 -d' '")
+    ssh ${!CONTROLLERIP} "jstack $KARAF_PID"> ${WORKSPACE}/karaf_${i}_threads_before.log
 done
 
 echo "Generating mininet variables..."
@@ -121,6 +124,9 @@ set +e  # We do not want to create red dot just because something went wrong whi
 for i in `seq 1 ${NUM_ODL_SYSTEM}`
 do
     CONTROLLERIP=ODL_SYSTEM_${i}_IP
+    echo "Lets's take the karaf thread dump again"
+    KARAF_PID=$(ssh ${!CONTROLLERIP} "ps aux | grep 'distribution-karaf' | grep -v grep | tr -s ' ' | cut -f2 -d' '")
+    ssh ${!CONTROLLERIP} "jstack $KARAF_PID"> ${WORKSPACE}/karaf_${i}_threads_after.log
     echo "killing karaf process..."
     ssh "${!CONTROLLERIP}" bash -c 'ps axf | grep karaf | grep -v grep | awk '"'"'{print "kill -9 " $1}'"'"' | sh'
 done