fb62e96237
* Resolve a deadlock between the timer and serialize locks. * totemconfig: change minimum RRP threshold * Ignore memb_join messages during flush operations * rrp: Higher threshold in passive mode for mcast (bnc#712037) * rrp: Handle endless loop if all ifaces are faulty (bnc#712037) * A CPG client can sometimes lockup if the local node is in the downlist * Handle errors from totem_mcast * coroipcc: use malloc for path in service_connect * Version cs: 23112099e1c2b620e6976ca099d2b9afc80721aa - corosync 1.4.1 stable release: * main: let poll really stop before totempg_finalize * totemsrp: fix buffer overflows for large clusters (> 100 nodes) * rrp: Handle rollower in passive rrp properly * rrp: handle rollover in active rrp properly * totemconfig: Change default FAIL_TO_RECV_CONST * Fix problem where corosync will segfault if there are gaps in recovery queue * cpgtool/cfgtool: print list of IP with space between items * RRP: redundant ring automatic recovery (fate#310284) * fix typos in cpg_mcast_joined.3 and cpg_zcb_mcast_joined.3 * Remove spinlocks * confdb: Resolve dispatch deadlock * RRP: Fix ring initialization issue for UDPU mode * crypto: rng_make_prng prevent buf overflow * cpg: do_proc_join change list_slice to list_add * totemudp: memset of proper size * coroipcs: init buf in coroipcs_handler_dispatch * iazc: Reduce number of mem alloc and memcpy * coroipcc: Fix unhandled BSD EOF in coroipcc_dispatch_get() OBS-URL: https://build.opensuse.org/package/show/network:ha-clustering:Factory/corosync?expand=0&rev=10
144 lines
4.2 KiB
Diff
144 lines
4.2 KiB
Diff
Only in corosync-1.2.0/exec: cscope.out
|
|
Index: corosync-1.4.1/exec/totemip.c
|
|
===================================================================
|
|
--- corosync-1.4.1.orig/exec/totemip.c
|
|
+++ corosync-1.4.1/exec/totemip.c
|
|
@@ -396,9 +396,6 @@ int totemip_iface_check(struct totem_ip_
|
|
*/
|
|
totemip_sockaddr_to_totemip_convert((struct sockaddr_storage *)sockaddr_in, boundto);
|
|
boundto->nodeid = sockaddr_in->sin_addr.s_addr;
|
|
-#if __BYTE_ORDER == __BIG_ENDIAN
|
|
- boundto->nodeid = swab32 (boundto->nodeid);
|
|
-#endif
|
|
|
|
if (ioctl(id_fd, SIOCGLIFFLAGS, &lifreq[i]) < 0) {
|
|
printf ("couldn't do ioctl\n");
|
|
@@ -648,9 +645,6 @@ int totemip_iface_check(struct totem_ip_
|
|
if (ipaddr.family == AF_INET && ipaddr.nodeid == 0) {
|
|
unsigned int nodeid = 0;
|
|
memcpy (&nodeid, ipaddr.addr, sizeof (int));
|
|
-#if __BYTE_ORDER == __BIG_ENDIAN
|
|
- nodeid = swab32 (nodeid);
|
|
-#endif
|
|
if (mask_high_bit) {
|
|
nodeid &= 0x7FFFFFFF;
|
|
}
|
|
Index: corosync-1.4.1/test/testcpg.c
|
|
===================================================================
|
|
--- corosync-1.4.1.orig/test/testcpg.c
|
|
+++ corosync-1.4.1/test/testcpg.c
|
|
@@ -49,7 +49,6 @@
|
|
|
|
#include <corosync/corotypes.h>
|
|
#include <corosync/cpg.h>
|
|
-#include <corosync/swab.h>
|
|
|
|
static int quit = 0;
|
|
static int show_ip = 0;
|
|
@@ -63,24 +62,6 @@ static void print_cpgname (const struct
|
|
}
|
|
}
|
|
|
|
-static char * node_pid_format(unsigned int nodeid,int pid) {
|
|
- static char buffer[100];
|
|
- if (show_ip) {
|
|
- struct in_addr saddr;
|
|
-#if __BYTE_ORDER == __BIG_ENDIAN
|
|
- saddr.s_addr = swab32(nodeid);
|
|
-#else
|
|
- saddr.s_addr = nodeid;
|
|
-#endif
|
|
- sprintf(buffer, "node/pid %s/%d", inet_ntoa(saddr),pid);
|
|
- }
|
|
- else {
|
|
- sprintf(buffer, "node/pid %d/%d", nodeid, pid);
|
|
- }
|
|
- return buffer;
|
|
-}
|
|
-
|
|
-
|
|
static void DeliverCallback (
|
|
cpg_handle_t handle,
|
|
const struct cpg_name *groupName,
|
|
@@ -89,9 +70,18 @@ static void DeliverCallback (
|
|
void *msg,
|
|
size_t msg_len)
|
|
{
|
|
- printf("DeliverCallback: message (len=%lu)from %s: '%s'\n",
|
|
- (unsigned long int) msg_len, node_pid_format(nodeid, pid),
|
|
+ if (show_ip) {
|
|
+ struct in_addr saddr;
|
|
+ saddr.s_addr = nodeid;
|
|
+ printf("DeliverCallback: message (len=%lu)from node/pid %s/%d: '%s'\n",
|
|
+ (unsigned long int) msg_len,
|
|
+ inet_ntoa(saddr), pid, (const char *)msg);
|
|
+ }
|
|
+ else {
|
|
+ printf("DeliverCallback: message (len=%lu)from node/pid %d/%d: '%s'\n",
|
|
+ (unsigned long int) msg_len, nodeid, pid,
|
|
(const char *)msg);
|
|
+ }
|
|
}
|
|
|
|
static void ConfchgCallback (
|
|
@@ -102,27 +92,51 @@ static void ConfchgCallback (
|
|
const struct cpg_address *joined_list, size_t joined_list_entries)
|
|
{
|
|
int i;
|
|
+ struct in_addr saddr;
|
|
|
|
printf("\nConfchgCallback: group '");
|
|
print_cpgname(groupName);
|
|
printf("'\n");
|
|
for (i=0; i<joined_list_entries; i++) {
|
|
- printf("joined %s reason: %d\n",
|
|
- node_pid_format(joined_list[i].nodeid, joined_list[i].pid),
|
|
- joined_list[i].reason);
|
|
+ if (show_ip) {
|
|
+ saddr.s_addr = joined_list[i].nodeid;
|
|
+ printf("joined node/pid: %s/%d reason: %d\n",
|
|
+ inet_ntoa (saddr), joined_list[i].pid,
|
|
+ joined_list[i].reason);
|
|
+ }
|
|
+ else {
|
|
+ printf("joined node/pid: %d/%d reason: %d\n",
|
|
+ joined_list[i].nodeid, joined_list[i].pid,
|
|
+ joined_list[i].reason);
|
|
+ }
|
|
}
|
|
|
|
for (i=0; i<left_list_entries; i++) {
|
|
- printf("left %s reason: %d\n",
|
|
- node_pid_format(left_list[i].nodeid, left_list[i].pid),
|
|
- left_list[i].reason);
|
|
+ if (show_ip) {
|
|
+ saddr.s_addr = left_list[i].nodeid;
|
|
+ printf("left node/pid: %s/%d reason: %d\n",
|
|
+ inet_ntoa (saddr), left_list[i].pid,
|
|
+ left_list[i].reason);
|
|
+ }
|
|
+ else {
|
|
+ printf("left node/pid: %d/%d reason: %d\n",
|
|
+ left_list[i].nodeid, left_list[i].pid,
|
|
+ left_list[i].reason);
|
|
+ }
|
|
}
|
|
|
|
printf("nodes in group now %lu\n",
|
|
(unsigned long int) member_list_entries);
|
|
for (i=0; i<member_list_entries; i++) {
|
|
- printf("%s\n",
|
|
- node_pid_format(member_list[i].nodeid, member_list[i].pid));
|
|
+ if (show_ip) {
|
|
+ saddr.s_addr = member_list[i].nodeid;
|
|
+ printf("node/pid: %s/%d\n",
|
|
+ inet_ntoa (saddr), member_list[i].pid);
|
|
+ }
|
|
+ else {
|
|
+ printf("node/pid: %d/%d\n",
|
|
+ member_list[i].nodeid, member_list[i].pid);
|
|
+ }
|
|
}
|
|
|
|
/* Is it us??
|