diff --git a/scripts/autotest_common.sh b/scripts/autotest_common.sh index 4fb61707e..051542d6b 100755 --- a/scripts/autotest_common.sh +++ b/scripts/autotest_common.sh @@ -245,14 +245,7 @@ function start_iscsi_service() { } function rbd_setup() { - export CEPH_DIR=/home/sys_sgsw/ceph/build - - if [ -d $CEPH_DIR ]; then - export RBD_POOL=rbd - export RBD_NAME=foo - (cd $CEPH_DIR && ../src/vstart.sh -d -n -x -l) - /usr/local/bin/rbd create $RBD_NAME --size 1000 - elif hash ceph; then + if hash ceph; then export RBD_POOL=rbd export RBD_NAME=foo (cd $rootdir/scripts/ceph && ./start.sh) @@ -261,9 +254,7 @@ function rbd_setup() { } function rbd_cleanup() { - if [ -d $CEPH_DIR ]; then - (cd $CEPH_DIR && ../src/stop.sh || true) - elif hash ceph; then + if hash ceph; then (cd $rootdir/scripts/ceph && ./stop.sh || true) fi } diff --git a/test/iscsi_tgt/rbd/rbd.sh b/test/iscsi_tgt/rbd/rbd.sh index d9823470c..bcf81d744 100755 --- a/test/iscsi_tgt/rbd/rbd.sh +++ b/test/iscsi_tgt/rbd/rbd.sh @@ -5,13 +5,8 @@ rootdir=$(readlink -f $testdir/../../..) source $rootdir/scripts/autotest_common.sh source $rootdir/test/iscsi_tgt/common.sh -if [ -z $CEPH_DIR ] && ! hash ceph; then - echo "Ceph directory not defined; skipping RBD tests" - exit 0 -fi - -if [ ! -d $CEPH_DIR ] && ! hash ceph; then - echo "Ceph directory not detected on this system; skipping RBD tests" +if ! hash ceph; then + echo "Ceph not detected on this system; skipping RBD tests" exit 0 fi