2012-06-26 16:26:03 +00:00
|
|
|
#!/bin/sh -e
|
2012-04-04 20:54:43 +00:00
|
|
|
|
|
|
|
suite=$1
|
|
|
|
ceph=$2
|
|
|
|
kernel=$3
|
|
|
|
email=$4
|
2012-06-14 20:23:24 +00:00
|
|
|
flavor=$5
|
2013-02-13 05:15:52 +00:00
|
|
|
teuthology_branch=$6
|
2013-03-08 23:15:07 +00:00
|
|
|
mtype=$7
|
|
|
|
template=$8
|
2012-04-04 20:54:43 +00:00
|
|
|
|
|
|
|
if [ -z "$email" ]; then
|
2013-03-08 23:15:07 +00:00
|
|
|
echo "usage: $0 <suite> <ceph branch> <kernel branch> <email> [flavor] [teuthology-branch] [machinetype] [template]"
|
2012-06-14 20:23:24 +00:00
|
|
|
echo " flavor can be 'basic', 'gcov', 'notcmalloc'."
|
2012-04-04 20:54:43 +00:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2012-06-14 20:23:24 +00:00
|
|
|
[ -z "$flavor" ] && flavor='basic'
|
2012-04-04 20:54:43 +00:00
|
|
|
|
|
|
|
|
2012-06-14 20:23:24 +00:00
|
|
|
##
|
|
|
|
test ! -d ~/src/ceph-qa-suite && echo "error: expects to find ~/src/ceph-qa-suite" && exit 1
|
|
|
|
test ! -d ~/src/teuthology/virtualenv/bin && echo "error: expects to find ~/src/teuthology/virtualenv/bin" && exit 1
|
|
|
|
|
|
|
|
## get sha1
|
|
|
|
KERNEL_SHA1=`wget http://gitbuilder.ceph.com/kernel-deb-precise-x86_64-basic/ref/$kernel/sha1 -O- 2>/dev/null`
|
2013-05-22 16:25:40 +00:00
|
|
|
CEPH_SHA1=`wget http://gitbuilder.ceph.com/ceph-deb-precise-x86_64-$flavor/ref/$ceph/sha1 -O- 2>/dev/null`
|
2012-06-14 20:23:24 +00:00
|
|
|
|
2013-02-13 05:24:16 +00:00
|
|
|
[ -z "$KERNEL_SHA1" ] && echo "kernel branch $kernel dne" && exit 1
|
|
|
|
[ -z "$CEPH_SHA1" ] && echo "ceph branch $ceph dne" && exit 1
|
|
|
|
|
2013-02-13 16:50:46 +00:00
|
|
|
|
2013-02-15 17:33:27 +00:00
|
|
|
if [ -n "$teuthology_branch" ] && wget http://github.com/ceph/s3-tests/tree/$teuthology_branch -O- 2>/dev/null >/dev/null ; then
|
2013-02-13 16:50:46 +00:00
|
|
|
s3branch=$teuthology_branch
|
|
|
|
elif wget http://github.com/ceph/s3-tests/tree/$ceph -O- 2>/dev/null >/dev/null ; then
|
2012-09-10 18:09:25 +00:00
|
|
|
s3branch=$ceph
|
|
|
|
else
|
|
|
|
echo "branch $ceph not in s3-tests.git; will use master for s3tests"
|
|
|
|
s3branch='master'
|
|
|
|
fi
|
2013-02-13 16:50:46 +00:00
|
|
|
echo "s3branch $s3branch"
|
2012-07-03 19:49:39 +00:00
|
|
|
|
2013-02-13 16:50:46 +00:00
|
|
|
if [ -z "$teuthology_branch" ]; then
|
|
|
|
if wget http://github.com/ceph/teuthology/tree/$ceph -O- 2>/dev/null >/dev/null ; then
|
|
|
|
teuthology_branch=$ceph
|
|
|
|
else
|
|
|
|
echo "branch $ceph not in teuthology.git; will use master for teuthology"
|
|
|
|
teuthology_branch='master'
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
echo "teuthology branch $teuthology_branch"
|
2012-07-03 19:49:39 +00:00
|
|
|
|
2013-03-08 23:15:07 +00:00
|
|
|
[ -z "$mtype" ] && mtype="plana"
|
|
|
|
|
2012-06-14 20:23:24 +00:00
|
|
|
## always include this
|
|
|
|
fn="/tmp/schedule.suite.$$"
|
|
|
|
trap "rm $fn" EXIT
|
2012-04-04 20:54:43 +00:00
|
|
|
cat <<EOF > $fn
|
2013-07-18 19:04:08 +00:00
|
|
|
teuthology_branch: $teuthology_branch
|
2012-04-04 20:54:43 +00:00
|
|
|
kernel:
|
2012-06-20 00:29:32 +00:00
|
|
|
kdb: true
|
2012-07-03 19:49:39 +00:00
|
|
|
sha1: $KERNEL_SHA1
|
2012-04-04 20:54:43 +00:00
|
|
|
nuke-on-error: true
|
2013-03-08 23:15:07 +00:00
|
|
|
machine_type: $mtype
|
2012-06-14 20:23:24 +00:00
|
|
|
tasks:
|
|
|
|
- chef:
|
2013-04-03 21:00:25 +00:00
|
|
|
- clock.check:
|
2012-04-04 20:54:43 +00:00
|
|
|
overrides:
|
2012-07-23 05:03:04 +00:00
|
|
|
workunit:
|
|
|
|
sha1: $CEPH_SHA1
|
2012-09-10 18:09:25 +00:00
|
|
|
s3tests:
|
|
|
|
branch: $s3branch
|
2013-05-16 18:29:42 +00:00
|
|
|
install:
|
2013-05-18 01:53:02 +00:00
|
|
|
ceph:
|
|
|
|
sha1: $CEPH_SHA1
|
2012-04-04 20:54:43 +00:00
|
|
|
ceph:
|
2013-05-16 18:29:42 +00:00
|
|
|
sha1: $CEPH_SHA1
|
2013-03-13 15:23:59 +00:00
|
|
|
conf:
|
|
|
|
mon:
|
2013-07-25 16:10:47 +00:00
|
|
|
debug ms: 1
|
2013-03-13 15:23:59 +00:00
|
|
|
debug mon: 20
|
|
|
|
debug paxos: 20
|
2012-06-16 20:59:46 +00:00
|
|
|
log-whitelist:
|
|
|
|
- slow request
|
2013-07-17 00:41:32 +00:00
|
|
|
ceph-deploy:
|
2013-07-25 19:45:52 +00:00
|
|
|
branch:
|
|
|
|
dev: $ceph
|
2013-07-17 00:41:32 +00:00
|
|
|
conf:
|
|
|
|
mon:
|
2013-07-25 16:10:47 +00:00
|
|
|
debug mon: 1
|
2013-07-17 00:41:32 +00:00
|
|
|
debug paxos: 20
|
|
|
|
debug ms: 20
|
|
|
|
client:
|
2013-07-18 18:38:00 +00:00
|
|
|
log file: /var/log/ceph/ceph-\$name.\$pid.log
|
2013-07-17 00:41:32 +00:00
|
|
|
debug rados: 20
|
|
|
|
debug ms: 1
|
|
|
|
debug objecter: 20
|
|
|
|
debug monc: 20
|
2013-06-19 20:35:50 +00:00
|
|
|
admin_socket:
|
|
|
|
branch: $ceph
|
2012-04-04 20:54:43 +00:00
|
|
|
EOF
|
|
|
|
|
2012-06-14 20:23:24 +00:00
|
|
|
if [ "$flavor" = "gcov" ]; then
|
|
|
|
cat <<EOF >> $fn
|
|
|
|
coverage: yes
|
|
|
|
EOF
|
|
|
|
fi
|
|
|
|
|
|
|
|
## template, too?
|
|
|
|
if [ -n "$template" ]; then
|
|
|
|
sed s/CEPH_SHA1/$CEPH_SHA1/ $template | sed s/KERNEL_SHA1/$KERNEL_SHA1/ >> $fn
|
|
|
|
fi
|
|
|
|
|
|
|
|
##
|
|
|
|
stamp=`date +%Y-%m-%d_%H:%M:%S`
|
2012-06-16 22:05:46 +00:00
|
|
|
name=`whoami`"-$stamp-$suite-$ceph-$kernel-$flavor"
|
2012-06-14 20:23:24 +00:00
|
|
|
|
2013-02-13 16:50:46 +00:00
|
|
|
echo "name $name"
|
2012-09-21 21:54:19 +00:00
|
|
|
|
2012-06-14 20:23:24 +00:00
|
|
|
~/src/teuthology/virtualenv/bin/teuthology-suite -v $fn \
|
|
|
|
--collections ~/src/ceph-qa-suite/suites/$suite/* \
|
|
|
|
--email $email \
|
2013-05-20 18:23:50 +00:00
|
|
|
--timeout 36000 \
|
2012-09-21 21:54:19 +00:00
|
|
|
--name $name \
|
2013-07-18 19:04:08 +00:00
|
|
|
--worker $mtype
|