- mds
fmt_desc: Ceph will randomly fragment or merge directories.
with_legacy: true
+- name: mds_allow_async_dirops
+ type: bool
+ level: advanced
+ default: true
+ services:
+ - mds
+ fmt_desc: MDS will enable/disable the async dirop feature.
+ with_legacy: true
- name: mds_dump_cache_on_map
type: bool
level: dev
"mds_session_metadata_threshold",
"mds_log_trim_threshold",
"mds_log_trim_decay_rate",
+ "mds_allow_async_dirops",
NULL
};
return KEYS;
}
void Server::handle_conf_change(const std::set<std::string>& changed) {
+ if (changed.count("mds_allow_async_dirops")){
+ mds_allow_async_dirops = g_conf().get_val<bool>("mds_allow_async_dirops");
+ }
if (changed.count("mds_forward_all_requests_to_auth")){
forward_all_requests_to_auth = g_conf().get_val<bool>("mds_forward_all_requests_to_auth");
}
{
Session *session = mds->get_session(req);
- if (session->info.has_feature(CEPHFS_FEATURE_DELEG_INO)) {
+ if (mds_allow_async_dirops && session->info.has_feature(CEPHFS_FEATURE_DELEG_INO)) {
openc_response_t ocresp;
dout(10) << "adding created_ino and delegated_inos" << dendl;
if (!check_dir_max_entries(mdr, dir))
return;
- if (mdr->dn[0].size() == 1)
+ if (mds_allow_async_dirops && mdr->dn[0].size() == 1)
mds->locker->create_lock_cache(mdr, diri, &mdr->dir_layout);
// create inode.
return; // we're waiting for a witness.
}
- if (!rmdir && dnl->is_primary() && mdr->dn[0].size() == 1)
+ if (mds_allow_async_dirops && !rmdir && dnl->is_primary() && mdr->dn[0].size() == 1)
mds->locker->create_lock_cache(mdr, diri);
// ok!
feature_bitset_t supported_metric_spec;
feature_bitset_t required_client_features;
+ bool mds_allow_async_dirops = true;
bool forward_all_requests_to_auth = false;
bool replay_unsafe_with_closed_session = false;
double cap_revoke_eviction_timeout = 0;