[Xorp-hackers] Multicast Programming

Luca Giraudo luca.giraudo at gmail.com
Wed Oct 3 06:40:15 PDT 2007

I have a PC with 2 ethernet cards and I want to receive multicast packets
from both the cards: so I have to bind the UDP socket to every IP address on
the PC ( and

I try to do:


const IPv4 local_addr = IPv4Constants::any   //equivalent to INADDR_ANY

                local_addr, default_udp_port, default_multicast_group, ttl,


The error from rtrmgr is this:

[ 2007/10/03 14:12:11 WARNING xorp_fea XrlFeaTarget ] Handling method for
socket4/0.1/udp_open_bind_join failed: XrlCmdError 102 Command failed Cannot
open, bind and join an UDP socket to address ZERO: the address must belong
to a local interface

The solution to this problem is to bind to a specific ipv4 address (I bind
to, but if I bind the socket on a specific address I can't
receive multicast packets from the other card, also when I join the
multicast group on this interface.

In the end, I try also to bind the same socket on both the addresses, but
the second time there is an error, probably because it's possible to call
once the bind on the same socket.

Someone could help me?

Luca Giraudo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/xorp-hackers/attachments/20071003/a7c0ed17/attachment.html 

More information about the Xorp-hackers mailing list