witness: thread 0xffff800020b5e9f8 exiting with the following locks held: exclusive rrwlock inode r = 0 (0xfffffd806e4c02c0) #0 witness_lock+0x52e sys/kern/subr_witness.c:1163 #1 rw_enter+0x46d sys/kern/kern_rwlock.c:306 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:435 #3 VOP_LOCK+0x4b sys/kern/vfs_vops.c:602 #4 vn_rdwr+0x109 vn_lock sys/kern/vfs_vnops.c:561 [inline] #4 vn_rdwr+0x109 sys/kern/vfs_vnops.c:317 #5 acct_process+0x5db sys/kern/kern_acct.c:221 #6 exit1+0x361 sys/kern/kern_exit.c:208 #7 sys_exit+0x17 sys/kern/kern_exit.c:94 #8 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:92 [inline] #8 syscall+0x552 sys/arch/amd64/amd64/trap.c:555 #9 Xsyscall+0x128 panic: thread 0xffff800020b5e9f8 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *269433 61097 0 0x14000 0x200 1 reaper db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:207 witness_thread_exit(ffff800020b5e9f8) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020aff640) at reaper+0x14c sys/kern/kern_exit.c:423 end trace frame: 0x0, count: 11 https://www.openbsd.org/ddb.html describes the minimum info required in bug reports. Insufficient info makes it difficult to find and fix bugs. ddb{1}> ddb{1}> set $lines = 0 ddb{1}> set $maxwidth = 0 ddb{1}> show panic thread 0xffff800020b5e9f8 cannot exit while holding sleeplocks ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:207 witness_thread_exit(ffff800020b5e9f8) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020aff640) at reaper+0x14c sys/kern/kern_exit.c:423 end trace frame: 0x0, count: -4 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800020afd230 rbx 0xffff800020afd2e0 rdx 0xffff800020aff640 rcx 0 rax 0 r8 0xffffffff81c91603 kprintf+0x173 r9 0x1 r10 0x25 r11 0x82c9550815ec26ad r12 0x3000000008 r13 0xffff800020afd240 r14 0x100 r15 0x1 rip 0xffffffff81166418 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020afd220 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (reaper) pid=269433 stat=onproc flags process=14000 proc=200 pri=4, usrpri=52, nice=20 forw=0xffffffffffffffff, list=0xffff800020ab1b28,0xffff800020afec70 process=0xffff800020aea708 user=0xffff800020af8000, vmspace=0xffffffff82365e48 estcpu=2, cpticks=4, pctcpu=0.62 user=0, sys=4, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 75640 7192 18078 0 3 0x82 nanosleep syz-executor.1 22963 395385 0 0 3 0x14200 acct acct 79584 190094 18078 0 3 0x82 nanosleep syz-executor.0 57352 440309 1 0 3 0x100083 ttyin getty 23296 303072 0 0 3 0x14200 bored sosplice 18078 41881 86449 0 3 0x82 thrsleep syz-fuzzer 18078 141859 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 42258 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 334262 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 299682 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 210541 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 242694 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 51745 86449 0 3 0x4000082 thrsleep syz-fuzzer 18078 465785 86449 0 3 0x4000082 kqread syz-fuzzer 18078 153525 86449 0 3 0x4000082 thrsleep syz-fuzzer 86449 457636 98858 0 3 0x10008a pause ksh 98858 483374 91939 0 3 0x92 select sshd 91939 255643 1 0 3 0x80 select sshd 93888 115065 88128 74 3 0x100092 bpf pflogd 88128 453104 1 0 3 0x80 netio pflogd 73645 41641 93864 73 3 0x100010 ffs_fsync syslogd 93864 378136 1 0 3 0x100082 netio syslogd 90177 359264 0 0 3 0x14200 pgzero zerothread 73685 109065 0 0 3 0x14200 aiodoned aiodoned 45643 343268 0 0 3 0x14200 syncer update 37744 320444 0 0 3 0x14200 cleaner cleaner *61097 269433 0 0 7 0x14200 reaper 15895 161097 0 0 3 0x14200 pgdaemon pagedaemon 99188 394353 0 0 3 0x14200 bored crynlk 19838 308757 0 0 3 0x14200 bored crypto 61941 428086 0 0 3 0x40014200 acpi0 acpi0 90750 493599 0 0 3 0x40014200 idle1 16171 6835 0 0 3 0x14200 bored softnet 37180 509730 0 0 3 0x14200 bored systqmp 43247 399892 0 0 3 0x14200 bored systq 90135 154466 0 0 3 0x40014200 bored softclock 46066 170203 0 0 7 0x40014200 idle0 82232 348961 0 0 2 0x40014200 smr 1 482987 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 73645 (syslogd) thread 0xffff800020b60c68 (41641) exclusive rrwlock inode r = 0 (0xfffffd806eb00b38) #0 witness_lock+0x52e sys/kern/subr_witness.c:1163 #1 rw_enter+0x46d sys/kern/kern_rwlock.c:306 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:435 #3 VOP_LOCK+0x4b sys/kern/vfs_vops.c:602 #4 vn_lock+0x6e sys/kern/vfs_vnops.c:561 #5 sys_fsync+0x114 sys/kern/vfs_syscalls.c:2806 #6 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:92 [inline] #6 syscall+0x552 sys/arch/amd64/amd64/trap.c:555 #7 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9613 6416K 7745K 78643K 35584 0 0 pcb 13 8K 8K 78643K 645 0 0 rtable 117 12K 13K 78643K 3260 0 0 ifaddr 90 24K 28K 78643K 1166 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 4K 78643K 1893 0 0 iov 0 0K 28K 78643K 1142 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1200 75K 77K 78643K 10469 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 9K 78643K 135 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 926 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12765 0 0 file desc 4 9K 25K 78643K 9899 0 0 sigio 0 0K 0K 78643K 112 0 0 proc 54 51K 83K 78643K 2820 0 0 subproc 32 2K 2K 78643K 665 0 0 NFS srvsock 1 0K 0K 78643K 1 0 0 NFS daemon 1 16K 16K 78643K 1 0 0 ip_moptions 0 0K 0K 78643K 834 0 0 in_multi 33 2K 2K 78643K 698 0 0 ether_multi 1 0K 0K 78643K 48 0 0 mrt 0 0K 0K 78643K 37 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 114 503K 503K 78643K 114 0 0 exec 0 0K 1K 78643K 1412 0 0 pfkey data 0 0K 0K 78643K 4 0 0 pagedep 1 8K 8K 78643K 1 0 0 inodedep 1 32K 32K 78643K 1 0 0 newblk 1 0K 0K 78643K 1 0 0 VM swap 7 26K 26K 78643K 7 0 0 UVM amap 115 22K 32K 78643K 33526 0 0 UVM aobj 130 6K 6K 78643K 139 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 1K 78643K 501 0 0 NDP 22 0K 0K 78643K 368 0 0 temp 243 2753K 3392K 78643K 174672 0 0 kqueue 0 0K 0K 78643K 66 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{1}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 84 0 78 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 80 458 0 458 3 2 1 1 0 8 1 rtentry 112 475 0 431 3 1 2 2 0 8 0 unpcb 120 3216 0 3208 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 8050 0 8050 1 1 0 1 0 8 0 tcpcb 544 1475 0 1471 1 0 1 1 0 8 0 inpcb 280 4450 0 4446 6 5 1 2 0 8 0 rttmr 72 5 0 5 5 5 0 1 0 8 0 nd6 48 117 0 111 1 0 1 1 0 8 0 pkpcb 40 64 0 64 22 22 0 1 0 8 0 swfcl 56 4 0 0 1 0 1 1 0 8 0 ppxss 1128 171 0 171 31 31 0 1 0 8 0 pffrag 232 20 0 20 12 12 0 1 0 482 0 pffrnode 88 20 0 20 12 12 0 1 0 8 0 pffrent 40 51 0 51 12 12 0 1 0 8 0 pfosfp 40 846 0 423 5 0 5 5 0 8 0 pfosfpen 112 1428 0 714 21 0 21 21 0 8 0 pfstitem 24 233 0 202 1 0 1 1 0 8 0 pfstkey 112 233 0 202 1 0 1 1 0 8 0 pfstate 328 233 0 202 4 1 3 3 0 8 0 pfrule 1360 21 0 16 2 1 1 2 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 1926 0 1728 23 10 13 13 0 8 0 art_table 32 1927 0 1728 2 0 2 2 0 8 0 art_node 16 460 0 420 1 0 1 1 0 8 0 sysvmsgpl 40 16 0 11 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 924 0 914 1 0 1 1 0 8 0 shmpl 112 137 0 9 4 0 4 4 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 16564 0 15129 47 0 47 47 0 8 0 ffsino 272 16564 0 15129 96 0 96 96 0 8 0 nchpl 144 30446 0 28810 62 0 62 62 0 8 0 uvmvnodes 72 5926 0 0 108 0 108 108 0 8 0 vnodes 200 5926 0 0 312 0 312 312 0 8 0 namei 1024 100027 0 100027 3 2 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 12 0 12 9 9 0 1 0 8 0 scxspl 192 92581 0 92580 40 39 1 6 0 8 0 plimitpl 152 899 0 892 1 0 1 1 0 8 0 sigapl 432 9995 0 9983 3 1 2 3 0 8 0 futexpl 56 116141 0 116141 1 0 1 1 0 8 1 knotepl 112 2289 0 2270 1 0 1 1 0 8 0 kqueuepl 104 1992 0 1990 1 0 1 1 0 8 0 pipepl 112 5500 0 5481 17 16 1 2 0 8 0 fdescpl 488 9996 0 9983 3 0 3 3 0 8 0 filepl 152 58078 0 57989 21 16 5 6 0 8 1 lockfpl 104 3368 0 3368 6 5 1 1 0 8 1 lockfspl 48 1159 0 1159 6 5 1 1 0 8 1 sessionpl 112 62 0 53 1 0 1 1 0 8 0 pgrppl 48 161 0 152 1 0 1 1 0 8 0 ucredpl 96 11464 0 11455 1 0 1 1 0 8 0 zombiepl 144 9987 0 9985 2 1 1 1 0 8 0 processpl 896 10017 0 9985 4 0 4 4 0 8 0 procpl 632 30836 0 30794 14 9 5 5 0 8 1 srpgc 64 79 0 79 29 29 0 1 0 8 0 sosppl 128 134 0 134 30 30 0 1 0 8 0 sockpl 384 8260 0 8248 16 13 3 4 0 8 1 mcl64k 65536 771 0 0 97 60 37 97 0 8 0 mcl16k 16384 12 0 0 2 0 2 2 0 8 0 mcl12k 12288 29 0 0 2 0 2 2 0 8 0 mcl9k 9216 25 0 0 2 0 2 2 0 8 0 mcl8k 8192 17 0 0 3 1 2 3 0 8 0 mcl4k 4096 35 0 0 4 1 3 3 0 8 1 mcl2k2 2112 16 0 0 2 0 2 2 0 8 0 mcl2k 2048 164 0 0 19 2 17 19 0 8 0 mtagpl 80 58 0 0 1 0 1 1 0 8 0 mbufpl 256 977 0 0 53 0 53 53 0 8 0 bufpl 256 30944 0 23915 440 0 440 440 0 8 0 anonpl 16 883112 0 871261 244 187 57 67 0 125 3 amapchunkpl 152 61129 0 60989 53 46 7 13 0 158 0 amappl16 192 48506 0 47857 225 190 35 45 0 8 0 amappl15 184 1881 0 1881 6 6 0 1 0 8 0 amappl14 176 1041 0 1036 1 0 1 1 0 8 0 amappl13 168 1471 0 1470 1 0 1 1 0 8 0 amappl12 160 1258 0 1254 6 5 1 1 0 8 0 amappl11 152 1235 0 1227 1 0 1 1 0 8 0 amappl10 144 2043 0 2036 1 0 1 1 0 8 0 amappl9 136 1999 0 1995 1 0 1 1 0 8 0 amappl8 128 1480 0 1452 2 0 2 2 0 8 0 amappl7 120 2095 0 2085 1 0 1 1 0 8 0 amappl6 112 1113 0 1103 1 0 1 1 0 8 0 amappl5 104 1704 0 1690 1 0 1 1 0 8 0 amappl4 96 9205 0 9171 3 2 1 2 0 8 0 amappl3 88 2637 0 2626 1 0 1 1 0 8 0 amappl2 80 78889 0 78816 3 1 2 3 0 8 0 amappl1 72 227215 0 226778 25 15 10 20 0 8 0 amappl 80 31731 0 31685 2 0 2 2 0 84 0 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma64 64 259 0 259 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 17 0 17 1 1 0 1 0 8 0 aobjpl 64 138 0 9 3 0 3 3 0 8 0 uaddrrnd 24 9996 0 9981 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 9996 0 9981 1 0 1 1 0 8 0 vmmpekpl 168 75909 0 75875 2 0 2 2 0 8 0 vmmpepl 168 1215723 0 1213880 423 331 92 102 0 357 8 vmsppl 368 9995 0 9981 2 0 2 2 0 8 0 pdppl 4096 20000 0 19962 6 0 6 6 0 8 0 pvpl 32 2422402 0 2407335 536 389 147 165 0 265 20 pmappl 232 9995 0 9981 2 1 1 2 0 8 0 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 757 0 79 22 0 22 22 0 8 0