diff options
author | kalyanreddy <reddyx.gundarapu@intel.com> | 2017-03-10 09:34:54 -0800 |
---|---|---|
committer | Kalyan reddy Gundarapu <reddyx.gundarapu@intel.com> | 2017-03-15 07:03:45 +0000 |
commit | a9df9f4fdafc08c33d1debd0e4999e58cdbf4b31 (patch) | |
tree | caf655e710a568fa905e77abee198ae0645e9882 /ci/cyclicTestTrigger.sh | |
parent | af712826966ee75ba5ac466a6c192580abdf0c29 (diff) |
This patch includes scripts and configuration files for
executing packet forwarding test cases as a part of
kvmfornfv daily job and printing the results.
Change-Id: I484ce89c4821d03cb997c774f014c59a10dc275e
Signed-off-by: Gundarapu Kalyan Reddy <reddyx.gundarapu@intel.com>
Diffstat (limited to 'ci/cyclicTestTrigger.sh')
-rwxr-xr-x | ci/cyclicTestTrigger.sh | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/ci/cyclicTestTrigger.sh b/ci/cyclicTestTrigger.sh index 741a865d0..12b2a66de 100755 --- a/ci/cyclicTestTrigger.sh +++ b/ci/cyclicTestTrigger.sh @@ -118,6 +118,7 @@ function env_clean { #Cleaning the latest kernel changes on host after executing the test. function host_clean { sudo ssh root@${HOST_IP} "rpm=\$(rpm -qa | grep 'kernel-${KERNELRPM_VERSION}' | awk '{print \$1}'); rpm -ev \$rpm" + sudo ssh root@${HOST_IP} "rpm=\$(rpm -qa | grep 'kernel-devel-${KERNELRPM_VERSION}' | awk '{print \$1}'); rpm -ev \$rpm" sudo ssh root@${HOST_IP} "rm -rf /boot/initramfs-${KERNELRPM_VERSION}*.img" sudo ssh root@${HOST_IP} "grub2-mkconfig -o /boot/grub2/grub.cfg" sudo ssh root@${HOST_IP} "rpm=\$(rpm -qa | grep 'qemu-${QEMURPM_VERSION}'| awk '{print \$1}'); rpm -ev \$rpm" @@ -136,6 +137,31 @@ function cleanup { fi } +#environment setup for executing packet forwarding test cases +function setUpPacketForwarding { + #copying required files to run packet forwarding test cases + ssh root@$HOST_IP "mkdir -p /root/workspace/image" + ssh root@$HOST_IP "mkdir -p /root/workspace/rpm" + ssh root@$HOST_IP "mkdir -p /root/workspace/scripts" + #Copying the host configuration scripts on to host + scp -r $WORKSPACE/ci/envs/* root@$HOST_IP:/root/workspace/scripts + scp -r $WORKSPACE/tests/vsperf.conf* root@$HOST_IP:/root/workspace/scripts + scp -r $WORKSPACE/build_output/kernel-${KERNELRPM_VERSION}*.rpm root@$HOST_IP:/root/workspace/rpm + scp -r $WORKSPACE/build_output/kernel-devel-${KERNELRPM_VERSION}*.rpm root@$HOST_IP:/root/workspace/rpm + scp -r $WORKSPACE/build_output/qemu-${QEMURPM_VERSION}*.rpm root@$HOST_IP:/root/workspace/rpm + #execute host configuration script for installing kvm built kernel. + ssh root@$HOST_IP "cd /root/workspace/scripts ; ./host-setup0.sh" + ssh root@$HOST_IP "cd /root/workspace/rpm ; rpm -ivh kernel-devel-${KERNELRPM_VERSION}*.rpm" + ssh root@$HOST_IP "reboot" + sleep 10 +} + +#executing packet forwarding test cases +function runPacketForwarding { + testType=$1 + ssh -t -t root@$HOST_IP "cd /root/workspace/scripts ; sudo scl enable python33 'sh packet_forwarding.sh $testType $QEMURPM_VERSION'" +} + #Creating a docker image with yardstick installed and Verify the results of cyclictest function runCyclicTest { container_id=`sudo docker ps -a | grep kvmfornfv_${testType} |awk '{print \$1}'|sed -e 's/\r//g'` @@ -189,4 +215,4 @@ function runCyclicTest { return 1 fi fi -}
\ No newline at end of file +} |