Skip to content

Commit

Permalink
Enable stress-ng for all configs
Browse files Browse the repository at this point in the history
  • Loading branch information
jinengandhi-intel committed Aug 10, 2021
1 parent a0ad418 commit 098fb42
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 29 deletions.
1 change: 1 addition & 0 deletions ci/config-docker.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ env.PREFIX = '/home/intel/graphene_install/usr'
env.DOCKER_ARGS_COMMON = """
--device=/dev/kmsg:/dev/kmsg
--env=PATH=${env.PREFIX}/bin:${env.PATH}
--volume=/usr/bin/stress-ng:/usr/bin/stress-ng
"""
env.DOCKER_ARGS_SGX = '''
--volume=/lib/modules:/lib/modules:ro
Expand Down
2 changes: 2 additions & 0 deletions ci/linux-direct-centos8.2-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ node(node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"

sh 'sed -i -e \'s/dent != g_dentry_root && dent->state & DENTRY_VALID/0/\' \
Expand All @@ -32,6 +33,7 @@ node(node_label) {
load '../ci/stage-build-nosgx.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-direct.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
} finally {
stage('cleanup'){
Expand Down
5 changes: 4 additions & 1 deletion ci/linux-direct-ubuntu18.04-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ node(node_label) {
try {
stage('checkout'){
dir ('./') {
git url: 'https://github.com/jinengandhi-intel/graphene_local_ci.git'
git url: 'https://github.com/jinengandhi-intel/graphene_local_ci.git',
branch: 'stress_ng_ci'
}

dir('graphene') {
Expand All @@ -15,6 +16,7 @@ node(node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"

sh 'sed -i -e \'s/dent != g_dentry_root && dent->state & DENTRY_VALID/0/\' \
Expand All @@ -35,6 +37,7 @@ node(node_label) {
load '../ci/stage-build-nosgx.jenkinsfile'
load '../ci/stage-test-direct.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
2 changes: 2 additions & 0 deletions ci/linux-direct-ubuntu20.04-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ node(node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"

sh 'sed -i -e \'s/dent != g_dentry_root && dent->state & DENTRY_VALID/0/\' \
Expand All @@ -34,6 +35,7 @@ node(node_label) {
load '../ci/stage-build-nosgx.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-direct.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
2 changes: 2 additions & 0 deletions ci/linux-sgx-centos8.2-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ node (node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"
env.SGX = '1'

Expand All @@ -33,6 +34,7 @@ node (node_label) {
load '../ci/stage-build-sgx-centos.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-sgx.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
} finally {
stage('cleanup'){
Expand Down
1 change: 0 additions & 1 deletion ci/linux-sgx-ubuntu18.04-gcc-release-apps.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ node (node_label) {

load '../ci/stage-build-sgx.jenkinsfile'
load '../ci/stage-test-sandstone.jenkinsfile'
// load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
2 changes: 2 additions & 0 deletions ci/linux-sgx-ubuntu18.04-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ node (node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"
env.SGX = '1'

Expand All @@ -36,6 +37,7 @@ node (node_label) {
load '../ci/stage-build-sgx.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-sgx.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
1 change: 0 additions & 1 deletion ci/linux-sgx-ubuntu20.04-gcc-release-apps.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ node (node_label) {

load '../ci/stage-build-sgx.jenkinsfile'
load '../ci/stage-test-sandstone.jenkinsfile'
// load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
2 changes: 2 additions & 0 deletions ci/linux-sgx-ubuntu20.04-gcc-release.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ node(node_label) {
dir ("graphene") {
sh 'cp -rf $WORKSPACE/ltp_src LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/ltp_config/* LibOS/shim/test/ltp/'
sh 'cp -rf $WORKSPACE/stress-ng Examples/'
env.WORKSPACE = env.WORKSPACE + "/graphene"
env.SGX = '1'

Expand All @@ -35,6 +36,7 @@ node(node_label) {
load '../ci/stage-build-sgx.jenkinsfile'
load '../ci/stage-test.jenkinsfile'
load '../ci/stage-test-sgx.jenkinsfile'
load '../ci/stage-test-stress-ng.jenkinsfile'
}
}
} finally {
Expand Down
61 changes: 35 additions & 26 deletions ci/stage-test-stress-ng.jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,33 +1,42 @@
stage('stress-ng') {
try {
timeout(time: 180, unit: 'MINUTES') {
sh '''
export cmd=graphene-direct
cd Examples/stress-ng
if test -n "$SGX"
then
make SGX=1
export cmd=graphene-sgx
else
make
fi
script {
if (env.stress_ng_run == "True") {

$cmd stress-ng --job hdd.job 2>&1 | tee hdd.log
$cmd stress-ng --job seek.job 2>&1 | tee seek.log
$cmd stress-ng --job seek-hdd.job 2>&1 | tee seek-hdd.log
$cmd stress-ng --job interrupt.job 2>&1 | tee interrupt.log
$cmd stress-ng --job filesystem.job 2>&1 | tee filesystem.log
$cmd stress-ng --job filesystem_all.job 2>&1 | tee filesystem_all.log
$cmd stress-ng --job scheduler.job 2>&1 | tee scheduler.log
$cmd stress-ng --job scheduler_all.job 2>&1 | tee scheduler_all.log
try {
timeout(time: 180, unit: 'MINUTES') {
sh '''
export cmd=graphene-direct
cd Examples/stress-ng
if test -n "$SGX"
then
make SGX=1
export cmd=graphene-sgx
else
make
fi

'''
$cmd stress-ng --job hdd.job 2>&1 | tee hdd.log
$cmd stress-ng --job seek.job 2>&1 | tee seek.log
$cmd stress-ng --job seek-hdd.job 2>&1 | tee seek-hdd.log
$cmd stress-ng --job interrupt.job 2>&1 | tee interrupt.log
$cmd stress-ng --job filesystem.job 2>&1 | tee filesystem.log
$cmd stress-ng --job filesystem_all.job 2>&1 | tee filesystem_all.log
$cmd stress-ng --job scheduler.job 2>&1 | tee scheduler.log
$cmd stress-ng --job scheduler_all.job 2>&1 | tee scheduler_all.log

python3 parser_stressng.py --path=.

'''
}
} catch (Exception e){
build_ok = false
sh 'echo "Stress-ng Failed"'
} finally {
archiveArtifacts 'Examples/stress-ng/*.log'
}
} else {
sh "Ignoring stress-ng run. For enabling pass True from Jenkins build parameters"
}
} catch (Exception e){
build_ok = false
sh 'echo "Stress-ng Failed"'
} finally {
archiveArtifacts 'Examples/stress-ng/*.log'
}
}

0 comments on commit 098fb42

Please sign in to comment.