- defaults:
- name: baremetal_tests
+ name: baremetal_benchmarks
description: |
Runs baremetal kernel tests over different combination of kernel and lttng configurations.
- logrotate:
- numToKeep: 5
triggers:
- pollscm:
cron: "@hourly"
+ logrotate:
+ numToKeep: 10
- project-type: freestyle
- node: 'master'
properties:
- throttle:
max-total: 2
option: 'category'
categories:
- - 'kvm-tests'
+ - 'baremetal-tests'
project-type: freestyle
node: 'master'
wrappers:
properties-content: |
TOOLS_BRANCH={lttngversion}
UST_BRANCH={lttngversion}
- BUILD_DEVICE=kvm
+ BUILD_DEVICE=baremetal
publishers:
- email:
recipients: 'francis.deslauriers@efficios.com'
block: true
- inject:
properties-file: properties.txt
- - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-tests.sh
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh
+
- defaults:
- name: baremetal_benchmarks
- defaults: lttng-baremetal-tests
+ name: kvm_tests
description: |
- Runs baremetal kernel benchmarks over different combination of kernel and lttng configurations.
-
- logrotate:
- numToKeep: 5
-
+ Runs baremetal kernel tests over different combination of kernel and lttng configurations.
+ project-type: freestyle
+ node: 'master'
+ properties:
+ - throttle:
+ max-total: 2
+ option: 'category'
+ categories:
+ - 'kvm-tests'
triggers:
- pollscm:
cron: "@hourly"
+ logrotate:
+ numToKeep: 10
- project-type: freestyle
- node: 'master'
+ wrappers:
+ - workspace-cleanup
+ - timestamps
+ - ansicolor
+ - credentials-binding:
+ - text:
+ credential-id: jenkins_lava_key
+ variable: LAVA_FRDESO_TOKEN
+ - inject:
+ properties-content: |
+ BUILD_DEVICE=kvm
+ TOOLS_BRANCH={lttngversion}
+ UST_BRANCH={lttngversion}
+ scm:
+ - git:
+ url: git://git-mirror.internal.efficios.com/lttng/lttng-tools.git
+ branches:
+ - "{lttngversion}"
+ shallow-clone: true
+ skip-tag: true
+ fastpoll: true
+ basedir: src/lttng-tools
+ - git:
+ url: git://git-mirror.internal.efficios.com/lttng/lttng-modules.git
+ branches:
+ - "{lttngversion}"
+ shallow-clone: true
+ skip-tag: true
+ fastpoll: true
+ basedir: src/lttng-modules
+ - git:
+ url: git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git
+ branches:
+ - "{kversion}"
+ shallow-clone: true
+ skip-tag: true
+ fastpoll: true
+ basedir: src/linux
-## Templates
-- job-template:
- name: baremetal_tests_k{kversion}_l{lttngversion}
+ publishers:
+ - email:
+ recipients: 'francis.deslauriers@efficios.com'
+ builders:
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/generate-properties-master.sh
+ - trigger-builds:
+ - project: "build_kernel_PARAM"
+ property-file: 'properties.txt'
+ block: true
+ - inject:
+ properties-file: properties.txt
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-kvm-tests.sh
+
+- defaults:
+ name: baremetal_tests
description: |
Runs baremetal kernel tests over different combination of kernel and lttng configurations.
+ project-type: freestyle
+ node: 'master'
properties:
- throttle:
max-total: 2
option: 'category'
categories:
- 'baremetal-tests'
+ triggers:
+ - pollscm:
+ cron: "@hourly"
+ logrotate:
+ numToKeep: 10
+
wrappers:
- workspace-cleanup
- timestamps
variable: LAVA_FRDESO_TOKEN
- inject:
properties-content: |
+ UST_BRANCH={lttngversion}
BUILD_DEVICE=baremetal
scm:
- git:
block: true
- inject:
properties-file: properties.txt
- - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-benchmarks.sh
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-baremetal-tests.sh
- job-template:
name: baremetal_benchmarks_k{kversion}_l{lttngversion}
- description: |
- Runs baremetal kernel benchmarks over different combination of kernel and lttng configurations.
- defaults: lttng-baremetal-tests
- logrotate:
- numToKeep: 5
+ defaults: baremetal_benchmarks
+- job-template:
+ name: kvm_tests_k{kversion}_l{lttngversion}
+ defaults: kvm_tests
+- job-template:
+ name: baremetal_tests_k{kversion}_l{lttngversion}
+ defaults: baremetal_tests
- job-template:
name: baremetal_tests_k{kversion}_l{lttngversion}_canary
defaults: baremetal_tests
+- job-template:
+ name: kvm_tests_k{kversion}_l{lttngversion}_canary
+ defaults: kvm_tests
- job-template:
name: baremetal_benchmarks_k{kversion}_l{lttngversion}_canary
defaults: baremetal_benchmarks
+
- job-template:
- name: baremetal_tests_k{kversion}_l{lttngversion}
- defaults: baremetal_tests
-- job-template:
- name: baremetal_benchmarks_k{kversion}_l{lttngversion}
- defaults: baremetal_benchmarks
+ name: kvm_tests_kmainline_l{lttngversion}
+ defaults: kvm_tests
+ triggers:
+ - pollscm:
+ cron: "@daily"
+ scm:
+ - git:
+ url: git://git-mirror.internal.efficios.com/lttng/lttng-tools.git
+ branches:
+ - "{lttngversion}"
+ shallow-clone: true
+ skip-tag: true
+ fastpoll: true
+ basedir: src/lttng-tools
+ - git:
+ url: git://git-mirror.internal.efficios.com/lttng/lttng-modules.git
+ branches:
+ - "{lttngversion}"
+ shallow-clone: true
+ skip-tag: true
+ fastpoll: true
+ basedir: src/lttng-modules
+ - git:
+ url: git://git-mirror.internal.efficios.com/kernel/stable/linux-stable.git
+ refspec: "+refs/tags/*:refs/remotes/origin/tags/*"
+ branches:
+ - "master"
+ fastpoll: true
+ basedir: src/linux
+
- job-template:
name: baremetal_tests_kmainline_l{lttngversion}
defaults: baremetal_tests
- "master"
fastpoll: true
basedir: src/linux
-
+ wrappers:
+ - workspace-cleanup
+ - timestamps
+ - ansicolor
+ - credentials-binding:
+ - text:
+ credential-id: jenkins_lava_key
+ variable: LAVA_FRDESO_TOKEN
+ - inject:
+ properties-content: |
+ BUILD_DEVICE=baremetal
+ builders:
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/generate-properties-master.sh
+ - trigger-builds:
+ - project: "build_kernel_PARAM"
+ property-file: 'properties.txt'
+ block: true
+ - inject:
+ properties-file: properties.txt
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh
- job-template:
name: baremetal_benchmarks_kmainline_l{lttngversion}
defaults: baremetal_benchmarks
block: true
- inject:
properties-file: properties.txt
- - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-benchmarks.sh
+ - shell: !include-raw-escape: scripts/lttng-baremetal-tests/run-baremetal-benchmarks.sh
- job:
name: build_kernel_PARAM
concurrent: true
logrotate:
- numToKeep: 2
+ numToKeep: 20
node: 'x86-64'
wrappers:
- stable-2.8
- stable-2.9
jobs:
- - 'baremetal_tests_k{kversion}_l{lttngversion}'
+ - 'kvm_tests_k{kversion}_l{lttngversion}'
- 'baremetal_benchmarks_k{kversion}_l{lttngversion}'
+ - 'baremetal_tests_k{kversion}_l{lttngversion}'
- project:
name: lttng-kernel-tests-oldkernel
lttngversion:
- stable-2.7
jobs:
+ - 'kvm_tests_k{kversion}_l{lttngversion}':
- 'baremetal_tests_k{kversion}_l{lttngversion}':
- 'baremetal_benchmarks_k{kversion}_l{lttngversion}':
lttngversion:
- v2.8.1
jobs:
+ - 'kvm_tests_k{kversion}_l{lttngversion}_canary'
- 'baremetal_tests_k{kversion}_l{lttngversion}_canary'
- 'baremetal_benchmarks_k{kversion}_l{lttngversion}_canary'
lttngversion:
- v2.8.1
jobs:
+ - 'kvm_tests_kmainline_l{lttngversion}'
- 'baremetal_tests_kmainline_l{lttngversion}'
- 'baremetal_benchmarks_kmainline_l{lttngversion}'
SCP_PATH = 'scp://jenkins-lava@storage.internal.efficios.com'
class TestType(Enum):
- benchmarks=1
- tests=2
+ baremetal_benchmarks=1
+ baremetal_tests=2
+ kvm_tests=3
def get_job_bundle_content(server, job):
bundle_sha = server.scheduler.job_status(str(job))['bundle_sha1']
def get_config_cmd(build_device):
packages=['bsdtar', 'psmisc', 'wget', 'python3', 'python3-pip', \
'libglib2.0-dev', 'libffi-dev', 'elfutils', 'libdw-dev', \
- 'libelf-dev', 'libmount-dev', 'libxml2']
+ 'libelf-dev', 'libmount-dev', 'libxml2', 'libpfm4-dev']
command = OrderedDict({
'command': 'lava_command_run',
'parameters': {
])
return command
-def get_benchmarks_cmd():
+def get_baremetal_benchmarks_cmd():
command = OrderedDict({
'command': 'lava_test_shell',
'parameters': {
'git-repo': 'https://github.com/lttng/lttng-ci.git',
'revision': 'master',
'testdef': 'lava/baremetal-tests/failing-open-enoent.yml'
- },
+ }
+ ],
+ 'timeout': 18000
+ }
+ })
+ return command
+
+def get_baremetal_tests_cmd():
+ command = OrderedDict({
+ 'command': 'lava_test_shell',
+ 'parameters': {
+ 'testdef_repos': [
{
'git-repo': 'https://github.com/lttng/lttng-ci.git',
'revision': 'master',
})
return command
-def get_tests_cmd():
+def get_kvm_tests_cmd():
command = OrderedDict({
'command': 'lava_test_shell',
'parameters': {
parser.add_argument('-uc', '--ust-commit', required=False)
args = parser.parse_args()
- if args.type in 'benchmarks':
- test_type = TestType.benchmarks
- elif args.type in 'tests':
- test_type = TestType.tests
+ if args.type in 'baremetal-benchmarks':
+ test_type = TestType.baremetal_benchmarks
+ elif args.type in 'baremetal-tests':
+ test_type = TestType.baremetal_tests
+ elif args.type in 'kvm-tests':
+ test_type = TestType.kvm_tests
else:
print('argument -t/--type {} unrecognized. Exiting...'.format(args.type))
return -1
- if test_type is TestType.benchmarks:
+ if test_type is TestType.baremetal_benchmarks:
j = create_new_job(args.jobname, build_device='x86')
j['actions'].append(get_deploy_cmd_x86(args.jobname, args.kernel, args.kmodule, args.lmodule))
- elif test_type is TestType.tests:
+ elif test_type is TestType.baremetal_tests:
+ j = create_new_job(args.jobname, build_device='x86')
+ j['actions'].append(get_deploy_cmd_x86(args.jobname, args.kernel, args.kmodule, args.lmodule))
+ elif test_type is TestType.kvm_tests:
j = create_new_job(args.jobname, build_device='kvm')
j['actions'].append(get_deploy_cmd_kvm(args.jobname, args.kernel, args.kmodule, args.lmodule))
j['actions'].append(get_boot_cmd())
- if test_type is TestType.benchmarks:
+ if test_type is TestType.baremetal_benchmarks:
j['actions'].append(get_config_cmd('x86'))
j['actions'].append(get_env_setup_cmd('x86', args.tools_commit))
- j['actions'].append(get_benchmarks_cmd())
+ j['actions'].append(get_baremetal_benchmarks_cmd())
j['actions'].append(get_results_cmd(stream_name='benchmark-kernel'))
- elif test_type is TestType.tests:
+ elif test_type is TestType.baremetal_tests:
+ if args.ust_commit is None:
+ print('Tests runs need -uc/--ust-commit options. Exiting...')
+ return -1
+ j['actions'].append(get_config_cmd('x86'))
+ j['actions'].append(get_env_setup_cmd('x86', args.tools_commit, args.ust_commit))
+ j['actions'].append(get_baremetal_tests_cmd())
+ j['actions'].append(get_results_cmd(stream_name='tests-kernel'))
+ elif test_type is TestType.kvm_tests:
if args.ust_commit is None:
print('Tests runs need -uc/--ust-commit options. Exiting...')
return -1
j['actions'].append(get_config_cmd('kvm'))
j['actions'].append(get_env_setup_cmd('kvm', args.tools_commit, args.ust_commit))
- j['actions'].append(get_tests_cmd())
+ j['actions'].append(get_kvm_tests_cmd())
j['actions'].append(get_results_cmd(stream_name='tests-kernel'))
else:
assert False, 'Unknown test type'
passed, failed=check_job_all_test_cases_state_count(server, jobid)
- if test_type is TestType.tests:
+ if test_type is TestType.kvm_tests:
print_test_output(server, jobid)
print('Job ended with {} status.'.format(jobstatus))
--- /dev/null
+#!/bin/bash -xeu
+# Copyright (C) 2016 - Francis Deslauriers <francis.deslauriers@efficios.com>
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+echo 'At this point, we built the modules and kernel if we needed to.'
+echo 'We can now launch the lava job using those artefacts'
+git clone https://github.com/lttng/lttng-ci
+
+set +x
+python lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \
+ -t baremetal-benchmarks \
+ -j "$JOB_NAME" \
+ -l "$LAVA_FRDESO_TOKEN" \
+ -k "$STORAGE_KERNEL_IMAGE" \
+ -km "$STORAGE_LINUX_MODULES" \
+ -lm "$STORAGE_LTTNG_MODULES" \
+ -tc "$LTTNG_TOOLS_COMMIT_ID"
--- /dev/null
+#!/bin/bash -xeu
+# Copyright (C) 2016 - Francis Deslauriers <francis.deslauriers@efficios.com>
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+echo 'At this point, we built the modules and kernel if we needed to.'
+echo 'We can now launch the lava job using those artefacts'
+git clone https://github.com/lttng/lttng-ci
+
+set +x
+python lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \
+ -t baremetal-tests \
+ -j "$JOB_NAME" \
+ -l "$LAVA_FRDESO_TOKEN" \
+ -k "$STORAGE_KERNEL_IMAGE" \
+ -km "$STORAGE_LINUX_MODULES" \
+ -lm "$STORAGE_LTTNG_MODULES" \
+ -tc "$LTTNG_TOOLS_COMMIT_ID" \
+ -uc "$LTTNG_UST_COMMIT_ID"
+++ /dev/null
-#!/bin/bash -xeu
-# Copyright (C) 2016 - Francis Deslauriers <francis.deslauriers@efficios.com>
-#
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-echo 'At this point, we built the modules and kernel if we needed to.'
-echo 'We can now launch the lava job using those artefacts'
-git clone https://github.com/lttng/lttng-ci
-
-set +x
-python lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \
- -t benchmarks \
- -j "$JOB_NAME" \
- -l "$LAVA_FRDESO_TOKEN" \
- -k "$STORAGE_KERNEL_IMAGE" \
- -km "$STORAGE_LINUX_MODULES" \
- -lm "$STORAGE_LTTNG_MODULES" \
- -tc "$LTTNG_TOOLS_COMMIT_ID"
--- /dev/null
+#!/bin/bash -xeu
+# Copyright (C) 2016 - Francis Deslauriers <francis.deslauriers@efficios.com>
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+echo 'At this point, we built the modules and kernel if we needed to.'
+echo 'We can now launch the lava job using those artefacts'
+git clone https://github.com/lttng/lttng-ci
+
+set +x
+python lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \
+ -t kvm-tests \
+ -j "$JOB_NAME" \
+ -l "$LAVA_FRDESO_TOKEN" \
+ -k "$STORAGE_KERNEL_IMAGE" \
+ -km "$STORAGE_LINUX_MODULES" \
+ -lm "$STORAGE_LTTNG_MODULES" \
+ -tc "$LTTNG_TOOLS_COMMIT_ID" \
+ -uc "$LTTNG_UST_COMMIT_ID"
+++ /dev/null
-#!/bin/bash -xeu
-# Copyright (C) 2016 - Francis Deslauriers <francis.deslauriers@efficios.com>
-#
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-echo 'At this point, we built the modules and kernel if we needed to.'
-echo 'We can now launch the lava job using those artefacts'
-git clone https://github.com/lttng/lttng-ci
-
-set +x
-python lttng-ci/scripts/lttng-baremetal-tests/lava-submit.py \
- -t tests \
- -j "$JOB_NAME" \
- -l "$LAVA_FRDESO_TOKEN" \
- -k "$STORAGE_KERNEL_IMAGE" \
- -km "$STORAGE_LINUX_MODULES" \
- -lm "$STORAGE_LTTNG_MODULES" \
- -tc "$LTTNG_TOOLS_COMMIT_ID" \
- -uc "$LTTNG_UST_COMMIT_ID"