]> git.proxmox.com Git - mirror_corosync.git/commitdiff
totem: Log a message if JOIN or LEAVE message is ignored
authorChristine Caulfield <ccaulfie@redhat.com>
Fri, 17 Apr 2015 14:49:53 +0000 (15:49 +0100)
committerChristine Caulfield <ccaulfie@redhat.com>
Fri, 17 Apr 2015 14:49:53 +0000 (15:49 +0100)
As per recent email thread, this patch adds a log message if a JOIN or
LEAVE message is discarded while corosync is flushing the receive queue.

While ignoring a JOIN message is harmless (it will be resent), ignoring
a LEAVE message can cause a longer state transition as it is treated as
a node crashing rather than leaving gracefully, so the system admin
might be confused as to the cause.

Unfortunately, we can't (at the totemudp level) distinguish between JOIN
or LEAVE messages without a lot more protocol-specific code creeping in
the lower layer so the message is left ambiguous.

Signed-off-by: Christine Caulfield <ccaulfie@redhat.com>
exec/totemudp.c

index 86059af6a33d1155a9226e003c9443c20624779f..8ed87ceadbb0e4461ca2d7bb4cd497945199ddca 100644 (file)
@@ -511,6 +511,7 @@ static int net_deliver_fn (
         */
        message_type = (char *)iovec->iov_base;
        if (instance->flushing == 1 && *message_type == MESSAGE_TYPE_MEMB_JOIN) {
+               log_printf(instance->totemudp_log_level_warning, "JOIN or LEAVE message was thrown away during flush operation.");
                iovec->iov_len = FRAME_SIZE_MAX;
                return (0);
        }