From: Sage Weil Date: Sun, 24 Feb 2013 00:36:36 +0000 (-0800) Subject: mds: reencode MDSMap in MMDSMap if MDSENC feature is not present X-Git-Tag: v0.58~14 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=0cd215ee5b4768012041006377e10eeff53de7b0;p=ceph.git mds: reencode MDSMap in MMDSMap if MDSENC feature is not present In some cases the MMDSMap message from mon -> client passes from leader -> peon -> client, and the leader doesn't encode with the correct feature bits. As with MMOSDMap, we reencode the nested MDSMap based on the features if relevant bits are not present. We forgot to include this with the mds encoding changes. Signed-off-by: Sage Weil --- diff --git a/src/messages/MMDSMap.h b/src/messages/MMDSMap.h index 42bb98f54e1c..66566d01d313 100644 --- a/src/messages/MMDSMap.h +++ b/src/messages/MMDSMap.h @@ -82,7 +82,8 @@ public: void encode_payload(uint64_t features) { ::encode(fsid, payload); ::encode(epoch, payload); - if ((features & CEPH_FEATURE_PGID64) == 0) { + if ((features & CEPH_FEATURE_PGID64) == 0 || + (features & CEPH_FEATURE_MDSENC) == 0) { // reencode for old clients. MDSMap m; m.decode(encoded);