autotest_common.sh: handle ceph luminous in rbd_setup

unlike previous implementations of ceph, luminous (which ships with
fedora 27) does not create a default pool for us. In case we are on a
system using luminous, we need to create that pool ourselves.

Change-Id: I183dc4fff6b92f7b270bd5a5d05947f0d99e9d04
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/405703
Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
This commit is contained in:
Seth Howell 2018-03-28 14:47:11 -07:00 committed by Daniel Verkamp
parent 7b4bc2a243
commit 397521bdb9

View File

@ -329,9 +329,13 @@ function start_iscsi_service() {
function rbd_setup() {
if hash ceph; then
export PG_NUM=128
export RBD_POOL=rbd
export RBD_NAME=foo
$rootdir/scripts/ceph/start.sh
ceph osd pool create $RBD_POOL $PG_NUM || true
rbd pool init $RBD_POOL || true
rbd create $RBD_NAME --size 1000
fi
}