[Openais] [Corosync] [Patch] Add debug logs when a call to sendmsg() fails

Steven Dake sdake at redhat.com
Wed Mar 24 14:08:40 PDT 2010


On Wed, 2010-03-24 at 11:39 +0100, Jerome Flesch wrote:
> Hello,
> 
> I spent some time looking for a problem we had with Corosync when we 
> activate packet filtering on our machines (the packet filter and 
> Corosync are on the same machine). I eventually realized this problem 
> occurred because we filter the loopback (it's more or less related to 
> bug reports https://bugzilla.redhat.com/show_bug.cgi?id=557513 and 
> https://bugzilla.redhat.com/show_bug.cgi?id=576000 ).
> 
> Thing is, even if in the end it was trivial to fix, our packet filter 
> just prevented sendmsg() from sending the packet in a first place, so I 
> didn't even see the packets in my tcpdump session. Having some logs when 
> sendmsg() calls fail could have pointed me to the issue quicker.
> 
> I've joined the patch I used to get error messages when sendmsg() fails, 
> hoping it may later help other people as well. The patch was made on the 
> Flatiron branch but seems to apply also to the trunk.
> 
> Best regards,
> _______________________________________________
> Openais mailing list
> Openais at lists.linux-foundation.org
> https://lists.linux-foundation.org/mailman/listinfo/openais

The patch looks ok but the 
+       if ( res < 0 )
+	{

should be more like
	if (res < 0) {

Please fix that and merge
regards
-steve




More information about the Openais mailing list