[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1338543286.2760.1477.camel@edumazet-glaptop>
Date: Fri, 01 Jun 2012 11:34:46 +0200
From: Eric Dumazet <eric.dumazet@...il.com>
To: Hans Schillstrom <hans.schillstrom@...csson.com>
Cc: netdev <netdev@...r.kernel.org>,
Neal Cardwell <ncardwell@...gle.com>,
Tom Herbert <therbert@...gle.com>,
Jesper Dangaard Brouer <brouer@...hat.com>
Subject: Re: [PATCH net-next] tcp: avoid tx starvation by SYNACK packets
On Fri, 2012-06-01 at 09:36 +0200, Hans Schillstrom wrote:
> On Thursday 31 May 2012 23:56:37 Eric Dumazet wrote:
> > From: Eric Dumazet <edumazet@...gle.com>
> >
> > pfifo_fast being the default Qdisc, its pretty easy to fill it with
> > SYNACK (small) packets while host is under SYNFLOOD attack.
> >
> > Packets of established TCP sessions are dropped and host appears almost
> > dead.
> >
> > Avoid this problem assigning TC_PRIO_FILLER priority to SYNACK
> > generated in SYNCOOKIE mode, so that these packets are enqueued into
> > pfifo_fast band 2.
> >
> > Other packets, queued to band 0 or 1 are dequeued before any SYNACK
> > packets waiting in band 2.
> >
> Thanks Eric,
> the patch is in under test now.
>
Thanks Hans
By the way, I found that we have another problem because __qdisc_run()
( called from net_tx_action()) only pushes 64 frames per invocation, and
in fact less if need_resched() breaks the loop.
Its not fair with the net_rx_action, allowed to receive 64 frames per
NAPI device regardless of need_resched().
So if our cpu is flooded by incoming frames, our output is muted.
Basically we need to make SYNACK frames aware of multiqueue devices,
since they currently all end on one single queue.
Obvious choice is to reflect incoming SYN packet @queue_mapping to
SYNACK packet.
I am testing a patch right now.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists