0

I am trying to create a multicast messaging service between vlans. When both multicast client and server are in same vlan, the client receives the packet without any issues. When client and server in different vlans, I need to route the multicast packets from vlan1 to vlan2. I am currently using a linux machine with two nic - eth0 and eth1 as a router. I found sources for configuring routers to route multicast packets but I couldn't find sources for using a linux machine to do the same. Could anyone help?

Below is depiction of my setup: setup

1 Answer 1

1

You can use SMCRoute for this (yes, you need a separate daemon for managing multicast routes). SMCRoute can be used to set static multicast routes in the Linux kernel's multicast routing table, which is separate from the unicast routing table. Download the latest release and build it with:

tar xf smcroute-2.4.4.tar.gz
cd smcroute-2.4.4/
./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
make

You can now run make install to install SMCRoute to your system. However, I've chosen not to show that below, that's up to you. The reminder of my reply use paths relative to your build directory.

Now create a smcroute.conf file with the following line:

mroute from eth0 source 192.168.1.2 group 224.0.0.3 to eth1

Start the SMCRoute daemon in the background like this:

sudo ./src/smcrouted -f smcroute.conf

You can then inspect the multicast routing table using one of:

ip mroute
sudo ./src/smcroutectl show routes

Make sure to check the TTL of the multicast stream from the server, it must be >1 to be routed by the kernel.

Also, you may want to look into changing the group of your server. The 224.0.0.* range is reserved for link-local multicast, which by definition should never be routed.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .