2017-09-24 18:05:14 +00:00
|
|
|
#!/bin/sh -ex
|
|
|
|
|
2018-06-10 18:08:45 +00:00
|
|
|
ceph config set mgr mgr/localpool/subtree host
|
|
|
|
ceph config set mgr mgr/localpool/failure_domain osd
|
2017-09-24 18:05:14 +00:00
|
|
|
ceph mgr module enable localpool
|
|
|
|
|
|
|
|
while ! ceph osd pool ls | grep '^by-host-'
|
|
|
|
do
|
|
|
|
sleep 5
|
|
|
|
done
|
|
|
|
|
|
|
|
ceph mgr module disable localpool
|
|
|
|
for p in `ceph osd pool ls | grep '^by-host-'`
|
|
|
|
do
|
|
|
|
ceph osd pool rm $p $p --yes-i-really-really-mean-it
|
|
|
|
done
|
|
|
|
|
2018-06-10 18:08:45 +00:00
|
|
|
ceph config rm mgr mgr/localpool/subtree
|
|
|
|
ceph config rm mgr mgr/localpool/failure_domain
|
2017-09-24 18:05:14 +00:00
|
|
|
|
|
|
|
echo OK
|