panic: ufs_rename: lost dir entry Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *376931 56988 0 0x1000 0x4080000 0 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff82fc99a5) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003741d1a8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80631ebcc0,fffffd80631eb2a0,ffff80003741d378,fffffd80631eb018,0,ffff80003741d2c8) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a4a2528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003741d510) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x6ef318b3020, 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(ffffffff82fc99a5) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003741d1a8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80631ebcc0,fffffd80631eb2a0,ffff80003741d378,fffffd80631eb018,0,ffff80003741d2c8) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a4a2528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003741d510) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x6ef318b3020, count: -7 ddb> show registers rdi 0 rsi 0x1 rbp 0xffff80003741cf30 rbx 0xfffffd80631eb018 rdx 0 rcx 0 rax 0xffff80002a4a2528 r8 0x101010101010101 r9 0x8080808080808080 r10 0x8bb94f1edd751e3d r11 0xb584d17eca43dbd7 r12 0 r13 0xfffffd807b3be3d0 r14 0 r15 0x1 rip 0xffffffff812e9875 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003741cf20 ss 0 db_enter+0x25: addq $0x8,%rsp ddb> show proc PROC (syz-executor) tid=376931 pid=56988 tcnt=2 stat=onproc flags process=1000 proc=4080000 runpri=17, usrpri=84, slppri=17, nice=20 wchan=0x0, wmesg=, ps_single=0xffff80003761d970 scnt=1 ecnt=0 forw=0xffffffffffffffff, list=0xffff80002a4a3bf0,0xffff80002a4a27c0 process=0xffff8000327f66a0 user=0xffff800037418000, vmspace=0xfffffd806bf17c28 estcpu=34, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 82549 122606 10834 0 3 0 futex syz-executor 82549 67385 10834 0 3 0x4000000 futex syz-executor 78230 430117 51460 0 2 0 syz-executor 78230 182624 51460 0 3 0x4000000 futex syz-executor 78230 507152 51460 0 3 0x4000080 fsleep syz-executor 78230 489781 51460 0 3 0x4000080 fsleep syz-executor 3054 274349 95551 0 3 0 futex syz-executor 3054 511570 95551 0 2 0x4000000 syz-executor 3054 275147 95551 0 2 0x4000000 syz-executor 47827 8444 51356 0 2 0 syz-executor 47827 214774 51356 0 3 0x4000000 futex syz-executor 56988 462899 22214 0 3 0x3000 suspend syz-executor *56988 376931 22214 0 7 0x4081000 syz-executor 26332 67630 93606 0 3 0 futex syz-executor 26332 119017 93606 0 3 0x4000000 futex syz-executor 26332 57648 93606 0 3 0x4000080 fsleep syz-executor 26332 504819 93606 0 3 0x4000080 fsleep syz-executor 70043 523593 53442 0 2 0x10 syz-executor 70043 174928 53442 0 3 0x4000010 futex syz-executor 70043 377373 53442 0 3 0x4000090 fsleep syz-executor 11960 31988 81955 0 2 0x2 syz-executor 51460 281252 81955 0 3 0x82 nanoslp syz-executor 93606 327256 81955 0 3 0x82 nanoslp syz-executor 95551 467453 81955 0 3 0x82 nanoslp syz-executor 73737 349086 1 0 3 0x100083 ttyin getty 53442 195635 81955 0 3 0x82 nanoslp syz-executor 51356 229378 81955 0 3 0x82 nanoslp syz-executor 22214 410251 81955 0 3 0x82 nanoslp syz-executor 10834 497392 81955 0 3 0x82 nanoslp syz-executor 53335 479412 0 0 3 0x14280 nfsidl nfsio 16028 457577 0 0 3 0x14280 nfsidl nfsio 68729 103086 0 0 3 0x14280 nfsidl nfsio 30445 427454 0 0 3 0x14280 nfsidl nfsio 16253 196361 0 0 3 0x14280 nfsidl nfsio 78437 119833 0 0 3 0x14280 nfsidl nfsio 59719 54707 0 0 3 0x14280 nfsidl nfsio 31262 21027 0 0 3 0x14280 nfsidl nfsio 97075 222603 0 0 3 0x14280 nfsidl nfsio 29564 148641 0 0 3 0x14280 nfsidl nfsio 94120 362083 0 0 3 0x14280 nfsidl nfsio 89364 53414 0 0 3 0x14280 nfsidl nfsio 46835 413560 0 0 3 0x14280 nfsidl nfsio 15163 316078 0 0 3 0x14280 nfsidl nfsio 49224 339657 0 0 3 0x14280 nfsidl nfsio 74752 424369 0 0 3 0x14280 nfsidl nfsio 92257 304635 0 0 3 0x14280 nfsidl nfsio 67931 105093 0 0 3 0x14280 nfsidl nfsio 81162 231251 0 0 3 0x14280 nfsidl nfsio 72055 34911 0 0 3 0x14280 nfsidl nfsio 26396 399274 0 0 3 0x14200 bored sosplice 81955 331213 38815 0 3 0x82 kqread syz-executor 38815 388625 24314 0 3 0x10008a sigsusp ksh 24314 95600 12884 0 3 0x98 kqread sshd-session 12884 107871 87736 0 3 0x92 kqread sshd-session 87736 498643 1 0 3 0x88 kqread sshd 12523 19390 4355 73 3 0x1100090 kqread syslogd 4355 376925 1 0 3 0x100082 sbwait syslogd 36365 61059 1 0 3 0x100080 kqread resolvd 79116 75532 43013 77 3 0x100092 kqread dhcpleased 565 91974 43013 77 3 0x100092 kqread dhcpleased 43013 391165 1 0 3 0x80 kqread dhcpleased 54161 277897 0 0 3 0x14200 bored smr 61389 368554 0 0 2 0x14200 zerothread 8067 227006 0 0 3 0x14200 aiodoned aiodoned 46356 349632 0 0 3 0x14200 syncer update 29332 197165 0 0 3 0x14200 cleaner cleaner 72236 381462 0 0 3 0x14200 reaper reaper 85052 448458 0 0 3 0x14200 pgdaemon pagedaemon 4232 172457 0 0 3 0x14200 bored viomb 62453 515865 0 0 3 0x40014200 acpi0 acpi0 58606 182910 0 0 3 0x14200 bored softnet3 48116 177882 0 0 3 0x14200 bored softnet2 49396 282543 0 0 3 0x14200 bored softnet1 92224 83623 0 0 3 0x14200 bored softnet0 50882 39990 0 0 3 0x14200 bored systqmp 68752 26678 0 0 3 0x14200 bored systq 87097 69617 0 0 3 0x40014200 tmoslp softclock 25087 47446 0 0 3 0x40014200 idle0 1 328605 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 10218 14148K 14694K 166960K 13524 0 pcb 19 15K 16K 166960K 376 0 rtable 210 7K 8K 166960K 3817 0 pf 35 13K 22K 166960K 335 0 ifaddr 45 9K 10K 166960K 517 0 ifgroup 58 2K 2K 166960K 546 0 sysctl 3 0K 0K 166960K 3 0 counters 32 17K 18K 166960K 158 0 ioctlops 0 0K 4K 166960K 244 0 iov 0 0K 20K 166960K 167 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1519 95K 96K 166960K 3996 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 9K 166960K 22 0 VM map 2 1K 1K 166960K 2 0 sem 12 0K 0K 166960K 240 0 dirhash 15 2K 3K 166960K 45 0 ACPI 1690 195K 286K 166960K 12418 0 file desc 18 65K 97K 166960K 3166 0 sigio 0 0K 0K 166960K 101 0 proc 62 67K 124K 166960K 3628 0 subproc 104 6K 6K 166960K 1509 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 1 0K 0K 166960K 183 0 in_multi 92 6K 7K 166960K 1341 0 ether_multi 1 0K 0K 166960K 10 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 247 1102K 1102K 166960K 247 0 exec 0 0K 1K 166960K 2111 0 pfkey data 0 0K 0K 166960K 38 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 228 72K 90K 166960K 24751 0 UVM aobj 36 4K 4K 166960K 40 0 pinsyscall 39 78K 96K 166960K 6991 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 158 0 NDP 13 0K 2K 166960K 373 0 temp 75 6816K 6944K 166960K 122367 0 kqueue 13 20K 28K 166960K 262 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 384 0 381 2 1 1 2 0 8 0 rtentry 112 1348 0 1254 5 1 4 4 0 8 0 unpcb 144 1503 0 1486 9 5 4 6 0 8 3 syncache 336 4 0 4 1 1 0 1 0 8 0 tcpcb 808 565 0 559 11 3 8 8 0 8 7 arp 88 240 0 222 1 0 1 1 0 8 0 ipq 40 9 0 6 1 0 1 1 0 8 0 ipqe 40 56 0 53 1 0 1 1 0 8 0 inpcb 336 2462 0 2448 24 15 9 13 0 8 7 nd6 104 365 0 344 1 0 1 1 0 8 0 pkpcb 40 13 0 13 2 1 1 1 0 8 1 kcovpl 48 116 0 108 1 0 1 1 0 8 0 ppxss 1072 11 0 11 2 1 1 1 0 8 1 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 5428 0 4997 31 1 30 30 0 8 0 art_table 32 5429 0 4997 4 0 4 4 0 8 0 art_node 16 1346 0 1266 1 0 1 1 0 8 0 sysvmsgpl 40 4 0 3 1 0 1 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 235 0 225 1 0 1 1 0 8 0 shmpl 112 37 0 4 1 0 1 1 0 8 0 dirhash 1024 39 0 20 3 0 3 3 0 8 0 dino2pl 256 4360 0 2648 108 0 108 108 0 8 0 ffsino 240 4360 0 2648 101 0 101 101 0 8 0 nchpl 144 6741 0 6078 65 32 33 65 0 8 6 uvmvnodes 80 6631 0 0 136 0 136 136 0 8 0 vnodes 216 6631 0 0 369 0 369 369 0 8 0 namei 1024 33444 0 33442 3 1 2 2 0 8 1 kstatmem 264 278 0 252 3 0 3 3 0 8 0 scsiplug 72 6 0 6 2 1 1 1 0 8 1 scxspl 216 60152 0 60152 10 7 3 8 1 8 3 plimitpl 152 438 0 422 1 0 1 1 0 8 0 sigapl 424 3252 0 3185 8 0 8 8 0 8 0 futexpl 64 21927 0 21921 1 0 1 1 0 8 0 knotepl 120 53309 0 53262 25 15 10 17 0 8 8 kqueuepl 184 410 0 400 3 2 1 3 0 8 0 pipepl 288 691 0 663 7 0 7 7 0 8 4 fdescpl 432 3212 0 3182 5 1 4 5 0 8 0 filepl 120 16186 0 15930 18 4 14 14 0 8 4 lockfpl 104 605 0 601 1 0 1 1 0 8 0 lockfspl 48 220 0 216 1 0 1 1 0 8 0 sessionpl 144 130 0 122 1 0 1 1 0 8 0 pgrppl 48 256 0 240 1 0 1 1 0 8 0 ucredpl 104 2224 0 2211 1 0 1 1 0 8 0 zombiepl 144 3895 0 3894 2 1 1 1 0 8 0 processpl 1096 3252 0 3185 6 0 6 6 0 8 1 procpl 648 5790 0 5710 9 0 9 9 0 8 2 sosppl 168 5 0 5 2 1 1 1 0 8 1 sockpl 504 4388 0 4354 61 49 12 29 0 8 7 mcl64k 65536 10 0 10 2 1 1 1 0 8 1 mcl16k 16384 3 0 3 1 0 1 1 0 8 1 mcl9k 9216 2 0 2 2 1 1 1 0 8 1 mcl8k 8192 85 0 85 2 1 1 1 0 8 1 mcl4k 4096 7 0 7 2 1 1 1 0 8 1 mcl2k2 2112 2 0 2 1 1 0 1 0 8 0 mcl2k 2048 10993 0 10901 28 12 16 25 0 8 3 mtagpl 96 170 0 100 4 2 2 2 0 8 0 mbufpl 256 36712 0 36427 312 288 24 293 0 8 4 bufpl 280 10412 0 3295 509 0 509 509 0 8 0 anonpl 24 445446 0 442155 100 26 74 74 0 187 43 amapchunkpl 152 79741 0 79242 52 21 31 41 0 158 11 amappl16 200 7339 0 7314 40 30 10 14 0 8 8 amappl15 192 10 0 10 1 1 0 1 0 8 0 amappl14 184 331 0 321 1 0 1 1 0 8 0 amappl13 176 11 0 11 1 1 0 1 0 8 0 amappl12 168 5540 0 5511 2 0 2 2 0 8 0 amappl11 160 48 0 38 1 0 1 1 0 8 0 amappl10 152 12 0 12 1 1 0 1 0 8 0 amappl9 144 125 0 125 1 1 0 1 0 8 0 amappl8 136 22 0 20 1 0 1 1 0 8 0 amappl7 128 378 0 367 1 0 1 1 0 8 0 amappl6 120 1246 0 1243 1 0 1 1 0 8 0 amappl5 112 559 0 550 1 0 1 1 0 8 0 amappl4 104 605 0 591 1 0 1 1 0 8 0 amappl3 96 15100 0 14989 5 1 4 4 0 8 1 amappl2 88 2195 0 2134 2 0 2 2 0 8 0 amappl1 80 22755 0 22253 14 2 12 13 0 8 0 amappl 88 23496 0 23321 5 0 5 5 0 92 0 dma16384 16384 33 0 33 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 254 0 254 1 1 0 1 0 8 0 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 8 0 8 1 1 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 72 39 0 4 1 0 1 1 0 8 0 uaddrrnd 24 3212 0 3182 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 3212 0 3182 1 0 1 1 0 8 0 vmmpekpl 168 26179 0 26124 3 0 3 3 0 8 0 vmmpepl 168 199498 0 197752 87 2 85 85 0 357 6 vmsppl 344 3211 0 3182 4 1 3 4 0 8 0 rwobjpl 24 62144 0 54641 46 0 46 46 0 8 0 pdppl 4096 6430 0 6364 296 228 68 82 0 8 2 pvpl 32 1470420 0 1460575 364 137 227 227 0 265 131 pmappl 216 3211 0 3182 3 1 2 3 0 8 0 extentpl 40 56 0 38 1 0 1 1 0 8 0 phpool 112 998 0 604 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(ffffffff82fc99a5) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003741d1a8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80631ebcc0,fffffd80631eb2a0,ffff80003741d378,fffffd80631eb018,0,ffff80003741d2c8) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a4a2528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003741d510) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x6ef318b3020, 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(ffffffff82fc99a5) at panic+0x1cf sys/kern/subr_prf.c:198 ufs_rename(ffff80003741d1a8) at ufs_rename+0x18b2 VOP_RENAME(fffffd80631ebcc0,fffffd80631eb2a0,ffff80003741d378,fffffd80631eb018,0,ffff80003741d2c8) at VOP_RENAME+0x13c sys/kern/vfs_vops.c:376 dorenameat(ffff80002a4a2528,ffffff9c,20000540,ffffff9c,200005c0) at dorenameat+0x3f8 sys/kern/vfs_syscalls.c:3020 syscall(ffff80003741d510) at syscall+0x97e sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x6ef318b3020, count: -7