openstack-helm/ceph/templates/bin/_ceph_rbd_pool.sh.tpl
Huamin Chen eed43b8524 Ceph: luminous fixes
init osd: Ceph luminous release init osd differently. This fix detects
ceph releases and use the right process to init osd directory
mgr: Set mgr daemonset that is in Luminous

Change-Id: I99a102f24c4a8ba18a0bba873e9f752368bea594
Signed-off-by: Huamin Chen <hchen@redhat.com>
Depends-On: I17359df62a720cbd0b3ff79b1d642f99b3e81b3f
2017-12-13 15:52:36 -05:00

26 lines
582 B
Smarty

#!/bin/bash
set -ex
export LC_ALL=C
source variables_entrypoint.sh
source common_functions.sh
if [[ ! -e /etc/ceph/${CLUSTER}.conf ]]; then
log "ERROR- /etc/ceph/${CLUSTER}.conf must exist; get it from your existing mon"
exit 1
fi
if [[ ! -e $ADMIN_KEYRING ]]; then
log "ERROR- $ADMIN_KEYRING must exist; get it from your existing mon"
exit 1
fi
# Make sure rbd pool exists
if ! ceph ${CLI_OPTS} osd pool stats rbd > /dev/null 2>&1; then
ceph ${CLI_OPTS} osd pool create rbd "${RBD_POOL_PG}"
rbd pool init rbd
ceph osd crush tunables hammer
fi
log "SUCCESS"