[NEWTON-ONLY] Fix Ceph upgrade from Hammer to Jewel >= 10.2.4

Newer versions of Ceph Jewel (>= 10.2.4) require setting a flag
after the last OSD has been upgraded from Hammer.

This change adds a conditional in the upgrade scripts to set the
needed flag when the warning message appears in ceph health output.

Change-Id: I449588609b2b6d7252401499b229cf6490ce90bf
Closes-Bug: #1685777
This commit is contained in:
Giulio Fidente 2017-04-24 13:44:42 +02:00
parent b0e4970a7c
commit 3890eb169a
1 changed files with 6 additions and 0 deletions

View File

@ -100,6 +100,12 @@ ceph osd unset noout
ceph osd unset norebalance
ceph osd unset nodeep-scrub
ceph osd unset noscrub
# From Ceph 10.2.4 we need to set the require_jewel_osds flag when the last OSD
# has been upgraded, see http://ceph.com/geen-categorie/v10-2-4-jewel-released/
if ceph health | grep "all OSDs are running jewel or later"; then
ceph osd set require_jewel_osds
fi
ENDOFCAT
# ensure the permissions are OK