Re: When does Linux drop UDP packets?

From: Steven Rostedt
Date: Thu Jun 04 2009 - 12:57:47 EST



On Thu, 4 Jun 2009, Steven Rostedt wrote:

>
> Oh, btw, you don't need to strip LKML from replys (or any Cc), unless it
> is off topic. LKML is a public forum, and as long as things are on topic,
> it is nice to show others the solutions that are found.
>
> >
> > On Thu, 4 Jun 2009, Philipp Reh wrote:
> >
> > > I'm not really sure it is dropped but tcpdump sees the packet and
> > > recvfrom doesn't see it, so I think that the kernel might drop it
> > > somewhere when processing the IP stack logic.
> >
> > Looking at the udp stack, selinux plays a role, and looks like it will
> > drop a packet if it is not in the routing table.
> >
> > Try:
> >
> > # setenforce 0
> >
> > and see if you start seeing packets.
>
> BTW, I used ftrace to look into this:
>
> Enable:
>
> CONFIG_FTRACE
> CONFIG_FUNCTION_TRACER
> CONFIG_FUNCITON_GRAPH_TRACER
> CONFIG_DYNAMIC_FTRACE
>
> Compile and boot:
>
> # mount -t debugfs nodev /sys/kernel/debug
> # cd /sys/kernel/debug
> # echo udp_rcv > set_graph_function
> # echo function_graph > current_tracer
> # cat trace
>

Could you do the above and send me (off list) the output of the trace?

-- Steve

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/