mds: don't manully create snaprealm during rename

project_past_snaprealm_parent() will do the same job. Besides
MDCache::_snaprealm_create_finish() is buggy, it updates snaprealm's
current_parent_since incorrectly

Signed-off-by: Yan, Zheng <zyan@redhat.com>
This commit is contained in:
Yan, Zheng 2014-12-29 16:16:23 +08:00
parent f3b61e6892
commit 966e108055
2 changed files with 3 additions and 1 deletions

View File

@ -8862,7 +8862,6 @@ void MDCache::_snaprealm_create_finish(MDRequestRef& mdr, MutationRef& mut, CIno
in->snaprealm->open = true;
in->snaprealm->srnode.seq = seq;
in->snaprealm->srnode.created = seq;
in->snaprealm->srnode.current_parent_since = seq;
do_realm_invalidate_and_update_notify(in, CEPH_SNAP_OP_SPLIT);

View File

@ -5962,6 +5962,8 @@ void Server::handle_client_rename(MDRequestRef& mdr)
return;
}
/* project_past_snaprealm_parent() will do this job
*
// moving between snaprealms?
if (srcdnl->is_primary() && srci->is_multiversion() && !srci->snaprealm) {
SnapRealm *srcrealm = srci->find_snaprealm();
@ -5974,6 +5976,7 @@ void Server::handle_client_rename(MDRequestRef& mdr)
return;
}
}
*/
assert(g_conf->mds_kill_rename_at != 1);