witness: thread 0xffff800020b28780 exiting with the following locks held: exclusive rrwlock inode r = 0 (0xfffffd80686ec2b8) #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 spec_write+0xec sys/kern/spec_vnops.c:312 #6 VOP_WRITE+0xce sys/kern/vfs_vops.c:268 #7 vn_write+0x1be sys/kern/vfs_vnops.c:405 #8 dofilewritev+0x1ac sys/kern/sys_generic.c:364 #9 sys_writev+0xa7 sys/kern/sys_generic.c:311 #10 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:92 [inline] #10 syscall+0x552 sys/arch/amd64/amd64/trap.c:555 #11 Xsyscall+0x128 panic: thread 0xffff800020b28780 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 103794 97577 73 0x100010 0 0 syslogd *196090 28925 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(ffff800020b28780) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020affb30) 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 0xffff800020b28780 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(ffff800020b28780) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020affb30) at reaper+0x14c sys/kern/kern_exit.c:423 end trace frame: 0x0, count: -4 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800020afd290 rbx 0xffff800020afd340 rdx 0xffff800020affb30 rcx 0 rax 0 r8 0xffffffff81ec29a3 kprintf+0x173 r9 0x1 r10 0x25 r11 0xf1c102f353a2e334 r12 0x3000000008 r13 0xffff800020afd2a0 r14 0x100 r15 0x1 rip 0xffffffff81d956a8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020afd280 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (reaper) pid=196090 stat=onproc flags process=14000 proc=200 pri=4, usrpri=52, nice=20 forw=0xffffffffffffffff, list=0xffff800020ab1b28,0xffff800020aff8c8 process=0xffff800020aeb188 user=0xffff800020af8000, vmspace=0xffffffff8239d420 estcpu=2, cpticks=8, pctcpu=0.55 user=0, sys=5, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 267 366333 75787 32767 3 0x3010 suspend syz-executor.1 267 41705 75787 32767 3 0x4081010 inode syz-executor.1 75787 198734 94116 32767 3 0x90 nanosleep syz-executor.1 94116 92924 60794 0 3 0x82 wait syz-executor.1 61657 25002 91495 32767 3 0x90 piperd syz-executor.0 91495 73379 60794 0 3 0x82 wait syz-executor.0 64509 369231 0 0 3 0x14200 bored sosplice 60794 45253 65192 0 3 0x82 thrsleep syz-fuzzer 60794 110006 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 358254 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 381274 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 164136 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 332101 65192 0 3 0x4000082 kqread syz-fuzzer 60794 211522 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 516625 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 509807 65192 0 3 0x4000082 thrsleep syz-fuzzer 60794 162576 65192 0 3 0x4000082 thrsleep syz-fuzzer 65192 400117 43122 0 3 0x10008a pause ksh 43122 25442 41825 0 3 0x92 select sshd 80680 59083 1 0 3 0x100083 ttyin getty 41825 85509 1 0 3 0x80 select sshd 97577 103794 95274 73 7 0x100010 syslogd 95274 206900 1 0 3 0x100082 netio syslogd 24032 519626 1 77 3 0x100090 poll dhclient 68908 371371 1 0 3 0x80 poll dhclient 42561 303933 0 0 3 0x14200 pgzero zerothread 36001 220124 0 0 3 0x14200 aiodoned aiodoned 77637 313050 0 0 3 0x14200 syncer update 77345 11183 0 0 3 0x14200 cleaner cleaner *28925 196090 0 0 7 0x14200 reaper 77053 31086 0 0 3 0x14200 pgdaemon pagedaemon 98987 192302 0 0 3 0x14200 bored crynlk 87480 365798 0 0 3 0x14200 bored crypto 47108 296878 0 0 3 0x40014200 acpi0 acpi0 66098 410252 0 0 3 0x40014200 idle1 97742 502910 0 0 3 0x14200 bored softnet 24560 108897 0 0 3 0x14200 bored systqmp 31132 108626 0 0 3 0x14200 bored systq 34480 165245 0 0 3 0x40014200 bored softclock 37398 219443 0 0 3 0x40014200 idle0 96448 93146 0 0 3 0x14200 bored smr 1 250888 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks Process 97577 (syslogd) thread 0xffff800020b60ee0 (103794) exclusive rrwlock inode r = 0 (0xfffffd806ebc62b8) #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 9464 6322K 6322K 78643K 13001 0 0 pcb 13 8K 8K 78643K 13 0 0 rtable 105 3K 3K 78643K 22176 0 0 ifaddr 35 17K 21K 78643K 3036 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 1189 0 0 iov 0 0K 36K 78643K 2072 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1215 76K 76K 78643K 13168 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 307 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 2819 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12765 0 0 file desc 7 21K 33K 78643K 26531 0 0 sigio 0 0K 0K 78643K 319 0 0 proc 41 38K 70K 78643K 22595 0 0 subproc 34 2K 2K 78643K 8364 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 3243 0 0 in_multi 33 2K 2K 78643K 6170 0 0 ether_multi 1 0K 0K 78643K 148 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 72 318K 318K 78643K 72 0 0 exec 0 0K 1K 78643K 8392 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 107 21K 31K 78643K 88998 0 0 UVM aobj 130 4K 4K 78643K 161 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 0K 78643K 1405 0 0 NDP 5 0K 0K 78643K 1479 0 0 temp 121 2750K 2830K 78643K 115293 0 0 kqueue 0 0K 0K 78643K 394 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 994 0 988 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 80 2099 0 2097 1 0 1 1 0 8 0 rtentry 112 5443 0 5399 2 0 2 2 0 8 0 unpcb 120 10438 0 10430 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 4188 0 4188 1 1 0 1 0 8 0 tcpcb 544 5596 0 5592 1 0 1 1 0 8 0 ipq 40 7 0 7 6 6 0 1 0 8 0 ipqe 40 15 0 15 6 6 0 1 0 8 0 inpcb 280 14196 0 14187 33 31 2 2 0 8 1 nd6 48 1476 0 1470 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 22306 0 22112 22 9 13 13 0 8 0 art_table 32 22307 0 22112 2 0 2 2 0 8 0 art_node 16 5442 0 5402 1 0 1 1 0 8 0 sysvmsgpl 40 27 0 21 1 0 1 1 0 8 0 semapl 112 2817 0 2807 1 0 1 1 0 8 0 shmpl 112 159 0 31 4 0 4 4 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 28093 0 26595 53 4 49 49 0 8 0 ffsino 272 28093 0 26595 112 11 101 101 0 8 0 nchpl 144 58594 0 56962 61 0 61 61 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 253428 0 253428 7 6 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 175894 0 175894 122 119 3 6 0 8 3 plimitpl 152 4567 0 4558 1 0 1 1 0 8 0 sigapl 432 25232 0 25217 28 26 2 3 0 8 0 futexpl 56 228774 0 228774 3 2 1 1 0 8 1 knotepl 112 15226 0 15207 1 0 1 1 0 8 0 kqueuepl 104 5712 0 5710 1 0 1 1 0 8 0 pipepl 112 16586 0 16567 33 32 1 2 0 8 0 fdescpl 488 25233 0 25217 4 1 3 3 0 8 0 filepl 152 152763 0 152658 43 38 5 7 0 8 0 lockfpl 104 4589 0 4589 29 28 1 1 0 8 1 lockfspl 48 1479 0 1479 29 28 1 1 0 8 1 sessionpl 112 507 0 497 1 0 1 1 0 8 0 pgrppl 48 770 0 760 1 0 1 1 0 8 0 ucredpl 96 42079 0 42070 1 0 1 1 0 8 0 zombiepl 144 25218 0 25217 6 5 1 1 0 8 0 processpl 896 25249 0 25217 4 0 4 4 0 8 0 procpl 632 67699 0 67656 64 59 5 5 0 8 1 srpgc 64 980 0 980 66 66 0 1 0 8 0 sosppl 128 497 0 497 100 99 1 1 0 8 1 sockpl 384 27260 0 27243 21 18 3 4 0 8 1 mcl64k 65536 49 0 0 6 3 3 3 0 8 0 mcl16k 16384 34 0 0 4 2 2 3 0 8 0 mcl12k 12288 81 0 0 2 0 2 2 0 8 0 mcl9k 9216 89 0 0 5 3 2 2 0 8 0 mcl8k 8192 55 0 0 6 4 2 3 0 8 0 mcl4k 4096 37 0 0 4 1 3 3 0 8 0 mcl2k2 2112 9 0 0 1 0 1 1 0 8 0 mcl2k 2048 218 0 0 22 9 13 22 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 1364 0 0 13 1 12 13 0 8 0 bufpl 256 55878 0 48854 440 0 440 440 0 8 0 anonpl 16 2570437 0 2563382 382 339 43 54 0 125 1 amapchunkpl 152 202600 0 202509 286 279 7 18 0 158 2 amappl16 192 108333 0 107947 598 568 30 33 0 8 8 amappl15 184 3745 0 3745 50 50 0 1 0 8 0 amappl14 176 7048 0 7039 1 0 1 1 0 8 0 amappl13 168 3808 0 3808 43 43 0 1 0 8 0 amappl12 160 2112 0 2107 2 1 1 1 0 8 0 amappl11 152 4851 0 4839 1 0 1 1 0 8 0 amappl10 144 3741 0 3730 1 0 1 1 0 8 0 amappl9 136 9772 0 9768 1 0 1 1 0 8 0 amappl8 128 7974 0 7929 2 0 2 2 0 8 0 amappl7 120 4614 0 4605 1 0 1 1 0 8 0 amappl6 112 3594 0 3581 1 0 1 1 0 8 0 amappl5 104 5538 0 5527 1 0 1 1 0 8 0 amappl4 96 25388 0 25363 1 0 1 1 0 8 0 amappl3 88 5948 0 5937 1 0 1 1 0 8 0 amappl2 80 165232 0 165162 4 2 2 3 0 8 0 amappl1 72 688996 0 688561 23 13 10 19 0 8 0 amappl 80 75628 0 75590 1 0 1 1 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 160 0 31 3 0 3 3 0 8 0 uaddrrnd 24 25233 0 25217 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 25233 0 25217 1 0 1 1 0 8 0 vmmpekpl 168 203321 0 203292 2 0 2 2 0 8 0 vmmpepl 168 3236295 0 3234685 541 457 84 95 0 357 8 vmsppl 368 25232 0 25217 2 0 2 2 0 8 0 pdppl 4096 50474 0 50434 7 1 6 6 0 8 0 pvpl 32 7214044 0 7202742 925 809 116 142 0 265 9 pmappl 232 25232 0 25217 49 48 1 2 0 8 0 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 652 0 49 18 0 18 18 0 8 0