witness: thread 0xffff800020ab0780 exiting with the following locks held: exclusive rrwlock inode r = 0 (0xfffffd806926ca30) #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_write+0x169 vn_lock sys/kern/vfs_vnops.c:561 [inline] #4 vn_write+0x169 sys/kern/vfs_vnops.c:401 #5 dofilewritev+0x1ac sys/kern/sys_generic.c:364 #6 sys_writev+0xa7 sys/kern/sys_generic.c:311 #7 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:92 [inline] #7 syscall+0x552 sys/arch/amd64/amd64/trap.c:555 #8 Xsyscall+0x128 panic: thread 0xffff800020ab0780 cannot exit while holding sleeplocks Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 370500 61464 73 0x100010 0 1 syslogd *497550 23396 0 0x14000 0x200 0 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(ffff800020ab0780) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020a5f640) 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic thread 0xffff800020ab0780 cannot exit while holding sleeplocks ddb{0}> 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(ffff800020ab0780) at witness_thread_exit+0x213 sys/kern/subr_witness.c:1364 reaper(ffff800020a5f640) at reaper+0x14c sys/kern/kern_exit.c:423 end trace frame: 0x0, count: -4 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff800020a5db50 rbx 0xffff800020a5dc00 rdx 0xffff800020a5f640 rcx 0 rax 0 r8 0xffffffff81b87073 kprintf+0x173 r9 0x1 r10 0x25 r11 0x6188583b8ca7c8f3 r12 0x3000000008 r13 0xffff800020a5db60 r14 0x100 r15 0x1 rip 0xffffffff81e265b8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020a5db40 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (reaper) pid=497550 stat=onproc flags process=14000 proc=200 pri=4, usrpri=51, nice=20 forw=0xffffffffffffffff, list=0xffff800020a11b28,0xffff800020a5eee8 process=0xffff800020a4ae08 user=0xffff800020a58000, vmspace=0xffffffff82668b10 estcpu=1, cpticks=4, pctcpu=0.55 user=0, sys=4, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 6444 198118 77867 32767 3 0x90 nanosleep syz-executor.1 77867 194516 4302 0 3 0x82 wait syz-executor.1 99299 414656 0 0 3 0x14200 bored sosplice 4302 330205 23050 0 3 0x82 thrsleep syz-fuzzer 4302 351471 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 358316 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 188171 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 224882 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 242762 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 293729 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 72950 23050 0 3 0x4000082 kqread syz-fuzzer 4302 218397 23050 0 3 0x4000082 thrsleep syz-fuzzer 4302 263353 23050 0 3 0x4000082 thrsleep syz-fuzzer 23050 118324 60079 0 3 0x10008a pause ksh 60079 76152 47874 0 3 0x92 select sshd 40777 302296 1 0 3 0x100083 ttyin getty 47874 493051 1 0 3 0x80 select sshd 61464 370500 19650 73 7 0x100010 syslogd 19650 78658 1 0 3 0x100082 netio syslogd 34503 203793 1 77 3 0x100090 poll dhclient 48749 70727 1 0 3 0x80 poll dhclient 88300 419083 0 0 3 0x14200 pgzero zerothread 94650 447148 0 0 3 0x14200 aiodoned aiodoned 98277 163875 0 0 3 0x14200 syncer update 6229 336717 0 0 3 0x14200 cleaner cleaner *23396 497550 0 0 7 0x14200 reaper 80748 292442 0 0 3 0x14200 pgdaemon pagedaemon 15754 205846 0 0 3 0x14200 bored crynlk 12053 209923 0 0 3 0x14200 bored crypto 56732 345880 0 0 3 0x40014200 acpi0 acpi0 77626 217724 0 0 3 0x40014200 idle1 39386 208048 0 0 3 0x14200 bored softnet 5520 304935 0 0 3 0x14200 bored systqmp 40132 157297 0 0 3 0x14200 bored systq 91705 155492 0 0 3 0x40014200 bored softclock 34513 521642 0 0 3 0x40014200 idle0 70900 473923 0 0 3 0x14200 bored smr 1 426573 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 61464 (syslogd) thread 0xffff800020ac09f0 (370500) exclusive rrwlock inode r = 0 (0xfffffd806eb3c3c8) #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{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9459 6319K 6322K 78643K 12166 0 0 pcb 13 8K 8K 78643K 13 0 0 rtable 83 2K 3K 78643K 14718 0 0 ifaddr 31 17K 21K 78643K 2025 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 780 0 0 iov 0 0K 28K 78643K 1475 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1215 76K 76K 78643K 9357 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 221 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 1946 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12765 0 0 file desc 5 13K 33K 78643K 18143 0 0 sigio 0 0K 0K 78643K 202 0 0 proc 41 38K 70K 78643K 15090 0 0 subproc 17 1K 2K 78643K 5525 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 2153 0 0 in_multi 22 1K 2K 78643K 4157 0 0 ether_multi 1 0K 0K 78643K 109 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 5587 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 101 13K 32K 78643K 61090 0 0 UVM aobj 130 5K 5K 78643K 143 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 1112 0 0 NDP 4 0K 0K 78643K 978 0 0 temp 97 3545K 3620K 78643K 78500 0 0 kqueue 0 0K 0K 78643K 221 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 655 0 651 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 80 1426 0 1424 1 0 1 1 0 8 0 rtentry 112 3602 0 3569 2 0 2 2 0 8 0 unpcb 120 7286 0 7278 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 sackhl 24 1 0 1 1 1 0 1 0 8 0 tcpqe 32 3600 0 3600 1 1 0 1 0 8 0 tcpcb 544 4254 0 4250 1 0 1 1 0 8 0 ipq 40 21 0 21 10 10 0 1 0 8 0 ipqe 40 56 0 56 10 10 0 1 0 8 0 inpcb 280 9986 0 9979 14 13 1 2 0 8 0 nd6 48 976 0 973 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 14808 0 14658 26 13 13 13 0 8 1 art_table 32 14809 0 14658 2 0 2 2 0 8 0 art_node 16 3601 0 3571 1 0 1 1 0 8 0 sysvmsgpl 40 18 0 11 2 1 1 1 0 8 0 semupl 112 3 0 3 1 1 0 1 0 8 0 semapl 112 1939 0 1929 1 0 1 1 0 8 0 shmpl 112 141 0 13 4 0 4 4 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 19985 0 18517 52 4 48 48 0 8 0 ffsino 272 19985 0 18517 101 2 99 99 0 8 0 nchpl 144 41201 0 39577 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 176062 0 176062 7 6 1 1 0 8 1 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 124001 0 124001 72 71 1 7 0 8 1 plimitpl 152 3065 0 3058 1 0 1 1 0 8 0 sigapl 432 17345 0 17332 21 19 2 3 0 8 0 futexpl 56 166342 0 166342 6 5 1 1 0 8 1 knotepl 112 10297 0 10284 2 1 1 2 0 8 0 kqueuepl 104 4005 0 4003 1 0 1 1 0 8 0 pipepl 112 10940 0 10927 19 18 1 2 0 8 0 fdescpl 488 17346 0 17332 4 1 3 3 0 8 1 filepl 152 106974 0 106897 34 29 5 7 0 8 1 lockfpl 104 3540 0 3540 19 18 1 1 0 8 1 lockfspl 48 1117 0 1117 19 18 1 1 0 8 1 sessionpl 112 340 0 331 1 0 1 1 0 8 0 pgrppl 48 521 0 512 1 0 1 1 0 8 0 ucredpl 96 30088 0 30080 1 0 1 1 0 8 0 zombiepl 144 17333 0 17332 4 3 1 1 0 8 0 processpl 896 17362 0 17332 4 0 4 4 0 8 0 procpl 632 46548 0 46508 38 33 5 5 0 8 1 srpgc 64 648 0 648 51 50 1 1 0 8 1 sosppl 128 287 0 287 63 63 0 1 0 8 0 sockpl 384 19051 0 19034 19 16 3 4 0 8 1 mcl64k 65536 32 0 0 4 1 3 3 0 8 0 mcl16k 16384 37 0 0 5 3 2 3 0 8 0 mcl12k 12288 73 0 0 3 1 2 2 0 8 0 mcl9k 9216 56 0 0 3 1 2 2 0 8 0 mcl8k 8192 25 0 0 4 1 3 3 0 8 0 mcl4k 4096 41 0 0 4 1 3 3 0 8 0 mcl2k2 2112 13 0 0 1 0 1 1 0 8 0 mcl2k 2048 184 0 0 17 4 13 17 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 1093 0 0 14 2 12 12 0 8 0 bufpl 256 38433 0 31419 439 0 439 439 0 8 0 anonpl 16 1974570 0 1968579 231 187 44 47 0 124 0 amapchunkpl 152 141908 0 141818 221 216 5 18 0 158 0 amappl16 192 81886 0 81497 465 435 30 33 0 8 8 amappl15 184 3316 0 3313 28 27 1 1 0 8 0 amappl14 176 4599 0 4588 1 0 1 1 0 8 0 amappl13 168 3090 0 3090 37 36 1 1 0 8 1 amappl12 160 1777 0 1774 1 0 1 1 0 8 0 amappl11 152 2359 0 2348 1 0 1 1 0 8 0 amappl10 144 2390 0 2386 1 0 1 1 0 8 0 amappl9 136 6622 0 6620 1 0 1 1 0 8 0 amappl8 128 5190 0 5146 2 0 2 2 0 8 0 amappl7 120 2843 0 2833 1 0 1 1 0 8 0 amappl6 112 2003 0 1991 1 0 1 1 0 8 0 amappl5 104 4181 0 4171 1 0 1 1 0 8 0 amappl4 96 16614 0 16584 2 1 1 2 0 8 0 amappl3 88 4805 0 4787 1 0 1 1 0 8 0 amappl2 80 115227 0 115162 3 1 2 3 0 8 0 amappl1 72 476620 0 476201 23 13 10 19 0 8 0 amappl 80 52020 0 51985 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 142 0 13 4 1 3 3 0 8 0 uaddrrnd 24 17346 0 17332 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 17346 0 17332 1 0 1 1 0 8 0 vmmpekpl 168 146043 0 146017 2 0 2 2 0 8 0 vmmpepl 168 2235056 0 2233562 462 374 88 97 0 357 11 vmsppl 368 17345 0 17332 2 0 2 2 0 8 0 pdppl 4096 34699 0 34664 8 2 6 6 0 8 1 pvpl 32 5237567 0 5228458 761 644 117 127 0 265 13 pmappl 232 17345 0 17332 33 31 2 2 0 8 1 extentpl 40 41 0 26 1 0 1 1 0 8 0 phpool 112 638 0 37 18 0 18 18 0 8 0