]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
OSDMonitor: clear jewel+ feature bits when talking to Hammer OSD 13131/head
authorPiotr Dałek <piotr.dalek@corp.ovh.com>
Fri, 20 Jan 2017 15:07:10 +0000 (16:07 +0100)
committerPiotr Dałek <piotr.dalek@corp.ovh.com>
Thu, 2 Feb 2017 10:05:30 +0000 (11:05 +0100)
During upgrade from Hammer to Jewel, when upgrading MONs first and OSDs
last, Jewel MONs send OSDMaps with components in encoding version not
encodable by Hammer OSDs, generating extra load on MONs due to requests
for full OSDMap after failing the CRC check.
Fix this by not including CEPH_FEATURE_NEW_OSDOP_ENCODING (which
is responsible for encoding pg_pool_t in version 24 instead of 21) and
CEPH_FEATURE_CRUSH_TUNABLES5 (responsible for adding chooseleaf_stable
field into encoded CRUSH map) when CEPH_OSDMAP_REQUIRE_JEWEL flag
is not present.
Note that this issue applies only to upgrade from Hammer to Jewel,
because direct upgrade from Hammer to any other later release is not
supported. For that reason, there is no need to have this patch in any
release other than Jewel.

Fixes: http://tracker.ceph.com/issues/18582
Signed-off-by: Piotr Dałek <piotr.dalek@corp.ovh.com>
src/mon/OSDMonitor.cc

index b9cdc4d86023ceaed504f2a6d71f7654a483a962..658914eaeb4a0a06cf35978499941fb70b409563 100644 (file)
@@ -1215,7 +1215,9 @@ void OSDMonitor::encode_pending(MonitorDBStore::TransactionRef t)
     // determine appropriate features
     if (!tmp.test_flag(CEPH_OSDMAP_REQUIRE_JEWEL)) {
       dout(10) << __func__ << " encoding without feature SERVER_JEWEL" << dendl;
-      features &= ~CEPH_FEATURE_SERVER_JEWEL;
+      features &= ~(CEPH_FEATURE_SERVER_JEWEL |
+         CEPH_FEATURE_NEW_OSDOP_ENCODING |
+         CEPH_FEATURE_CRUSH_TUNABLES5);
     }
     dout(10) << __func__ << " encoding full map with " << features << dendl;