Subject: simple_lock: locking against myself on fresh i386 SMP kernel
To: None <current-users@netbsd.org>
From: Jeff Rizzo <riz@boogers.sf.ca.us>
List: current-users
Date: 07/18/2003 10:16:55
Without running anything (that I'm aware of, anyway) that's using pthreads,
on a -current i386 kernel compiled from sources grabbed 45 minutes ago,
I just got a locking panic.

I was doing an http load test between this system and another one; the
panic seems pretty reproducible.  I don't *think* it's a new problem; I
was running a 1.6T kernel previously, and got a similar thing.

Let me know if any more info would be useful.

+j


simple_lock: locking against myself
lock: 0xc134e128, currently at: /usr/src/sys/kern/kern_event.c:930
on cpu 1                                                          
last locked: /usr/src/sys/kern/kern_event.c:930
last unlocked: /usr/src/sys/kern/kern_event.c:960
kqueue_scan(e726c9b4,6ec,8076000,e72f7f28,e72be934) at netbsd:kqueue_scan+0x1a7
sys_kevent(e72b9304,e72f7f80,e72f7f78,c031eab3,e72b9304) at netbsd:sys_kevent+0x208
syscall_plain(1f,bfbf001f,1f,bfbf001f,bfbff430) at netbsd:syscall_plain+0xc0
Stopped in pid 264.1 (thttpd) at        netbsd:cpu_Debugger+0x4:        leave
db{1}> bt                                                                    
cpu_Debugger(0,0,e72f7f80,4,2) at netbsd:cpu_Debugger+0x4
_simple_lock(c134e128,c04324e0,3a2,1f63,e72f7f28) at netbsd:_simple_lock+0x110
kqueue_scan(e726c9b4,6ec,8076000,e72f7f28,e72be934) at netbsd:kqueue_scan+0x1a7
sys_kevent(e72b9304,e72f7f80,e72f7f78,c031eab3,e72b9304) at netbsd:sys_kevent+0x
208                                                                            
syscall_plain(1f,bfbf001f,1f,bfbf001f,bfbff430) at netbsd:syscall_plain+0xc0
db{1}>  ps                                                                   
 PID           PPID     PGRP        UID S   FLAGS LWPS          COMMAND    WAIT
 192            304      304      32767 2   0x100    1            httpd  netcon
 296            304      304      32767 2   0x100    1            httpd  netcon
 955            304      304      32767 2   0x100    1            httpd  netcon
 295            304      304      32767 2   0x100    1            httpd  netcon
 654            304      304      32767 2   0x100    1            httpd  netcon
 546            304      304      32767 2   0x100    1            httpd  netcon
 692            304      304      32767 2   0x100    1            httpd  netcon
 630            445      630       1002 2  0x4002    1        http_load  select
 847            445      847       1002 2  0x4002    1        http_load  select
 652            445      652       1002 2  0x4002    1        http_load  select
 587            445      587       1002 2  0x4002    1        http_load  select
 230            489      230       1002 2  0x4002    1        http_load  select
 525              1      525       1002 2       0    1           thttpd  kqread
 522              1      522       1002 2       0    1           thttpd  kqread
 356              1      356       1002 2       0    1           thttpd  kqread
>264              1      264       1002 2       0    1           thttpd        
 445            600      445       1002 2  0x4002    1             tcsh   pause
 600            435      435       1002 2   0x100    1             sshd  select
 435            393      435          0 2   0x101    1             sshd   netio
 538            441      538       1002 2  0x4002    1             tcsh   ttyin
 441            471      471       1002 2   0x100    1             sshd  select
 471            393      471          0 2   0x101    1             sshd   netio
 479            478      479       1002 2  0x4002    1             tcsh   ttyin
 478            476      476       1002 2   0x100    1             sshd  select
 476            393      476          0 2   0x101    1             sshd   netio
 489            101      489       1002 2  0x4002    1             tcsh   pause
 101             99       99       1002 2   0x100    1             sshd  select
 99             393       99          0 2   0x101    1             sshd   netio
 96             304      304      32767 2   0x100    1            httpd  netcon
 447            304      304      32767 2   0x100    1            httpd   netio
 466            304      304      32767 2   0x100    1            httpd   netio
 475            304      304      32767 2   0x100    1            httpd   netio
 440            304      304      32767 2   0x100    1            httpd   netio
 446              1      446          0 2  0x4002    1            getty   ttyin
 375              1      375          0 2  0x4002    1            getty   ttyin
 444              1      444          0 2  0x4002    1            getty   ttyin
 433              1      433          0 2  0x4002    1            getty   ttyin
 431              1      431          0 2  0x4002    1            getty   ttyin
 442              1      442          0 2       0    1             cron nanosle
 404              1      404          0 2       0    1            inetd  kqread
 393              1      393          0 2       0    1             sshd  select
 309              1      309          0 2       0    1             ntpd   pause
 281              1      281          0 2       0    1              lpd  select
 304              1      304          0 2       0    1            httpd  select
 238            211      211          0 2       0    1             nfsd    nfsd
 237            211      211          0 2       0    1             nfsd    nfsd
 236            211      211          0 2       0    1             nfsd    nfsd
 221            211      211          0 2       0    1             nfsd    nfsd
 211              1      211          0 2       0    1             nfsd  select
 234              1      234          0 2       0    1           mountd  select
 171              1      171          0 2       0    1          rpcbind  select
 150              1      150          0 2       0    1          syslogd  select
 7                0        0          0 2 0x20200    1         aiodoned aiodone
 6                0        0          0 2 0x20200    1          ioflush  syncer
 5                0        0          0 2 0x20200    1           reaper  reaper
 4                0        0          0 2 0x20200    1       pagedaemon pgdaemo
 3                0        0          0 2 0x20200    1       lfs_writer lfswrit
 2                0        0          0 2 0x20200    1        atapibus0  sccomp
 1                0        1          0 2  0x4000    1             init    wait
 0               -1        0          0 2 0x20200    1          swapper schedul
db{1}>


-- 
Jeff Rizzo                                         http://boogers.sf.ca.us/~riz