From: Xiubo Li Date: Tue, 12 Jul 2022 14:33:45 +0000 (+0800) Subject: mds: add CEPHFS_FEATURE_OP_GETVXATTR feature bit support X-Git-Tag: v17.2.6~465^2~6 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=10ed79dcd2b350746983a42809aa726bfbc8d27e;p=ceph.git mds: add CEPHFS_FEATURE_OP_GETVXATTR feature bit support For old ceph if they receive unknown OPs, they will crash the MDS daemons directly. So we need to distiguish whether the new OPs is supported by the peer MDSs or not. Fixes: https://tracker.ceph.com/issues/56529 Signed-off-by: Xiubo Li (cherry picked from commit c7a0e71040e2a008497d4d7e2249f514bf082c92) --- diff --git a/src/mds/cephfs_features.cc b/src/mds/cephfs_features.cc index 419cf8d54977..dda64edfcd2a 100644 --- a/src/mds/cephfs_features.cc +++ b/src/mds/cephfs_features.cc @@ -24,6 +24,7 @@ static const std::array feature_names "metric_collect", "alternate_name", "notify_session_state", + "op_getvxattr", }; static_assert(feature_names.size() == CEPHFS_FEATURE_MAX + 1); diff --git a/src/mds/cephfs_features.h b/src/mds/cephfs_features.h index 7cf130ae6b22..811afa4d766a 100644 --- a/src/mds/cephfs_features.h +++ b/src/mds/cephfs_features.h @@ -44,7 +44,8 @@ namespace ceph { #define CEPHFS_FEATURE_METRIC_COLLECT 14 #define CEPHFS_FEATURE_ALTERNATE_NAME 15 #define CEPHFS_FEATURE_NOTIFY_SESSION_STATE 16 -#define CEPHFS_FEATURE_MAX 16 +#define CEPHFS_FEATURE_OP_GETVXATTR 17 +#define CEPHFS_FEATURE_MAX 17 #define CEPHFS_FEATURES_ALL { \ 0, 1, 2, 3, 4, \ @@ -62,6 +63,7 @@ namespace ceph { CEPHFS_FEATURE_METRIC_COLLECT, \ CEPHFS_FEATURE_ALTERNATE_NAME, \ CEPHFS_FEATURE_NOTIFY_SESSION_STATE, \ + CEPHFS_FEATURE_OP_GETVXATTR, \ } #define CEPHFS_METRIC_FEATURES_ALL { \