recoverd.c (6d40c4a708e0e996fd9c60d4093aebba5fe1f749) recoverd.c (4875647a08e35f77274838d97ca8fa44158d50e2)
1/******************************************************************************
2*******************************************************************************
3**
4** Copyright (C) Sistina Software, Inc. 1997-2003 All rights reserved.
5** Copyright (C) 2004-2011 Red Hat, Inc. All rights reserved.
6**
7** This copyrighted material is made available to anyone wishing to use,
8** modify, copy, or redistribute it subject to the terms and conditions

--- 70 unchanged lines hidden (view full) ---

79 */
80
81 error = dlm_recover_members(ls, rv, &neg);
82 if (error) {
83 log_debug(ls, "dlm_recover_members error %d", error);
84 goto fail;
85 }
86
1/******************************************************************************
2*******************************************************************************
3**
4** Copyright (C) Sistina Software, Inc. 1997-2003 All rights reserved.
5** Copyright (C) 2004-2011 Red Hat, Inc. All rights reserved.
6**
7** This copyrighted material is made available to anyone wishing to use,
8** modify, copy, or redistribute it subject to the terms and conditions

--- 70 unchanged lines hidden (view full) ---

79 */
80
81 error = dlm_recover_members(ls, rv, &neg);
82 if (error) {
83 log_debug(ls, "dlm_recover_members error %d", error);
84 goto fail;
85 }
86
87 ls->ls_recover_locks_in = 0;
88
87 dlm_set_recover_status(ls, DLM_RS_NODES);
88
89 error = dlm_recover_members_wait(ls);
90 if (error) {
91 log_debug(ls, "dlm_recover_members_wait error %d", error);
92 goto fail;
93 }
94

--- 30 unchanged lines hidden (view full) ---

125 if (error)
126 goto fail;
127
128 if (neg || dlm_no_directory(ls)) {
129 /*
130 * Clear lkb's for departed nodes.
131 */
132
89 dlm_set_recover_status(ls, DLM_RS_NODES);
90
91 error = dlm_recover_members_wait(ls);
92 if (error) {
93 log_debug(ls, "dlm_recover_members_wait error %d", error);
94 goto fail;
95 }
96

--- 30 unchanged lines hidden (view full) ---

127 if (error)
128 goto fail;
129
130 if (neg || dlm_no_directory(ls)) {
131 /*
132 * Clear lkb's for departed nodes.
133 */
134
133 dlm_purge_locks(ls);
135 dlm_recover_purge(ls);
134
135 /*
136 * Get new master nodeid's for rsb's that were mastered on
137 * departed nodes.
138 */
139
140 error = dlm_recover_masters(ls);
141 if (error) {

--- 14 unchanged lines hidden (view full) ---

156 dlm_set_recover_status(ls, DLM_RS_LOCKS);
157
158 error = dlm_recover_locks_wait(ls);
159 if (error) {
160 log_debug(ls, "dlm_recover_locks_wait error %d", error);
161 goto fail;
162 }
163
136
137 /*
138 * Get new master nodeid's for rsb's that were mastered on
139 * departed nodes.
140 */
141
142 error = dlm_recover_masters(ls);
143 if (error) {

--- 14 unchanged lines hidden (view full) ---

158 dlm_set_recover_status(ls, DLM_RS_LOCKS);
159
160 error = dlm_recover_locks_wait(ls);
161 if (error) {
162 log_debug(ls, "dlm_recover_locks_wait error %d", error);
163 goto fail;
164 }
165
166 log_debug(ls, "dlm_recover_locks %u in",
167 ls->ls_recover_locks_in);
168
164 /*
165 * Finalize state in master rsb's now that all locks can be
166 * checked. This includes conversion resolution and lvb
167 * settings.
168 */
169
170 dlm_recover_rsbs(ls);
171 } else {

--- 48 unchanged lines hidden (view full) ---

220 }
221
222 error = dlm_recover_waiters_post(ls);
223 if (error) {
224 log_debug(ls, "dlm_recover_waiters_post error %d", error);
225 goto fail;
226 }
227
169 /*
170 * Finalize state in master rsb's now that all locks can be
171 * checked. This includes conversion resolution and lvb
172 * settings.
173 */
174
175 dlm_recover_rsbs(ls);
176 } else {

--- 48 unchanged lines hidden (view full) ---

225 }
226
227 error = dlm_recover_waiters_post(ls);
228 if (error) {
229 log_debug(ls, "dlm_recover_waiters_post error %d", error);
230 goto fail;
231 }
232
228 dlm_grant_after_purge(ls);
233 dlm_recover_grant(ls);
229
230 log_debug(ls, "dlm_recover %llu generation %u done: %u ms",
231 (unsigned long long)rv->seq, ls->ls_generation,
232 jiffies_to_msecs(jiffies - start));
233 mutex_unlock(&ls->ls_recoverd_active);
234
235 dlm_lsop_recover_done(ls);
236 return 0;

--- 90 unchanged lines hidden ---
234
235 log_debug(ls, "dlm_recover %llu generation %u done: %u ms",
236 (unsigned long long)rv->seq, ls->ls_generation,
237 jiffies_to_msecs(jiffies - start));
238 mutex_unlock(&ls->ls_recoverd_active);
239
240 dlm_lsop_recover_done(ls);
241 return 0;

--- 90 unchanged lines hidden ---