2 ##############################################################################
3 # Copyright (c) 2018 The Linux Foundation and others.
5 # All rights reserved. This program and the accompanying materials
6 # are made available under the terms of the Eclipse Public License v1.0
7 # which accompanies this distribution, and is available at
8 # http://www.eclipse.org/legal/epl-v10.html
9 ##############################################################################
12 OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g')
14 if ! [ -z ${DOCKER_TEST} ] ; then
16 # framework.VppTestCase.MIN_REQ_SHM + (num_cores * framework.VppTestCase.SHM_PER_PROCESS)
17 # 1073741824 == 1024M (1073741824 >> 20)
18 sudo mount -o remount /dev/shm -o size=1024M || true
19 echo "/dev/shm remounted"
22 ##container server node detection
23 grep search /etc/resolv.conf || true
25 if [ "${OS_ID}" == "ubuntu" ]; then
26 dpkg-query -W -f='${binary:Package}\t${Version}\n' || true
27 echo "************************************************************************"
30 echo "************************************************************************"
31 echo "Contents of /var/cache/vpp/python/virtualenv/lib/python2.7/site-packages:"
32 ls -lth /var/cache/vpp/python/virtualenv/lib/python2.7/site-packages || true
33 echo "************************************************************************"
34 echo "Contents of br Downloads:"
35 ls -lth /w/Downloads || true
36 echo "************************************************************************"
37 echo "Contents of /w/dpdk for test folks:"
38 echo "************************************************************************"
39 ls -lth /w/dpdk || true
40 elif [ "${OS_ID}" == "centos" ]; then
41 yum list installed || true
43 elif [ "${OS_ID}" == "opensuse" ]; then
44 yum list installed || true
46 elif [ "${OS_ID}" == "opensuse-leap" ]; then
47 yum list installed || true
51 ##This will remove any previously installed dpdk for old branch builds
53 if [ "${GERRIT_BRANCH}" != "master" ]; then
54 if [ "${OS_ID}" == "ubuntu" ]; then
55 sudo apt-get -y remove vpp-dpdk-dev || true
56 sudo apt-get -y remove vpp-dpdk-dkms || true
57 sudo apt-get -y remove vpp-ext-deps || true
58 elif [ "${OS_ID}" == "centos" ]; then
59 sudo yum -y erase vpp-dpdk-devel || true
60 sudo yum -y erase vpp-ext-deps || true
61 sudo yum clean all || true
62 elif [ "${OS_ID}" == "opensuse" ]; then
63 sudo yum -y erase vpp-dpdk-devel || true
64 sudo yum -y erase vpp-ext-deps || true
65 elif [ "${OS_ID}" == "opensuse-leap" ]; then
66 sudo yum -y erase vpp-dpdk-devel || true
67 sudo yum -y erase vpp-ext-deps || true