Subject: port-amd64/33980: 100% system usage on recent -current kernels
To: None <port-amd64-maintainer@netbsd.org, gnats-admin@netbsd.org,>
From: None <damon@brodiefamily.org>
List: netbsd-bugs
Date: 07/12/2006 00:30:01
>Number:         33980
>Category:       port-amd64
>Synopsis:       100% system usage on recent -current kernels
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-amd64-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jul 12 00:30:01 +0000 2006
>Originator:     Damon Brodie
>Release:        NetBSD 3.99.21
>Organization:
	
>Environment:
	
	
System: NetBSD nomad.brodiefamily.org 3.99.21 NetBSD 3.99.21 (NOMAD) #8: Tue Jul 11 19:58:22 EDT 2006 damon@nomad.brodiefamily.org:/usr/obj/sys/arch/amd64/compile/NOMAD amd64
Architecture: x86_64
Machine: amd64
>Description:
	On recent kernels (sometime after July 1) runnign just about anything results
in 100% system cpu usage, and the machine is very slow.  Here is a vmstat before and
after while running a compile:

Before:

nomad:/usr/src# uname -a
NetBSD nomad.brodiefamily.org 3.99.21 NetBSD 3.99.21 (NOMAD) #4: Sat Jul  1 09:58:11 EDT 2006  damon@nomad.brodiefamily.org:/usr/obj/sys/arch/amd64/compile/NOMAD amd64
nomad:/raid/home/damon% vmstat 1
 procs    memory      page                       disks      faults      cpu
 r b w    avm    fre  flt  re  pi   po   fr   sr m0 w0 w1   in   sy  cs us sy id
 1 0 0 230416  74580  147   0   0    0    0    0  0  9  0   13  275  25  0  0 99
 1 0 0 223692  81320 15719   0   0    0    0    0  0 47  0   75 8064 218 89  8  3
 1 0 0 233724  71212 15249   0   0    0    0    0  0 31  0   49 7156 143 82 17  1
 1 0 0 240900  63916 10520   0   0    0    0    0  0 17  0   26 4205  88 94  6  0
 1 0 0 252236  52396 3219   0   0    0    0    0  0  7  0    9 1034  35 99  1  0
 1 0 0 245236  59520 7381   0   0    0    0    0  0 16  0   21 2728  64 96  3  1
 1 1 0 240184  64416 9938   0   0    0    0    0  0 19  1   32 4375 107 90 10  0
 1 0 0 234344  70536 9935   0   0    0    0    0  0 122  0  137 4678 726 89 10  1
 1 0 0 224232  80688 7401   0   0    0    0    0  0 13  0   34 2797  67 89 11  0
 1 0 0 226648  78260 12154   0   0    0    0    0  0 45  0   62 5834 134 90 10  0
 1 0 0 246392  58308 10170   0   0    0    0    0  0 11  0   18 3141  59 96  4  0
 1 0 0 232600  72216 6372   0   0    0    0    0  0 71  0   77 2374 112 89  9  2
 1 0 0 240624  64116 11209   0   0    0    0    0  0 24  0   37 4857 113 89 10  1
 1 0 0 243168  61524 7351   0   0    0    0    0  0 15  0   19 2693  65 93  7  0

After:

nomad:/usr/src# uname -a
NetBSD nomad.brodiefamily.org 3.99.21 NetBSD 3.99.21 (NOMAD) #8: Tue Jul 11 19:58:22 EDT 2006  damon@nomad.brodiefamily.org:/usr/obj/sys/arch/amd64/compile/NOMAD amd64
nomad:/raid/home/damon% vmstat 1
 procs    memory      page                       disks      faults      cpu
 r b w    avm    fre  flt  re  pi   po   fr   sr m0 w0 w1   in   sy  cs us sy id
 1 0 0  53260 421132  798   0   0    0    0    0  0 29  1   39 1136 116  0 60 40
 1 0 0  52936 421424 1118   0   0    0    0    0  0  0  0    2 1108  83 0 100  0
 1 0 0  53260 421128 1132   0   0    0    0    0  0  0  0   15 1056  98 0 100  0
 1 0 0  53220 421144 1071   0   0    0    0    0  0  0  0    2 1023  90 0 100  0
 1 0 0  52636 421796 1101   0   0    0    0    0  0  2  0    5 1076  99  0 98  2
 1 0 0  53132 421300 1206   0   0    0    0    0  0  1  0    3 1170  99 0 100  0
 1 0 0  52144 422356 1319   0   0    0    0    0  0  4  0    8 1043 102  0 96  4
 1 0 0  53092 421296 1520   0   0    0    0    0  0  7  0   13 1408 127 0 100  0
 1 0 0  52780 421688  676   0   0    0    0    0  0  0  0    2  725  63 0 100  0
 1 0 0  53568 420816 1112   0   0    0    0    0  0  0  0    4 1109  91 0 100  0
 2 0 0  53156 421168 1671   0   0    0    0    0  0  0  0    4 1485 129 0 100  0
 1 1 0  53296 420908  969   0   0    0    0    0  0 29  0   31  915 134 0 100  0
 2 0 0  54992 418976  340   0   0    0    0    0  0 70  0   68  535 156 0 100  0
 2 0 0  55944 417672 1643   0   0    0    0    0  0 45  1   46 1042 156 0 100  0
 2 0 0  56224 417408 1585   0   0    0    0    0  0 43  0   44 1096 149 0 100  0

Notice that before the cpu was mostly user, and after it is all system.

>How-To-Repeat:
	Use sources from some time after July 1, compile a kernel and notice how most of the usage is system.
>Fix:
	Not sure.

>Unformatted: