Multiple netgraph threads

Vladimir V. Kobal vlad at prokk.net
Thu Dec 4 06:08:30 PST 2008


Alexander Motin wrote:
>I have uploaded that patch back. Not sure is it correct at this moment,
>there was some changes, but that time it worked fine.

Thanks a lot. I've installed the patch with some changes. I'm using the
7-STABLE (ng_base.c,v 1.135.2.10) at a production NAS. Corresponding patch
is in the attachment.

I can't say anything of performance yet. Not enough statistics data is
collected at the moment. But there is a strangeness with ng_queue threads:
under high network load top display too low WCPU (while TIME has a normal
value) for these threads. The maximum WCPU I saw under lower network load
was 35-40% per ng_queue thread. Are there any ideas? Am I using correctly
the kthread_create() in the patch?

last pid: 21000;  load averages:  1.52,  1.40,  1.02    up 0+00:25:39
14:24:28
79 processes:  5 running, 63 sleeping, 11 waiting
CPU:  0.3% user,  0.0% nice, 41.4% system,  0.6% interrupt, 57.7% idle
Mem: 40M Active, 11M Inact, 166M Wired, 112K Cache, 77M Buf, 1731M Free
Swap: 2048M Total, 2048M Free

  PID USERNAME  THR PRI NICE   SIZE    RES STATE  C   TIME   WCPU COMMAND
   12 root        1 171 ki31     0K    16K RUN    2  18:36 58.50% idle: cpu2
   11 root        1 171 ki31     0K    16K RUN    3  18:02 63.87% idle: cpu3
   13 root        1 171 ki31     0K    16K CPU1   1  17:56 41.26% idle: cpu1
   14 root        1 171 ki31     0K    16K CPU0   0  17:20 59.96% idle: cpu0
    2 root        1  96    -     0K    16K sleep  0   7:16  0.20% ng_queue0
    3 root        1  96    -     0K    16K sleep  1   7:13  0.20% ng_queue1
   25 root        1 -68    -     0K    16K -      1   5:44 36.67% em0 taskq
   26 root        1 -68    -     0K    16K -      2   5:26 35.60% em1 taskq
   16 root        1 -32    -     0K    16K WAIT   0   1:30  3.86% swi4:
clock
 2538 root        1  48    0 36720K 15228K select 3   0:25  0.59% mpd5 

--
Vladimir Kobal
-------------- next part --------------
A non-text attachment was scrubbed...
Name: netgraph.threads.patch
Type: application/octet-stream
Size: 4075 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-net/attachments/20081204/79ea8a8c/netgraph.threads.obj


More information about the freebsd-net mailing list