witness: thread 0xffff800020b28290 exiting with the following locks held: exclusive rrwlock inode r = 0 (0xfffffd8065916f88) #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 postsig+0x4e3 sigexit sys/kern/kern_sig.c:1499 [inline] #7 postsig+0x4e3 sys/kern/kern_sig.c:1431 #8 userret+0x199 sys/kern/kern_sig.c:1887 #9 syscall+0x44a mi_syscall_return sys/sys/syscall_mi.h:115 [inline] #9 syscall+0x44a sys/arch/amd64/amd64/trap.c:577 #10 Xsyscall+0x128 panic: thread 0xffff800020b28290 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 502045 33333 73 0x100010 0 0 syslogd *367877 94477 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(ffff800020b28290) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020aff8b8) 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 0xffff800020b28290 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(ffff800020b28290) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020aff8b8) at reaper+0x14c sys/kern/kern_exit.c:423 end trace frame: 0x0, count: -4 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800020afcf30 rbx 0xffff800020afcfe0 rdx 0xffff800020aff8b8 rcx 0 rax 0 r8 0xffffffff81f21ae3 kprintf+0x173 r9 0x1 r10 0x25 r11 0x1362c572fb53f3 r12 0x3000000008 r13 0xffff800020afcf40 r14 0x100 r15 0x1 rip 0xffffffff81010db8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020afcf20 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (reaper) pid=367877 stat=onproc flags process=14000 proc=200 pri=4, usrpri=52, nice=20 forw=0xffffffffffffffff, list=0xffff800020ab18b0,0xffff800020aff650 process=0xffff800020aea708 user=0xffff800020af8000, vmspace=0xffffffff82386b98 estcpu=2, cpticks=4, pctcpu=0.63 user=0, sys=4, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 89594 369165 1 0 3 0x80 nanosleep init 86816 490846 82995 0 3 0x82 piperd syz-executor.1 17294 499185 0 0 3 0x14200 acct acct 38698 362684 0 0 3 0x14200 bored sosplice 82995 486001 89094 0 3 0x82 thrsleep syz-fuzzer 82995 37178 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 185149 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 188132 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 482873 89094 0 3 0x4000082 kqread syz-fuzzer 82995 100679 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 508709 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 411014 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 155339 89094 0 3 0x4000082 thrsleep syz-fuzzer 82995 458999 89094 0 3 0x4000082 thrsleep syz-fuzzer 89094 236848 38727 0 3 0x10008a pause ksh 38727 276106 62694 0 3 0x92 select sshd 62694 443944 1 0 3 0x80 select sshd 52513 178892 62719 74 3 0x100092 bpf pflogd 62719 455792 1 0 3 0x80 netio pflogd 33333 502045 26947 73 7 0x100010 syslogd 26947 137923 1 0 3 0x100082 netio syslogd 69779 359299 1 77 3 0x100090 poll dhclient 57889 486665 1 0 3 0x80 poll dhclient 73377 340291 0 0 3 0x14200 pgzero zerothread 1142 42770 0 0 3 0x14200 aiodoned aiodoned 85721 492640 0 0 3 0x14200 syncer update 13111 54196 0 0 3 0x14200 cleaner cleaner *94477 367877 0 0 7 0x14200 reaper 74411 111219 0 0 3 0x14200 pgdaemon pagedaemon 99494 216669 0 0 3 0x14200 bored crynlk 53869 429393 0 0 3 0x14200 bored crypto 29590 316152 0 0 3 0x40014200 acpi0 acpi0 79276 24394 0 0 3 0x40014200 idle1 54537 203539 0 0 3 0x14200 bored softnet 78825 520092 0 0 3 0x14200 bored systqmp 10816 508744 0 0 3 0x14200 bored systq 73374 214514 0 0 3 0x40014200 bored softclock 50488 460632 0 0 3 0x40014200 idle0 32098 345007 0 0 3 0x14200 bored smr 1 17599 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 33333 (syslogd) thread 0xffff800020b60c68 (502045) exclusive rrwlock inode r = 0 (0xfffffd806ec4eb38) #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 9579 6456K 7225K 78643K 15889 0 0 pcb 13 8K 8K 78643K 152 0 0 rtable 88 3K 4K 78643K 669 0 0 ifaddr 74 15K 18K 78643K 273 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 4K 78643K 1587 0 0 iov 0 0K 24K 78643K 424 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1206 76K 77K 78643K 3104 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 5K 78643K 22 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 233 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12765 0 0 file desc 3 5K 25K 78643K 2084 0 0 sigio 0 0K 0K 78643K 17 0 0 proc 47 38K 83K 78643K 755 0 0 subproc 16 1K 2K 78643K 85 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 195 0 0 in_multi 22 1K 2K 78643K 113 0 0 ether_multi 1 0K 0K 78643K 12 0 0 mrt 0 0K 0K 78643K 10 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 78 344K 344K 78643K 78 0 0 exec 0 0K 1K 78643K 401 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 103 13K 30K 78643K 7673 0 0 UVM aobj 58 3K 3K 78643K 68 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 111 0 0 NDP 18 0K 0K 78643K 77 0 0 temp 198 2751K 3392K 78643K 14556 0 0 kqueue 0 0K 0K 78643K 13 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 12 0 8 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 80 91 0 89 1 0 1 1 0 8 0 rtentry 112 80 0 47 2 0 2 2 0 8 0 unpcb 120 608 0 598 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 7604 0 7604 1 1 0 1 0 8 0 tcpcb 544 310 0 306 1 0 1 1 0 8 0 inpcb 280 936 0 929 3 2 1 2 0 8 0 nd6 48 15 0 12 1 0 1 1 0 8 0 pkpcb 40 6 0 6 3 3 0 1 0 8 0 swfcl 56 6 0 0 1 0 1 1 0 8 0 ppxss 1128 42 0 42 7 6 1 1 0 8 1 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 54 0 33 1 0 1 1 0 8 0 pfstkey 112 54 0 33 1 0 1 1 0 8 0 pfstate 328 54 0 33 2 0 2 2 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 326 0 179 13 0 13 13 0 8 0 art_table 32 327 0 179 2 0 2 2 0 8 0 art_node 16 77 0 47 1 0 1 1 0 8 0 sysvmsgpl 40 28 0 13 1 0 1 1 0 8 0 semapl 112 229 0 219 1 0 1 1 0 8 0 shmpl 112 66 0 10 2 0 2 2 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 4900 0 3487 47 0 47 47 0 8 0 ffsino 272 4900 0 3487 96 0 96 96 0 8 0 nchpl 144 7969 0 6341 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 24343 0 24343 3 2 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scsiplug 64 5 0 5 4 4 0 1 0 8 0 scxspl 192 24180 0 24180 12 11 1 6 0 8 1 plimitpl 152 196 0 189 1 0 1 1 0 8 0 sigapl 432 2278 0 2265 3 1 2 3 0 8 0 futexpl 56 24020 0 24020 2 1 1 1 0 8 1 knotepl 112 410 0 397 1 0 1 1 0 8 0 kqueuepl 104 416 0 414 1 0 1 1 0 8 0 pipepl 112 1188 0 1175 1 0 1 1 0 8 0 fdescpl 488 2279 0 2265 3 0 3 3 0 8 0 filepl 152 12616 0 12541 6 1 5 5 0 8 1 lockfpl 104 603 0 603 3 2 1 1 0 8 1 lockfspl 48 214 0 214 3 2 1 1 0 8 1 sessionpl 112 23 0 13 1 0 1 1 0 8 0 pgrppl 48 40 0 30 1 0 1 1 0 8 0 ucredpl 96 2069 0 2060 1 0 1 1 0 8 0 zombiepl 144 2265 0 2264 2 1 1 1 0 8 0 processpl 896 2296 0 2264 4 0 4 4 0 8 0 procpl 632 6711 0 6670 7 2 5 5 0 8 1 srpgc 64 8 0 8 4 3 1 1 0 8 1 sosppl 128 19 0 19 6 5 1 1 0 8 1 sockpl 384 1666 0 1647 6 3 3 3 0 8 1 mcl64k 65536 361 0 0 43 9 34 34 0 8 0 mcl16k 16384 3 0 0 1 0 1 1 0 8 0 mcl12k 12288 19 0 0 2 0 2 2 0 8 0 mcl9k 9216 6 0 0 1 0 1 1 0 8 0 mcl8k 8192 17 0 0 3 0 3 3 0 8 0 mcl4k 4096 10 0 0 2 0 2 2 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 163 0 0 19 1 18 19 0 8 0 mtagpl 80 20 0 0 1 0 1 1 0 8 0 mbufpl 256 608 0 0 31 0 31 31 0 8 0 bufpl 256 13420 0 6391 440 0 440 440 0 8 0 anonpl 16 223343 0 213968 111 45 66 67 0 125 15 amapchunkpl 152 13150 0 13020 20 9 11 11 0 158 4 amappl16 192 11870 0 11230 94 52 42 46 0 8 8 amappl15 184 8 0 8 1 0 1 1 0 8 1 amappl14 176 75 0 68 1 0 1 1 0 8 0 amappl13 168 514 0 513 3 2 1 1 0 8 0 amappl12 160 12 0 12 2 2 0 1 0 8 0 amappl11 152 785 0 770 1 0 1 1 0 8 0 amappl10 144 881 0 878 1 0 1 1 0 8 0 amappl9 136 642 0 639 1 0 1 1 0 8 0 amappl8 128 189 0 167 1 0 1 1 0 8 0 amappl7 120 849 0 841 1 0 1 1 0 8 0 amappl6 112 760 0 753 1 0 1 1 0 8 0 amappl5 104 163 0 149 1 0 1 1 0 8 0 amappl4 96 2549 0 2518 2 1 1 2 0 8 0 amappl3 88 263 0 252 1 0 1 1 0 8 0 amappl2 80 17499 0 17433 3 1 2 3 0 8 0 amappl1 72 57798 0 57384 25 15 10 20 0 8 0 amappl 80 7021 0 6980 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 67 0 10 1 0 1 1 0 8 0 uaddrrnd 24 2279 0 2264 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 2279 0 2264 1 0 1 1 0 8 0 vmmpekpl 168 19404 0 19373 2 0 2 2 0 8 0 vmmpepl 168 282048 0 280420 165 72 93 101 0 357 11 vmsppl 368 2278 0 2264 2 0 2 2 0 8 0 pdppl 4096 4566 0 4528 6 0 6 6 0 8 0 pvpl 32 618854 0 606399 249 87 162 165 0 265 36 pmappl 232 2278 0 2264 2 1 1 2 0 8 0 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 668 0 15 19 0 19 19 0 8 0