From b32d6f9cb254bad3cccb71cac36fc0b43498b771 Mon Sep 17 00:00:00 2001 From: Francis Deslauriers Date: Thu, 26 Jan 2017 10:43:55 -0500 Subject: [PATCH] jjb: Fix missing script to save the benchmark data Signed-off-by: Francis Deslauriers --- .../generate-properties-master.sh | 7 +++++++ .../run-baremetal-benchmarks.sh | 14 ++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/scripts/lttng-baremetal-tests/generate-properties-master.sh b/scripts/lttng-baremetal-tests/generate-properties-master.sh index ae1901a..39ba391 100644 --- a/scripts/lttng-baremetal-tests/generate-properties-master.sh +++ b/scripts/lttng-baremetal-tests/generate-properties-master.sh @@ -50,9 +50,16 @@ echo "LTTNG_TOOLS_COMMIT_ID=$LTTNG_TOOLS_COMMIT_ID" >> properties.txt BASE_STORAGE_FOLDER="/storage/jenkins-lava/baremetal-tests" +echo "BASE_STORAGE_FOLDER=$BASE_STORAGE_FOLDER" >> properties.txt +echo "STORAGE_HOST=storage01.internal.efficios.com" >> properties.txt +echo "STORAGE_USER=jenkins-lava" >> properties.txt + echo "BUILD_DEVICE=$BUILD_DEVICE" >> properties.txt echo "KGITREPO=git://git-mirror.internal.efficios.com/git/linux-stable.git" >> properties.txt echo "STORAGE_KERNEL_FOLDER=$BASE_STORAGE_FOLDER/kernel" >> properties.txt echo "STORAGE_KERNEL_IMAGE=$BASE_STORAGE_FOLDER/kernel/$KERNEL_VERSION-$KERNEL_COMMIT_ID.$BUILD_DEVICE.bzImage" >> properties.txt echo "STORAGE_LINUX_MODULES=$BASE_STORAGE_FOLDER/modules/linux/$KERNEL_VERSION-$KERNEL_COMMIT_ID.$BUILD_DEVICE.linux.modules.tar.gz" >> properties.txt echo "STORAGE_LTTNG_MODULES=$BASE_STORAGE_FOLDER/modules/lttng/$KERNEL_VERSION-$KERNEL_COMMIT_ID-$LTTNG_MODULES_COMMIT_ID.$BUILD_DEVICE.lttng.modules.tar.gz" >> properties.txt + +echo SSH_COMMAND="ssh -oStrictHostKeyChecking=no -i $identity_file" >> properties.txt +echo SCP_COMMAND="scp -oStrictHostKeyChecking=no -i $identity_file" >> properties.txt diff --git a/scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh b/scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh index 187205a..0c722ae 100644 --- a/scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh +++ b/scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh @@ -25,3 +25,17 @@ python3 -u lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \ -km "$STORAGE_LINUX_MODULES" \ -lm "$STORAGE_LTTNG_MODULES" \ -tc "$LTTNG_TOOLS_COMMIT_ID" + +# Create a results folder for this job +RESULT_STORAGE_FOLDER="$BASE_STORAGE_FOLDER/benchmark-results/$JOB_NAME/$BUILD_NUMBER" +$SSH_COMMAND "$STORAGE_USER@$STORAGE_HOST" mkdir -p "$RESULT_STORAGE_FOLDER" + +# Create a metadata file for this job containing the build_id and the commit ids +echo "build_id,kernel_commit,modules_commit,tools_commit" > metadata.csv +echo "$BUILD_NUMBER,$KERNEL_COMMIT_ID,$LTTNG_MODULES_COMMIT_ID,$LTTNG_TOOLS_COMMIT_ID" >> metadata.csv + +# Copy the result files for each benchmark and metadata on storage server +$SCP_COMMAND ./processed_results_close.csv "$STORAGE_USER@$STORAGE_HOST:$RESULT_STORAGE_FOLDER/close.csv" +$SCP_COMMAND ./processed_results_open_efault.csv "$STORAGE_USER@$STORAGE_HOST:$RESULT_STORAGE_FOLDER/open-efault.csv" +$SCP_COMMAND ./processed_results_open_enoent.csv "$STORAGE_USER@$STORAGE_HOST:$RESULT_STORAGE_FOLDER/open-enoent.csv" +$SCP_COMMAND ./metadata.csv "$STORAGE_USER@$STORAGE_HOST:$RESULT_STORAGE_FOLDER/metadata.csv" -- 2.34.1