panic: ufs_rename: lost dir entry Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND * 31181 71572 0 0x1000 0x4080000 0 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff82fcb23d) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003767f5f8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80770e1b50,fffffd807313fd08,ffff80003767f7c8,fffffd807313fc30,0,ffff80003767f718) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a48c528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003767f960) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x2f4e2849870, count: 8 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> ddb> set $lines = 0 ddb> set $maxwidth = 0 ddb> show panic *cpu0: ufs_rename: lost dir entry ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff82fcb23d) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003767f5f8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80770e1b50,fffffd807313fd08,ffff80003767f7c8,fffffd807313fc30,0,ffff80003767f718) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a48c528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003767f960) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x2f4e2849870, count: -7 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80003767f380 rbx 0xfffffd807313fc30 rdx 0 rcx 0 rax 0xffff80002a48c528 r8 0x101010101010101 r9 0x8080808080808080 r10 0xe4deb4b1e4f3387a r11 0x340abd6d0401c061 r12 0 r13 0xfffffd806c1d75a0 r14 0 r15 0x1 rip 0xffffffff821e47a5 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003767f370 ss 0 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (syz-executor) tid=31181 pid=71572 tcnt=2 stat=onproc flags process=1000 proc=4080000 runpri=17, usrpri=80, slppri=17, nice=20 wchan=0x0, wmesg=, ps_single=0xffff80002a4d07c0 scnt=1 ecnt=0 forw=0xffffffffffffffff, list=0xffff80002a4d02b0,0xffff80002a48cf58 process=0xffff80002a57c8b8 user=0xffff80003767a000, vmspace=0xfffffd806bf04010 estcpu=30, cpticks=0, pctcpu=0.0, user=0, sys=0, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 61624 252660 30111 0 2 0 syz-executor 61624 354191 30111 0 3 0x4000080 wsevent_read syz-executor 43316 121782 91002 60929 2 0x10 syz-executor 43316 327276 91002 60929 3 0x4000090 fsleep syz-executor 22382 30276 66577 0 2 0 syz-executor 22382 336922 66577 0 2 0x4000000 syz-executor 26296 135227 56052 0 2 0 syz-executor 26296 75974 56052 0 2 0x4000000 syz-executor 26296 382333 56052 0 3 0x4000080 fsleep syz-executor 26296 45123 56052 0 2 0x4000000 syz-executor 69715 197996 60826 0 2 0 syz-executor 69715 407711 60826 0 3 0x4000080 fsleep syz-executor 69715 380859 60826 0 3 0x4000080 fsleep syz-executor 96313 376462 39835 0 2 0 syz-executor 96313 14301 39835 0 3 0x4000080 fsleep syz-executor 96313 264276 39835 0 3 0x4000080 kqread syz-executor 96313 416962 39835 0 3 0x4000080 fsleep syz-executor 42103 390985 25799 0 3 0x80 nanoslp syz-executor 42103 511534 25799 0 3 0x4000080 sbwait syz-executor 42103 357330 25799 0 3 0x4000080 fsleep syz-executor 42103 378408 25799 0 3 0x4000080 fsleep syz-executor 71572 423880 76128 0 3 0x3000 suspend syz-executor *71572 31181 76128 0 7 0x4081000 syz-executor 72024 283029 1 0 3 0x100083 ttyin getty 91002 383465 14528 0 3 0x82 nanoslp syz-executor 60826 123250 14528 0 3 0x82 nanoslp syz-executor 76128 512964 14528 0 3 0x82 nanoslp syz-executor 56052 122540 14528 0 3 0x82 nanoslp syz-executor 39835 296261 14528 0 3 0x82 nanoslp syz-executor 30111 353544 14528 0 3 0x82 nanoslp syz-executor 25799 144631 14528 0 3 0x82 nanoslp syz-executor 66577 150555 14528 0 3 0x82 nanoslp syz-executor 74912 280050 0 0 3 0x14200 bored sosplice 14528 479229 69637 0 3 0x82 kqread syz-executor 69637 90559 53988 0 3 0x10008a sigsusp ksh 53988 445106 57685 0 3 0x98 kqread sshd-session 57685 455029 66901 0 3 0x92 kqread sshd-session 66901 343509 1 0 3 0x88 kqread sshd 17613 168585 29746 73 3 0x1100090 kqread syslogd 29746 247214 1 0 3 0x100082 sbwait syslogd 4235 300851 1 0 3 0x100080 kqread resolvd 83504 234687 94750 77 3 0x100092 kqread dhcpleased 43457 452590 94750 77 3 0x100092 kqread dhcpleased 94750 42706 1 0 3 0x80 kqread dhcpleased 34388 343149 0 0 3 0x14200 bored smr 59440 70555 0 0 2 0x14200 zerothread 16485 5133 0 0 3 0x14200 aiodoned aiodoned 64168 258229 0 0 3 0x14200 syncer update 34330 177411 0 0 3 0x14200 cleaner cleaner 66310 430952 0 0 3 0x14200 reaper reaper 58543 152797 0 0 3 0x14200 pgdaemon pagedaemon 64222 82848 0 0 3 0x14200 bored viomb 82215 84524 0 0 3 0x40014200 acpi0 acpi0 27501 64750 0 0 3 0x14200 bored softnet3 25427 391674 0 0 3 0x14200 bored softnet2 54759 236867 0 0 3 0x14200 bored softnet1 44949 258105 0 0 3 0x14200 bored softnet0 96764 84891 0 0 3 0x14200 bored systqmp 85128 185952 0 0 3 0x14200 bored systq 56557 166218 0 0 2 0x40014200 softclock 18776 73994 0 0 3 0x40014200 idle0 1 83163 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb> show all locks No such command ddb> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10214 14200K 14581K 166960K 12382 0 pcb 17 16K 18K 166960K 215 0 rtable 203 7K 8K 166960K 1380 0 pf 34 13K 22K 166960K 126 0 ifaddr 39 7K 8K 166960K 172 0 ifgroup 50 2K 2K 166960K 193 0 sysctl 2 0K 0K 166960K 2 0 counters 30 17K 17K 166960K 69 0 ioctlops 0 0K 4K 166960K 190 0 iov 0 0K 24K 166960K 140 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1567 98K 99K 166960K 2791 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 11 0 VM map 2 1K 1K 166960K 2 0 sem 12 0K 0K 166960K 22 0 dirhash 12 2K 2K 166960K 33 0 ACPI 1690 195K 286K 166960K 12418 0 file desc 18 65K 97K 166960K 1348 0 sigio 0 0K 0K 166960K 20 0 proc 60 59K 124K 166960K 1300 0 subproc 104 6K 7K 166960K 442 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 0 0K 0K 166960K 116 0 in_multi 84 6K 7K 166960K 425 0 ether_multi 1 0K 0K 166960K 8 0 mrt 1 0K 0K 166960K 3 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 235 1049K 1049K 166960K 235 0 exec 0 0K 1K 166960K 830 0 pfkey data 0 0K 0K 166960K 6 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 238 72K 90K 166960K 12452 0 UVM aobj 10 2K 2K 166960K 12 0 pinsyscall 39 78K 96K 166960K 3054 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 44 0 NDP 11 0K 2K 166960K 119 0 temp 76 6816K 6900K 166960K 74095 0 kqueue 13 20K 34K 166960K 187 0 SYN cache 2 16K 16K 166960K 2 0 ddb> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle rtpcb 120 170 0 165 2 1 1 2 0 8 0 rtentry 112 431 0 340 4 1 3 4 0 8 0 unpcb 144 785 0 764 4 3 1 4 0 8 0 syncache 336 7 0 7 2 2 0 1 0 8 0 tcpqe 32 2 0 2 1 1 0 1 0 8 0 tcpcb 808 515 0 510 8 7 1 8 0 8 0 arp 88 77 0 59 1 0 1 1 0 8 0 ipq 40 6 0 4 1 0 1 1 0 8 0 ipqe 40 130 0 128 1 0 1 1 0 8 0 inpcb 336 1590 0 1577 17 15 2 13 0 8 0 nd6 104 109 0 87 1 0 1 1 0 8 0 pkpcb 40 9 0 9 2 1 1 1 0 8 1 kcovpl 48 34 0 26 1 0 1 1 0 8 0 ppxss 1072 7 0 7 2 1 1 1 0 8 1 pfstscr 40 4 0 4 2 1 1 1 0 8 1 pfrktable 1344 1 0 1 1 1 0 1 0 8 0 pfanchor 1288 1 0 1 1 1 0 1 0 8 0 pftag 88 2 0 2 1 1 0 1 0 8 0 pfstitem 24 2 0 0 1 0 1 1 0 8 0 pfstkey 128 9 0 7 1 0 1 1 0 8 0 pfstate 344 5 0 4 1 0 1 1 0 8 0 pfrule 1344 73 0 73 1 1 0 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 1690 0 1313 29 2 27 29 0 8 0 art_table 32 1691 0 1313 4 0 4 4 0 8 0 art_node 16 430 0 352 1 0 1 1 0 8 0 sysvmsgpl 40 46 0 6 1 0 1 1 0 8 0 semapl 112 20 0 10 1 0 1 1 0 8 0 shmpl 112 9 0 2 1 0 1 1 0 8 0 dirhash 1024 31 0 14 3 0 3 3 0 8 0 dino2pl 256 3449 0 1911 97 0 97 97 0 8 0 ffsino 240 3449 0 1911 91 0 91 91 0 8 0 nchpl 144 4882 0 3172 64 0 64 64 0 8 0 uvmvnodes 80 4445 0 0 91 0 91 91 0 8 0 vnodes 216 4445 0 0 247 0 247 247 0 8 0 namei 1024 19307 0 19305 2 1 1 1 0 8 0 kstatmem 264 100 0 78 2 0 2 2 0 8 0 scsiplug 72 2 0 2 1 1 0 1 0 8 0 scxspl 216 25549 0 25549 11 8 3 8 1 8 3 plimitpl 152 282 0 265 1 0 1 1 0 8 0 sigapl 424 1598 0 1551 9 2 7 8 0 8 0 futexpl 64 13245 0 13237 1 0 1 1 0 8 0 knotepl 120 33794 0 33747 19 9 10 10 0 8 8 kqueuepl 184 403 0 393 4 3 1 4 0 8 0 pipepl 288 316 0 289 8 5 3 7 0 8 0 fdescpl 432 1561 0 1531 5 1 4 5 0 8 0 filepl 120 10042 0 9787 18 8 10 17 0 8 0 lockfpl 104 337 0 334 1 0 1 1 0 8 0 lockfspl 48 135 0 132 1 0 1 1 0 8 0 sessionpl 144 51 0 43 1 0 1 1 0 8 0 pgrppl 48 97 0 81 1 0 1 1 0 8 0 ucredpl 104 1908 0 1896 1 0 1 1 0 8 0 zombiepl 144 1673 0 1672 3 2 1 1 0 8 0 processpl 1096 1598 0 1551 6 0 6 6 0 8 0 procpl 648 2904 0 2842 8 1 7 8 0 8 1 sosppl 168 4 0 4 1 1 0 1 0 8 0 sockpl 504 2575 0 2534 39 33 6 22 0 8 0 mcl64k 65536 30 0 30 2 1 1 1 0 8 1 mcl16k 16384 5 0 5 2 1 1 1 0 8 1 mcl12k 12288 1 0 1 1 0 1 1 0 8 1 mcl8k 8192 21 0 21 3 2 1 1 0 8 1 mcl4k 4096 10 0 10 3 2 1 1 0 8 1 mcl2k 2048 7447 0 7351 28 13 15 26 0 8 2 mtagpl 96 155 0 150 3 1 2 2 0 8 1 mbufpl 256 22236 0 21970 290 267 23 283 0 8 3 bufpl 280 8011 0 1764 447 0 447 447 0 8 0 anonpl 24 257428 0 254037 53 8 45 50 0 187 21 amapchunkpl 152 40329 0 39798 33 11 22 32 0 158 1 amappl16 200 5551 0 5520 27 17 10 15 0 8 8 amappl15 192 14 0 14 1 1 0 1 0 8 0 amappl14 184 164 0 154 1 0 1 1 0 8 0 amappl13 176 6 0 6 2 2 0 1 0 8 0 amappl12 168 2618 0 2588 3 1 2 3 0 8 0 amappl11 160 49 0 39 1 0 1 1 0 8 0 amappl10 152 7 0 7 1 1 0 1 0 8 0 amappl9 144 147 0 146 1 0 1 1 0 8 0 amappl8 136 24 0 22 1 0 1 1 0 8 0 amappl7 128 154 0 144 1 0 1 1 0 8 0 amappl6 120 424 0 422 1 0 1 1 0 8 0 amappl5 112 235 0 227 1 0 1 1 0 8 0 amappl4 104 365 0 348 1 0 1 1 0 8 0 amappl3 96 8001 0 7884 4 0 4 4 0 8 1 amappl2 88 1036 0 975 2 0 2 2 0 8 0 amappl1 80 12734 0 12212 13 1 12 13 0 8 0 amappl 88 11824 0 11640 5 0 5 5 0 92 0 dma65536 65536 1 0 1 1 1 0 1 0 8 0 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma1024 1024 1 0 0 1 0 1 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma128 128 256 0 256 3 2 1 1 0 8 1 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 8 0 8 2 2 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 72 11 0 2 1 0 1 1 0 8 0 uaddrrnd 24 1561 0 1531 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 1561 0 1531 1 0 1 1 0 8 0 vmmpekpl 168 12979 0 12923 3 0 3 3 0 8 0 vmmpepl 168 100700 0 98893 92 3 89 89 0 357 10 vmsppl 344 1560 0 1531 4 1 3 4 0 8 0 rwobjpl 24 34147 0 28819 33 0 33 33 0 8 0 pdppl 4096 3128 0 3062 145 79 66 82 0 8 0 pvpl 32 737869 0 727939 241 135 106 224 0 265 21 pmappl 216 1560 0 1531 3 1 2 3 0 8 0 extentpl 40 56 0 38 1 0 1 1 0 8 0 phpool 112 774 0 433 19 6 13 19 0 8 0 ddb> machine ddbcpu 0 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff82fcb23d) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003767f5f8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80770e1b50,fffffd807313fd08,ffff80003767f7c8,fffffd807313fc30,0,ffff80003767f718) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a48c528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003767f960) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x2f4e2849870, count: -7 ddb> machine ddbcpu 1 No such command ddb> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff82fcb23d) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003767f5f8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80770e1b50,fffffd807313fd08,ffff80003767f7c8,fffffd807313fc30,0,ffff80003767f718) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a48c528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003767f960) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x2f4e2849870, count: -7