Bug 222485 - relocation with specified target does not work
relocation with specified target does not work
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: rgmanager (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Lon Hohberger
Cluster QE
: Regression
Depends On:
  Show dependency treegraph
Reported: 2007-01-12 15:58 EST by Lon Hohberger
Modified: 2009-04-16 18:36 EDT (History)
2 users (show)

See Also:
Fixed In Version: RC
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-02-07 21:15:35 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Lon Hohberger 2007-01-12 15:58:28 EST
Description of problem:

From: 	Simone Gotti
Subject:[Linux-cluster] 2 missing patches in HEAD and RHEL5 branch. (rg_state.c
and ip.sh)
Date: 	Fri, 12 Jan 2007 14:59:53 +0100  (08:59 EST)

Hi all,

On a 2 node openais cman cluster, I failed a network interface and
noticed that it didn't failed over the other node.

Looking at the rgmanager-2.0.16 code I noticed that:

handle_relocate_req is called with preferred_target = -1, but inside
this function, there are 2 checks to see if the preferred_target is
setted, the check is a 'if (preferred_target != 0)' so the function
thinks that a preferred target is choosed. Then, inside the cycle, the
only one target that really exists is "me" (as -1 isn't a real target)
and there a "goto exausted:", the service is then restarted only on the
locale node, where it fails again and so it's stopped. Changing these
checks to "> 0" worked. 

Before writing a patch I noticed that in the RHEL4 CVS tag is used a
NODE_ID_NONE instead of the numeric values, so the problem (not tested)
probably doesn't happen.
Is it probably a forgotten patch on HEAD and RHEL5?

- (other ref omitted; in a separate bugzilla)


Index: rgmanager/src/daemons/rg_state.c
RCS file: /cvs/cluster/cluster/rgmanager/src/daemons/rg_state.c,v
retrieving revision
diff -u -r1.24.4.2 rg_state.c
--- rgmanager/src/daemons/rg_state.c	14 Dec 2006 22:17:21 -0000
+++ rgmanager/src/daemons/rg_state.c	12 Jan 2007 20:57:51 -0000
@@ -1292,7 +1292,7 @@
 		    int *new_owner)
 	cluster_member_list_t *allowed_nodes, *backup = NULL;
-	uint32_t target = preferred_target, me = my_id();
+	int target = preferred_target, me = my_id();
 	int ret, x;
@@ -1308,7 +1308,7 @@
 			return RG_EFORWARD;
-	if (preferred_target != 0) {
+	if (preferred_target >= 0) {
 		allowed_nodes = member_list();
@@ -1380,7 +1380,7 @@
-	if (preferred_target != 0)
+	if (preferred_target >= 0)
 		memb_mark_down(allowed_nodes, preferred_target);
 	memb_mark_down(allowed_nodes, me);
Comment 2 Dean Jansa 2007-01-15 15:49:59 EST
This would block http://testify.test.redhat.com/plancases.cgi?op=view&id=3967 in
a 2 node config.
Comment 3 Kiersten (Kerri) Anderson 2007-01-15 16:47:47 EST
Devel ACK - Regression from RHEL4, blocks QE test for RHEL5 and fix is
available.  Requires a rebuild of the rgmanager package.
Comment 4 RHEL Product and Program Management 2007-01-15 17:00:58 EST
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
Comment 6 RHEL Product and Program Management 2007-01-15 17:26:25 EST
This bugzilla has Keywords: Regression.  

Since no regressions are allowed between releases, 
it is also being marked as a blocker for this release.  

Please resolve ASAP.
Comment 7 Lon Hohberger 2007-01-16 10:36:55 EST
Patch in cvs
Comment 8 RHEL Product and Program Management 2007-02-07 21:15:35 EST
A package has been built which should help the problem described in 
this bug report. This report is therefore being closed with a resolution 
of CURRENTRELEASE. You may reopen this bug report if the solution does 
not work for you.
Comment 9 Nate Straz 2007-12-13 12:18:48 EST
Moving all RHCS ver 5 bugs to RHEL 5 so we can remove RHCS v5 which never existed.

Note You need to log in before you can comment on or make changes to this bug.