netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: Route cache performance
@ 2005-08-24 16:06 Simon Kirby
  0 siblings, 0 replies; 36+ messages in thread
From: Simon Kirby @ 2005-08-24 16:06 UTC (permalink / raw)
  To: netdev

On Wed, Aug 24, 2005 at 04:59:32PM +0200, Robert Olsson wrote:

> You could probably also try to set hash table very large.
> via the boot option rt_hash_entries.

I have, and it just grows until it uses up all memory and kills my SSH
session.

> and gc_thresh to 1/4 of that as an experiment.

The threshold appears to have no difference except for where it settles
once I stop the DoS traffic.

> Also if you find any 2.6 version that work a la 2.4 it's 
> a good start.

It's weird because 2.6.11 is a lot better in that the GC appears to work
for some time, but it eventually something happens and it also hits
max_size and overflows continually.  I think I'm going to have to find a
version that works consistently as opposed to being "a little better".

I was just testing it again and noticed that on 2.6.11 it seems to be
almost stable at 71,000 entries (max_size = 131072) but as soon as I type
"dmesg" in another SSH window it will hit 131072.  It's as if it's at
equilibrium with the packet creation.

It may just be as simple as something that has always been buggy but
doesn't show up in 2.4 because the e1000 driver is more efficient there
(and/or some other piece of networking, which appears to be more likely).

Simon-

^ permalink raw reply	[flat|nested] 36+ messages in thread
* Route cache performance
@ 2005-08-15 21:38 Simon Kirby
  2005-08-16  2:23 ` Eric Dumazet
  0 siblings, 1 reply; 36+ messages in thread
From: Simon Kirby @ 2005-08-15 21:38 UTC (permalink / raw)
  To: Robert Olsson, netdev

Hi!

Well, after a few years of other work :), I have finally got around to
setting up some more permanent forwarding / route cache performance
test boxes.  I noticed the route trie option in the newer 2.6 kernels
and figured it would be a good time to revisit things.

Test setup:

[Xeon w/e1000]---[Opteron w/dual e1000]---[Xeon w/e1000]

The Xeons are 2.4 GHz boxes and the Opteron is a 140.  At some point
I intend to compare the performance of a 32 bit versus 64 bit kernel.

I'm only able to get pktgen to spit out about 660 kpps from the test 2.4
Xeon box with onboard e1000 (pause disabled), but already I notice some
disappointing results.  The old 2.4.27 kernel I last did tests with seems
to do a much better job of forwarding small packets (static src/dst) than
2.4.31 and 2.6.12.

On the (leftmost) sending box, 2.4.27, 2.4.31, and 2.6.12 all seem to do
fairly well at transmission with pktgen.  The 2.6 pktgen seems a little
better (no transmission errors and a few more Mbps), so I've been using
2.6.12.  With fixed dst packets and pause disabled via ethtool, about
660 kpps is sent continuously.  juno (spoofed source, userspace) seems to
do about 360 kpps.  The routes and packets are set up to route through
the Opteron box to the receiving (rightmost) box.

I've noticed that e1000 changes integrated in 2.6.11-bk2 are resulting in
the forwarding test box slowing down enough that it seems to be exposing
"dst cache overflow", even though under slightly less load the gc seems
to be able to keep up.  Robert, if I read correctly it seems that the
e1000 NAPI changes were some fixes you submitted?

Something appears to be different in the rtcache GC or perhaps NAPI or
some other interaction, because firing juno at 2.4 does not show any
problems while I can't seem to get 2.6.12 to _not_ print "dst cache
overflow".  2.6.11 (pre-bk2) seems a little better at start, but any kind
of burst seems to make the route cache entries exceed gc and then the
slower hash lookups seem to make it get stuck at max_size (and printing
"dst cache overflow") until the attack stops, even with gc_min_interval
set to 0 (really 0).

Anyway, I'm still in early testing stages here but it seems it's still as
easy as ever to destroy routers (and hosts?) with a fairly small stream
of small packets which create new rtcache entries.  These days, 184 Mbps
is starting to fall under the "small" DoS attack category, too.

I notice the hash table size is still only 4096 buckets for 512 MB, which
isn't that wonderful when it hits a max_size of 65536 (w/512 MB)...

Simon-

^ permalink raw reply	[flat|nested] 36+ messages in thread
[parent not found: <20050301220743.GF2554@netnation.com>]

end of thread, other threads:[~2005-09-17 15:17 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-24 16:06 Route cache performance Simon Kirby
  -- strict thread matches above, loose matches on Subject: below --
2005-08-15 21:38 Simon Kirby
2005-08-16  2:23 ` Eric Dumazet
2005-08-23 19:08   ` Simon Kirby
2005-08-23 19:56     ` Robert Olsson
2005-08-24  0:01       ` Simon Kirby
2005-08-24  3:50         ` Robert Olsson
2005-08-25 18:11         ` Simon Kirby
2005-08-25 20:05           ` Alexey Kuznetsov
2005-08-25 21:22             ` Simon Kirby
2005-08-26 11:55               ` Alexey Kuznetsov
2005-08-26 19:49                 ` Robert Olsson
2005-09-06 23:57                   ` Simon Kirby
2005-09-07  1:19                     ` Alexey Kuznetsov
2005-09-07 15:03                       ` Robert Olsson
2005-09-07 16:55                         ` Simon Kirby
2005-09-07 17:21                           ` Robert Olsson
2005-09-07 14:45                     ` Robert Olsson
2005-09-07 16:28                       ` Simon Kirby
2005-09-07 16:49                         ` Robert Olsson
2005-09-07 16:57                           ` Simon Kirby
2005-09-07 19:59                         ` Alexey Kuznetsov
2005-09-13 22:14                           ` Simon Kirby
2005-09-14  8:04                             ` Robert Olsson
2005-09-17  0:28                               ` Simon Kirby
2005-09-17  9:04                                 ` Martin Josefsson
2005-09-17 15:17                                 ` jamal
2005-09-15 21:04                             ` Alexey Kuznetsov
2005-09-15 21:30                               ` Robert Olsson
2005-09-15 22:21                                 ` Alexey Kuznetsov
2005-09-16 12:18                                   ` Robert Olsson
2005-09-16 19:04                                     ` Alexey Kuznetsov
2005-09-16 19:22                                       ` Ben Greear
2005-09-16 19:57                                       ` Robert Olsson
     [not found] <20050301220743.GF2554@netnation.com>
     [not found] ` <16940.9990.975632.115834@robur.slu.se>
2005-03-09  1:45   ` Simon Kirby
2005-03-09 12:05     ` Robert Olsson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).