ocfs2/dlm: clear DROPPING_REF flag when the master goes down
If the master goes down after return in-progress for deref message. The lock resource on non-master node can not be purged. Clear the DROPPING_REF flag and recovery it. Signed-off-by: xuejiufei <xuejiufei@huawei.com> Cc: Mark Fasheh <mfasheh@suse.de> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Reviewed-by: Joseph Qi <joseph.qi@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
842b90b624
commit
8c03439681
@ -2377,14 +2377,16 @@ static void dlm_do_local_recovery_cleanup(struct dlm_ctxt *dlm, u8 dead_node)
|
|||||||
dlm_revalidate_lvb(dlm, res, dead_node);
|
dlm_revalidate_lvb(dlm, res, dead_node);
|
||||||
if (res->owner == dead_node) {
|
if (res->owner == dead_node) {
|
||||||
if (res->state & DLM_LOCK_RES_DROPPING_REF) {
|
if (res->state & DLM_LOCK_RES_DROPPING_REF) {
|
||||||
mlog(ML_NOTICE, "%s: res %.*s, Skip "
|
mlog(0, "%s:%.*s: owned by "
|
||||||
"recovery as it is being freed\n",
|
"dead node %u, this node was "
|
||||||
dlm->name, res->lockname.len,
|
"dropping its ref when it died. "
|
||||||
res->lockname.name);
|
"continue, dropping the flag.\n",
|
||||||
} else
|
dlm->name, res->lockname.len,
|
||||||
dlm_move_lockres_to_recovery_list(dlm,
|
res->lockname.name, dead_node);
|
||||||
res);
|
}
|
||||||
|
res->state &= ~DLM_LOCK_RES_DROPPING_REF;
|
||||||
|
dlm_move_lockres_to_recovery_list(dlm,
|
||||||
|
res);
|
||||||
} else if (res->owner == dlm->node_num) {
|
} else if (res->owner == dlm->node_num) {
|
||||||
dlm_free_dead_locks(dlm, res, dead_node);
|
dlm_free_dead_locks(dlm, res, dead_node);
|
||||||
__dlm_lockres_calc_usage(dlm, res);
|
__dlm_lockres_calc_usage(dlm, res);
|
||||||
|
Loading…
Reference in New Issue
Block a user