Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am receiving IPTV (multicast) from my ISP (Deutsche Telekom) and it is already working without any issues for the main receiver which is directly connected to my dsl router (AVM Fritz!Box 7390).

Now, there is another receiver that can not be connect by ethernet wire. So, I've tried to create a wireless-wired-bridge with my notebook, which doesn't work, because bridges can only include eth interfaces or wireless interfaces in master mode.

------------  wireless   ----------  wired  ----------
|dsl router|  )))   (((  |notebook|  -----  |receiver|
------------             ----------         ----------
                      wlan0       eth0

Receiving multicast on my notebook via wireless interface wlan0 is working fine (signalled with igmpv2 !). When I add a virtual route to 224.0.0.0/4 via eth0, the application (vlc media player) is trying to join multicast groups by signalling with igmpv3 (I am following traffic flows with wireshark). Can that be a problem for forwarding multicast packets later?

The second receiver is directly connected to my notebook. It doesn't matter, whether I realize this by native routing or by nat'ing the traffic going out on wlan0: Unicast is working fine, but multicast is not forwarded. DHCP server is running on notebook and routing directive to the new subnet is also added on the dsl router. I also tried adding multicast routes on the notebook (224.0.0.0/4 via dev eth0 and/or via wlan0) but I did not have success.

The easiest solution would be getting some powerline adapter which support igmpv3 and multicasting, but I'd like to get this stuff working with the notebook as a router, because later this part should be played by a raspberry pi.

Is it possible to forward multicast packets on linux? Which rules are neccessary= Can I realize the eth bridge with managed wlan0 without compiling my own kernel version?

Thanks in advance Erik

share|improve this question

1 Answer 1

up vote 1 down vote accepted

I got a working solution for the environment mentioned above.

On the bridge notebook, which is connected to the internet via wlan0 (192.168.2.0/24) and to the new subnet via eth0 (192.168.28.0/24), I installed everything to make it work as a router. For that reason I added a static route in my dsl router to the new subnet via the laptop. If this is not possible, you can also apply a NAT rule on the bridge with iptables:

sudo iptables -t nat -A POSTROUTING -o wlan0 -s 192.168.28.0/24 -j MASQUERADE

Afterwards, I downloaded igmpproxy from http://sourceforge.net/projects/igmpproxy/ and installed it (install documentation is included in the README file). This little tool (recent version is 0.1) works with IGMPv1 and v2, so I forced the bridge to use v2 with:

sudo sh -c 'echo 2 > /proc/sys/net/ipv4/conf/wlan0/force_igmp_version'
sudo sh -c 'echo 2 > /proc/sys/net/ipv4/conf/eth0/force_igmp_version'

Now, you need to know the network of possible source ip addresses of the multicast streams. In my case the network is 193.0.0.0/8. I created a config file with this content:

quickleave
phyint eth0 downstream  ratelimit 0  threshold 1
phyint wlan0 upstream ratelimit 0 threshold 1
  altnet 192.168.2.0/24 # for local services
  altnet 193.0.0.0/8    # for multicast video streams

igmpproxy can be started using:

sudo igmpproxy -d -vv <config_file_name>

I hope, you can understand everything I was writing about. Enjoy it.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.