Skip to content. | Skip to navigation

Personal tools


You are here: Home / Wiki / Kb57


Emulab FAQ: Software Setup: Does Emulab support IP Multicast?

Emulab FAQ: Software Setup: Does Emulab support IP Multicast?

In short, yes, the local nodes in Emulab (but not all remote Netbed nodes) support IP Multicast on the experimental network. In order to use it, you must have a kernel that supports it, and if you want multicast routing, you'll need to enable mrouted. (You can do it manually, or automatically via program objects or startup commands, but the rtproto commands will not do it.) The reason `mrouted' is required is that IP mutlicast requires an "IGMP querier" to do periodic polls for group membership - without such a querier, members of the group will time out and leave after a few minutes. This role is normally performed by a multicast-capable router, and since the experimental network is your own "private world", you'll need to run your own multicast router on each link or LAN that will carry multicast traffic (even if that router is not routing packets between subnets).

To enable mrouted on recent versions of FreeBSD, place the following in /etc/rc.conf: mrouted_enable="YES". Reboot, or run /etc/rc.d/mrouted start. (As noted above, you can set up a startup command in your NS file to do this automatically when the node boots.) Enabling mrouted on Linux will vary depending on the distribution you are using: you may need to find and install the RPM for it (which can also be done in your NS file), and set up the appropriate init scripts in /etc.

When using multicast, there are a few issues you need to be aware of. The first is the fact that multicast traffic will often find the control network, rather than the experimental network, which you don't want. See this section of the tutorial for information about the control net. There are two ways to work around the control net. The first is to set a route for all multicast addresses ( to go out the experimental interface of your node (which will usually have a private IP address, such as 10.0.0.X). The second is to have your program use the IP_MULTICAST_IF sockopt to bind to a particular interface.

You should also stay away from multicast addresses that have special meanings, such as . You can get a list of these addresses from IANA here.