master - gfs_controld: fix fs_notify during recovery

David Teigland teigland@fedoraproject.org
Fri Aug 15 06:02:00 GMT 2008


Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=60132fc9c185be95a6cc480bd535412995a167a2
Commit:        60132fc9c185be95a6cc480bd535412995a167a2
Parent:        44861eae0e3530360c6e848aa5d86f482ede70e5
Author:        David Teigland <teigland@redhat.com>
AuthorDate:    Thu Aug 14 15:53:21 2008 -0500
Committer:     David Teigland <teigland@redhat.com>
CommitterDate: Thu Aug 14 15:53:21 2008 -0500

gfs_controld: fix fs_notify during recovery

Wasn't processing mountgroup again after an initial failed fs_notify,
so no retry was happening.  Also, the process_mountgroup check was
wrongly skipping the apply_changes phase sometimes at the very start
because there was no change struct yet, which would cause a segfault.

Signed-off-by: David Teigland <teigland@redhat.com>
---
 group/gfs_controld/cpg-new.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/group/gfs_controld/cpg-new.c b/group/gfs_controld/cpg-new.c
index d72d907..28445c1 100644
--- a/group/gfs_controld/cpg-new.c
+++ b/group/gfs_controld/cpg-new.c
@@ -622,6 +622,8 @@ void process_dlmcontrol(int ci)
 	}
 
 	poll_dlm = 0;
+
+	process_mountgroup(mg);
 }
 
 static int check_dlm_notify_done(struct mountgroup *mg)
@@ -657,8 +659,8 @@ static int check_dlm_notify_done(struct mountgroup *mg)
 		   dlmc_fs_notified() again in a bit */
 
 		if (node->dlm_notify_callback && node->dlm_notify_result) {
-			log_group(mg, "check_dlm_notify will retry nodeid %d",
-				  node->nodeid);
+			log_group(mg, "check_dlm_notify result %d will retry nodeid %d",
+				  node->dlm_notify_result, node->nodeid);
 			node->dlm_notify_callback = 0;
 			poll_dlm = 1;
 			return 0;
@@ -2065,7 +2067,7 @@ static void process_mountgroup(struct mountgroup *mg)
 	if (!list_empty(&mg->changes))
 		apply_changes(mg);
 	
-	if (list_empty(&mg->changes))
+	if (mg->started_change && list_empty(&mg->changes))
 		recover_and_start(mg);
 }
 



More information about the Cluster-cvs mailing list