Bug 244469 - CPG: bad elements in in member_list for cpg_confchg_fn
CPG: bad elements in in member_list for cpg_confchg_fn
Status: CLOSED NOTABUG
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: openais (Show other bugs)
5.0
All Linux
low Severity low
: ---
: ---
Assigned To: Steven Dake
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-15 17:42 EDT by Jonathan Earl Brassow
Modified: 2016-04-26 11:52 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-06-15 18:45:18 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jonathan Earl Brassow 2007-06-15 17:42:01 EDT
In my cpg_confchg_fn callback function:

	LOG_PRINT("* MEMBERS:");
	for (i = 0; i < member_list_entries; i++)
		LOG_PRINT("*   %d", member_list[i].nodeid);
	LOG_PRINT("* LEAVING:");

Output:
Jun 15 16:27:46 jb-xen-03 clogd[2141]: * MEMBERS:
Jun 15 16:27:46 jb-xen-03 clogd[2141]: *   3
Jun 15 16:27:46 jb-xen-03 clogd[2141]: *   3
Jun 15 16:27:46 jb-xen-03 clogd[2141]: *   3
Jun 15 16:27:46 jb-xen-03 clogd[2141]: * LEAVING:
Comment 1 Steven Dake 2007-06-15 18:45:18 EDT
i ran testcpg on the machines and testcpg works properly.  I then suspected that
logging.c/logging.h from cmirror has some problem so I copied over that code
into my testcpg program.  I copied the config logging messages into testcpg on
xen03 and replaced LOG_PRINT with printf and receive the following output:
[root@jb-xen-03 test]# ./testcpg
Type EXIT to finish
* CPG config callback *********************
* JOINING (1):
*   nodeid: 3, pid: 2815
* MEMBERS (3):
*   nodeid: 3, pid: 2815
*   nodeid: 2, pid: 2656
*   nodeid: 1, pid: 2656
* LEAVING (0):
*****************************************


whereas

the log output with LOG_PRINT being used in testcpg contains:


Since these dont match and regular printf is pretty simple, this seems to
indicate an error in the logging.c code in cmirror.
Jun 15 17:42:20 jb-xen-03 clogd[2815]: * CPG config callback *********************
Jun 15 17:42:20 jb-xen-03 clogd[2815]: * JOINING (1):
Jun 15 17:42:20 jb-xen-03 clogd[2815]: *   nodeid: 3, pid: 2815
Jun 15 17:42:20 jb-xen-03 clogd[2815]: * MEMBERS (3):
Jun 15 17:42:20 jb-xen-03 clogd[2815]: *   nodeid: 3, pid: 2815
Jun 15 17:42:20 jb-xen-03 last message repeated 2 times
Jun 15 17:42:20 jb-xen-03 clogd[2815]: * LEAVING (0):
Jun 15 17:42:20 jb-xen-03 clogd[2815]: *****************************************

The code with both log output methods (logging.c and also printf) is contained
on the xen-03 node.

Regards
-steve

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