[zeromq-dev] What is the exact issue with enabling MULTICAST_LOOP on ZMQ sockets?

Parag Patel Parag.Patel at fusionts.com
Mon Jun 10 19:02:15 CEST 2013


Thanks for the info Steven.  In your email previous to this, you provided a preferred solution.  Would this work if there are multiple processes that want to send on the same pgm + ipc channel?

From: zeromq-dev-bounces at lists.zeromq.org [mailto:zeromq-dev-bounces at lists.zeromq.org] On Behalf Of Steven McCoy
Sent: Monday, June 10, 2013 12:29 PM
To: ZeroMQ development list
Subject: Re: [zeromq-dev] What is the exact issue with enabling MULTICAST_LOOP on ZMQ sockets?

On 10 June 2013 11:37, Parag Patel <Parag.Patel at fusionts.com<mailto:Parag.Patel at fusionts.com>> wrote:
Does multicast loopback work without known issues on linux (regardless of java or not)?


If you start the subscriber before the publisher it relies on undefined behaviour but works.  The subscriber would thus see unicast packets and the IP stack would not duplicate to the publisher.

If the publisher started first it would bind to the socket and thus only achieve unreliable delivery.

You can verify with a debug build and the following:

publisher:
$ ./daytime -lp 7500 -n "eth0;"

subscriber:
$ PGM_LOSS_RATE=25 ./purinrecv -lp 7500 -n "eth0;"

Set trace level logging to verify NAKs, in the publish-started-first case it would appear similar to:

$ PGM_MIN_LOG_LEVEL=TRACE PGM_LOSS_RATE=25 ./purinrecv -lp 7500 -n "eth0;"
...
"Mon, 10 Jun 2013 12:28:41 -0400" (32 bytes from 167.203.253.7.192.148.30861)
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: nak_rpt_expiry in 2.000000 seconds.
Trace: NAK backoff queue empty.
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: New pending data.
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: New pending data.
Trace: Recv again on not-full
Trace: NCF retry #11 attempt 1/50.            /* NCF retry queue not-empty */
Trace: Wait ncf queue empty.
Trace: nak_rpt_expiry in 2.000000 seconds.
Trace: NAK backoff queue empty.
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: Recv again on not-full
Trace: nak_rpt_expiry in 2.000000 seconds.
Trace: NAK backoff queue empty.
Trace: Discarded unknown PGM packet.            /* receipt of NAK in subscriber */

--
Steve-o
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20130610/be7c5dbf/attachment.htm>


More information about the zeromq-dev mailing list