Hi all,
In my Linux box, I have kernel 2.4.2 with multicast support and
mrouted-3.9-beta3.
I configure the Ethernet devices as follows:
1: lo: <LOOPBACK,UP> mtu 3924 qdisc noqueue
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 brd 127.255.255.255 scope host lo
2: eth0: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 100
link/ether 00:50:56:bf:79:c8 brd ff:ff:ff:ff:ff:ff
inet 64.103.121.40/24 brd 64.103.121.255 scope global eth0
3: eth1: <BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 100
link/ether 00:50:56:bf:73:41 brd ff:ff:ff:ff:ff:ff
inet 10.0.0.10/24 brd 10.0.0.255 scope global eth1
inet 10.0.1.10/32 scope global eth1
When I activate mrouted (using the -d in order to see debug messages) I saw
that the kernel sent a list of 3 interfaces as a candidate to be VIFs.
The mrouted indeed recognized 3 VIFs one on eth0 and two VIFs on eth1.
Vif # 0 : device eth0, local vif address 64.103.121.40
Vif #1 : device eth1, local vif address 10.0.0.10
Vif #2 : device eth1, local vif address 10.0.1.10
Looking at the mrouted code it looks like that, general queries will send
twice on eth1, one per each VIF (The queries differ in there source IP
address).
Looking at the kernel code (.../ipv4/ipmr.c) it looks like that, the kernel
doesn't support such a case in appropriate way.
For example, then ipmr_find_vif uses the device and not the IP address in
order to find the appropriate vif, to my opinion it is wrong.
int ipmr_find_vif(struct net_device *dev)
{
int ct;
for (ct=maxvif-1; ct>=0; ct--) {
if (vif_table[ct].dev == dev)
break;
}
return ct;
}
To my opinion (and mybe I'm wrong) another problem accrue when the kernel
forwarding multicast traffic. In the function ip_mr_forward looking in the
following code,
it seems that if two client that connected to eth1 but belong to different
vifs joined to the same multicast group, they will received each multicast
packet twice, as the
traffic will be sent on both VIFs.
/*
* Forward the frame
*/
for (ct = cache->mfc_un.res.maxvif-1; ct >= cache->mfc_un.res.minvif;
ct--)
{
if (skb->nh.iph->ttl > cache->mfc_un.res.ttls[ct]) {
if (psend != -1)
ipmr_queue_xmit(skb, cache, psend, 0);
psend=ct;
}
}
if (psend != -1)
ipmr_queue_xmit(skb, cache, psend, !local);
Can someone help me with that?
Thanks
Dror G.
|