NVIDIA Accelerated IO (XLIO) Documentation Rev 3.20.7
NVIDIA Accelerated IO (XLIO) Documentation Rev 3.20.7

Appendix: Multicast Routing

All applications that receive and/or transmit multicast traffic on a multiple-interface host should define the network interfaces through which they would prefer to receive or transmit the various multicast groups.

If a networking application can use existing socket API semantics for multicast packet receive and transmit, the network interface can be defined by mapping the multicast traffic. In this case, the routing table does not have to be updated for multicast group mapping. The socket API setsockopt handles these definitions.

When the application uses setsockopt with IP_ADD_MEMBERSHIP/IPv6_JOIN_GROUP for the receive path multicast join request, it defines the interface through which it wants the XLIO to join the multicast group, and listens for incoming multicast packets for the specified multicast group on the specified socket.

IGMPv3 source specific multicast: when the application uses setsockopt with IP_ADD_SOURCE_MEMBERSHIP/MCAST_JOIN_SOURCE_GROUP for the receive path multicast join request, it defines the interface through which it wants the XLIO to join the multicast group, and listens for incoming multicast packets for the specified multicast group and from a specified source on the specified socket.

When the application uses setsockopt with IP_MULTICAST_IF/IPV6_MULTICAST_IF on the transmit path, it defines the interface through which the XLIO will transmit outgoing multicast packets on that specific socket.

If the user application does not use any of the above setsockopt socket lib API calls, the XLIO uses the network routing table mapping to find the appropriate interface to be used for receiving or transmitting multicast packets.

Use the route command to verify that multicast addresses in the routing table are mapped to the interface you are working on. If they are not mapped, you can map them as follows:

Copy
Copied!
            

#route add -net 224.0.0.0 netmask 240.0.0.0 dev ib0 #ip –6 route add ff00::/8 dev ib0 metric 1

It is best to perform the mapping before running the user application with XLIO, so that multicast packets are routed via the 10Gb/s Ethernet interface and not via the default Ethernet interface eth0.

The general rule is that the XLIO routing is the same as the OS routing.

© Copyright 2023, NVIDIA. Last updated on Nov 3, 2023.