Bug #346
Fwd: [PATCH ipv4 multicast] Fix IPv4 multicast over network namespaces
| Status: | New | Start date: | ||
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | - | % Done: | 0% |
|
| Category: | - | Spent time: | - | |
| Target version: | 1st Public Cerowrt release |
Description
I've been wondering what was so wrong about routed multicast....
---------- Forwarded message ----------
From: Benjamin LaHaise <bcrl@kvack.org>
Date: Tue, Mar 27, 2012 at 9:12 AM
Subject: [PATCH ipv4 multicast] Fix IPv4 multicast over network namespaces
To: "David S. Miller" <davem@davemloft.net>
Cc: netdev@vger.kernel.org
When using multicast over a local bridge feeding a number of LXC guests
using veth, the LXC guests are unable to get a response from other guests
when pinging 224.0.0.1. Multicast packets did not appear to be getting
delivered to the network namespaces of the guest hosts, and further
inspection showed that the incoming route was pointing to the loopback
device of the host, not the guest. This lead to the wrong network namespace
being picked up by sockets (like ICMP). Fix this by using the correct
network namespace when creating the inbound route entry.
---
net/ipv4/route.c | 2 ), 1 deletions()
1 files changed, 1 insertions(
diff --git a/net/ipv4/route.c b/net/ipv4/route.c
index 12ccf88..3b110a4 100644
--- a/net/ipv4/route.c
++ b/net/ipv4/route.c@ -2042,7 +2042,7 @ static int ip_route_input_mc(struct sk_buff *skb,
__be32 daddr, __be32 saddr,
if (err < 0)
goto e_err;
}
- rth = rt_dst_alloc(init_net.loopback_dev,
rth = rt_dst_alloc(dev_net(dev)->loopback_dev,
IN_DEV_CONF_GET(in_dev, NOPOLICY), false);
if (!rth)
goto e_nobufs;
History
Updated by Dave Täht about 1 year ago
- Target version set to 1st Public Cerowrt release