Merge "Ceph: fix ensure pool function for older than luminous"
This commit is contained in:
commit
8a02f63c3a
@ -312,7 +312,10 @@ bootstrap:
|
|||||||
ceph -s
|
ceph -s
|
||||||
function ensure_pool () {
|
function ensure_pool () {
|
||||||
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
||||||
|
local test_luminous=$(ceph -v | egrep -q "12.2|luminous"; echo $?)
|
||||||
|
if [[ ${test_luminous} -ne 0 ]]; then
|
||||||
ceph osd pool application enable $1 $3
|
ceph osd pool application enable $1 $3
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
#ensure_pool volumes 8 cinder
|
#ensure_pool volumes 8 cinder
|
||||||
|
|
||||||
|
@ -34,7 +34,10 @@ elif [ "x$STORAGE_BACKEND" == "xcinder.backup.drivers.ceph" ]; then
|
|||||||
ceph -s
|
ceph -s
|
||||||
function ensure_pool () {
|
function ensure_pool () {
|
||||||
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
||||||
|
local test_luminous=$(ceph -v | egrep -q "12.2|luminous"; echo $?)
|
||||||
|
if [[ ${test_luminous} -ne 0 ]]; then
|
||||||
ceph osd pool application enable $1 $3
|
ceph osd pool application enable $1 $3
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "cinder-backup"
|
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "cinder-backup"
|
||||||
|
|
||||||
|
@ -31,7 +31,10 @@ if [ "x$STORAGE_BACKEND" == "xcinder.volume.drivers.rbd.RBDDriver" ]; then
|
|||||||
ceph -s
|
ceph -s
|
||||||
function ensure_pool () {
|
function ensure_pool () {
|
||||||
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
||||||
|
local test_luminous=$(ceph -v | egrep -q "12.2|luminous"; echo $?)
|
||||||
|
if [[ ${test_luminous} -ne 0 ]]; then
|
||||||
ceph osd pool application enable $1 $3
|
ceph osd pool application enable $1 $3
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "cinder-volume"
|
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "cinder-volume"
|
||||||
|
|
||||||
|
@ -33,7 +33,10 @@ elif [ "x$STORAGE_BACKEND" == "xrbd" ]; then
|
|||||||
ceph -s
|
ceph -s
|
||||||
function ensure_pool () {
|
function ensure_pool () {
|
||||||
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
||||||
|
local test_luminous=$(ceph -v | egrep -q "12.2|luminous"; echo $?)
|
||||||
|
if [[ ${test_luminous} -ne 0 ]]; then
|
||||||
ceph osd pool application enable $1 $3
|
ceph osd pool application enable $1 $3
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "glance-image"
|
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "glance-image"
|
||||||
|
|
||||||
|
@ -28,7 +28,10 @@ set -ex
|
|||||||
ceph -s
|
ceph -s
|
||||||
function ensure_pool () {
|
function ensure_pool () {
|
||||||
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
ceph osd pool stats $1 || ceph osd pool create $1 $2
|
||||||
|
local test_luminous=$(ceph -v | egrep -q "12.2|luminous"; echo $?)
|
||||||
|
if [[ ${test_luminous} -ne 0 ]]; then
|
||||||
ceph osd pool application enable $1 $3
|
ceph osd pool application enable $1 $3
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "gnocchi-metrics"
|
ensure_pool ${RBD_POOL_NAME} ${RBD_POOL_CHUNK_SIZE} "gnocchi-metrics"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user