panic: pool_do_get: shmpl free list modified: page 0xfffffd806bb8b000; item addr 0xfffffd806bb8b930; offset 0x40=0x67b84cfe Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *221907 84463 32767 0x10 0x4000000 0K syz-executor 195023 57204 32767 0x10 0 1 syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833a7592) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff839142a0,1,ffff800038cbe858) at pool_do_get+0x5da pool_get(ffffffff839142a0,1) at pool_get+0x149 shmget_allocate_segment(ffff8000fffef218,ffff800038cbeab0,122,ffff800038cbea00) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000fffef218,ffff800038cbeab0,ffff800038cbea00) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff800038cbeab0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800038cbeab0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x49833bc4520, count: 7 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 *cpu0: pool_do_get: shmpl free list modified: page 0xfffffd806bb8b000; item addr 0xfffffd806bb8b930; offset 0x40=0x67b84cfe ddb{0}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833a7592) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff839142a0,1,ffff800038cbe858) at pool_do_get+0x5da pool_get(ffffffff839142a0,1) at pool_get+0x149 shmget_allocate_segment(ffff8000fffef218,ffff800038cbeab0,122,ffff800038cbea00) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000fffef218,ffff800038cbeab0,ffff800038cbea00) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff800038cbeab0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800038cbeab0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x49833bc4520, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff800038cbe690 rbx 0xffffffff83804dc7 cpu_info_full_primary+0x2dc7 rdx 0xffff800001421880 rcx 0xffff8000fffef218 rax 0xffffffff83803ff0 cpu_info_full_primary+0x1ff0 r8 0x101010101010101 r9 0x8080808080808080 r10 0x6aa221f8d90b9164 r11 0xa9003f08316a37c0 r12 0xffffffff83804bc8 cpu_info_full_primary+0x2bc8 r13 0 r14 0 r15 0x1 rip 0xffffffff8218a0d5 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff800038cbe680 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor) tid=221907 pid=84463 tcnt=2 stat=onproc flags process=10 proc=4000000 runpri=32, usrpri=74, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff8000fffef9c8,0xffffffff839e2c88 process=0xffff8000ffff0950 user=0xffff800038cb9000, vmspace=0xfffffd806bb84748 estcpu=36, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 84463 292935 11319 32767 2 0x10 syz-executor *84463 221907 11319 32767 7 0x4000010 syz-executor 57204 195023 70361 32767 7 0x10 syz-executor 57204 162777 70361 32767 2 0x4000010 syz-executor 27370 254875 25888 32767 2 0x10 syz-executor 27370 335138 25888 32767 3 0x4000090 fsleep syz-executor 27370 325320 25888 32767 3 0x4000090 fsleep syz-executor 69947 500196 16781 32767 3 0x90 nanoslp syz-executor 69947 431298 16781 32767 3 0x4000090 sbwait syz-executor 20444 323245 78620 32767 2 0x10 syz-executor 20444 340767 78620 32767 3 0x4000090 fsleep syz-executor 21986 518133 0 0 3 0x14200 bored sosplice 11319 7200 15736 32767 3 0x90 nanoslp syz-executor 43812 162978 94576 32767 3 0x90 wait syz-executor 25888 518378 3389 32767 3 0x90 nanoslp syz-executor 16781 508395 61729 32767 3 0x90 nanoslp syz-executor 70361 440464 91408 32767 3 0x90 nanoslp syz-executor 9430 515648 89858 32767 3 0x90 piperd syz-executor 78620 295712 82322 32767 3 0x90 nanoslp syz-executor 91408 330532 90781 0 3 0x82 wait syz-executor 61729 310076 90781 0 3 0x82 wait syz-executor 15736 305958 90781 0 3 0x82 wait syz-executor 94576 445871 90781 0 3 0x82 wait syz-executor 3389 276286 90781 0 3 0x82 wait syz-executor 82322 172901 90781 0 3 0x82 wait syz-executor 89858 406466 90781 0 3 0x82 wait syz-executor 90781 487742 65937 0 2 0x10000002 syz-executor 65937 288695 6236 0 3 0x10008a sigsusp ksh 6236 32388 69702 0 3 0x98 kqread sshd-session 69702 366077 98612 0 3 0x92 kqread sshd-session 80220 391339 1 0 3 0x100083 ttyin getty 98612 240211 1 0 3 0x88 kqread sshd 51330 381942 75403 73 3 0x1100090 kqread syslogd 75403 110668 1 0 3 0x100082 sbwait syslogd 21170 214583 1 0 3 0x100080 kqread resolvd 97228 286506 14416 77 3 0x100092 kqread dhcpleased 72947 59967 14416 77 3 0x100092 kqread dhcpleased 14416 477845 1 0 3 0x80 kqread dhcpleased 41255 125937 0 0 3 0x14200 bored smr 76428 291633 0 0 2 0x14200 zerothread 64465 3161 0 0 3 0x14200 aiodoned aiodoned 29153 2567 0 0 3 0x14200 syncer update 38164 393475 0 0 3 0x14200 cleaner cleaner 75248 135979 0 0 3 0x14200 reaper reaper 85498 359140 0 0 3 0x14200 pgdaemon pagedaemon 55576 53600 0 0 3 0x14200 bored viomb 59806 59503 0 0 3 0x40014200 acpi0 acpi0 90989 321411 0 0 3 0x40014200 idle1 20985 172569 0 0 3 0x14200 bored softnet3 25907 164052 0 0 3 0x14200 bored softnet2 52874 178290 0 0 3 0x14200 bored softnet1 65722 345391 0 0 3 0x14200 bored softnet0 62110 63627 0 0 3 0x14200 bored systqmp 51215 234090 0 0 3 0x14200 bored systq 2197 135785 0 0 3 0x14200 tmoslp softclockmp 84630 412149 0 0 3 0x40014200 tmoslp softclock 72388 56385 0 0 3 0x40014200 idle0 1 24353 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks CPU 0: exclusive mutex shmpl r = 0 (0xffffffff839142b8) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1155 #1 mtx_enter_try+0x178 #2 mtx_enter+0x60 sys/kern/kern_lock.c:239 #3 pool_get+0x10b sys/kern/subr_pool.c:583 #4 shmget_allocate_segment+0x1a7 #5 sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 #6 syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] #6 syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 #7 Xsyscall+0x128 Process 84463 (syz-executor) thread 0xffff8000fffef218 (221907) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff838fec78) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1155 #1 syscall+0xae6 mi_syscall sys/sys/syscall_mi.h:176 [inline] #1 syscall+0xae6 sys/arch/amd64/amd64/trap.c:577 #2 Xsyscall+0x128 exclusive mutex shmpl r = 0 (0xffffffff839142b8) #0 witness_lock+0x5bb stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5bb sys/kern/subr_witness.c:1155 #1 mtx_enter_try+0x178 #2 mtx_enter+0x60 sys/kern/kern_lock.c:239 #3 pool_get+0x10b sys/kern/subr_pool.c:583 #4 shmget_allocate_segment+0x1a7 #5 sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 #6 syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] #6 syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 #7 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 10184 10952K 10966K 166960K 11266 0 pcb 17 12K 12K 166960K 17 0 rtable 212 6K 6K 166960K 352 0 pf 29 16K 16K 166960K 31 0 ifaddr 38 6K 7K 166960K 44 0 ifgroup 46 2K 2K 166960K 50 0 sysctl 3 1K 1K 166960K 3 0 counters 62 36K 36K 166960K 64 0 ioctlops 0 0K 2K 166960K 30 0 iov 0 0K 24K 166960K 25 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1334 84K 84K 166960K 1464 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 9 0 VM map 2 1K 1K 166960K 2 0 sem 9 0K 0K 166960K 11 0 dirhash 12 2K 2K 166960K 15 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 22 81K 121K 166960K 346 0 sigio 0 0K 0K 166960K 38 0 proc 58 79K 115K 166960K 498 0 subproc 63 3K 4K 166960K 180 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 0 0K 0K 166960K 45 0 in_multi 88 6K 7K 166960K 105 0 ether_multi 1 0K 0K 166960K 2 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 67 307K 307K 166960K 67 0 exec 0 0K 1K 166960K 376 0 fusefs mount 1 32K 32K 166960K 1 0 tdb 3 0K 0K 166960K 3 0 VM swap 8 62K 64K 166960K 10 0 UVM amap 224 65K 78K 166960K 4240 0 UVM aobj 10 2K 2K 166960K 13 0 pinsyscall 43 86K 109K 166960K 1368 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 19 0 NDP 10 0K 1K 166960K 27 0 temp 36 8639K 8705K 166960K 4771 0 kqueue 14 22K 26K 166960K 58 0 SYN cache 2 16K 16K 166960K 2 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle plcache 128 24 0 0 1 0 1 1 0 8 0 rtpcb 120 43 0 40 1 0 1 1 0 8 0 rtentry 112 113 0 14 4 0 4 4 0 8 1 unpcb 144 159 0 134 2 0 2 2 0 8 1 syncache 336 9 0 9 1 0 1 1 0 8 1 tcpqe 32 4 0 4 1 1 0 1 0 8 0 tcpcb 808 119 0 115 5 0 5 5 0 8 4 arp 120 18 0 2 1 0 1 1 0 8 0 ipq 40 2 0 1 1 0 1 1 0 8 0 ipqe 40 46 0 45 1 0 1 1 0 8 0 inpcb 376 345 0 337 8 0 8 8 0 8 7 nd6 136 26 0 5 1 0 1 1 0 8 0 kcovpl 48 20 0 13 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 470 0 62 29 0 29 29 0 8 2 art_table 32 471 0 62 4 0 4 4 0 8 0 art_node 16 112 0 22 1 0 1 1 0 8 0 sysvmsgpl 40 4 0 2 1 0 1 1 0 8 0 semupl 112 1 0 1 1 0 1 1 0 8 1 semapl 112 8 0 1 1 0 1 1 0 8 0 shmpl 112 10 0 3 1 0 1 1 0 8 0 pool(0xffffffff839142a0:shmpl): page inconsistency: page 0xfffffd806bb8b000; 27 on list, 7 missing, 35 items per page dirhash 1024 19 0 2 3 0 3 3 0 8 0 dino2pl 256 1783 0 266 95 0 95 95 0 8 0 ffsino 280 1783 0 266 109 0 109 109 0 8 0 nchpl 144 2192 0 502 63 0 63 63 0 8 0 uvmvnodes 80 1972 0 0 41 0 41 41 0 8 0 vnodes 216 1972 0 0 110 0 110 110 0 8 0 namei 1024 6846 0 6846 1 0 1 1 0 8 1 percpumem 16 46 0 1 1 0 1 1 0 8 0 kstatmem 264 22 0 2 2 0 2 2 0 8 0 scxspl 216 7437 0 7437 9 4 5 8 1 8 5 plimitpl 152 79 0 54 2 0 2 2 0 8 1 sigapl 424 599 0 545 7 0 7 7 0 8 0 futexpl 64 2521 0 2518 1 0 1 1 0 8 0 knotepl 120 567 0 0 18 0 18 18 0 8 0 kqueuepl 216 80 0 70 2 0 2 2 0 8 1 pipepl 328 164 0 137 3 0 3 3 0 8 0 fdescpl 504 580 0 546 7 1 6 6 0 8 0 filepl 152 2645 0 2434 12 0 12 12 0 8 3 lockfpl 104 56 0 54 1 0 1 1 0 8 0 lockfspl 48 25 0 23 1 0 1 1 0 8 0 sessionpl 144 39 0 24 1 0 1 1 0 8 0 pgrppl 48 63 0 40 1 0 1 1 0 8 0 ucredpl 104 255 0 237 1 0 1 1 0 8 0 zombiepl 144 547 0 545 1 0 1 1 0 8 0 processpl 1176 599 0 545 5 0 5 5 0 8 0 procpl 656 885 0 825 7 0 7 7 0 8 1 sosppl 168 4 0 4 1 0 1 1 0 8 1 sockpl 688 549 0 513 10 0 10 10 0 8 6 mcl64k 65536 4 0 0 1 0 1 1 0 8 0 mcl16k 16384 1 0 0 1 0 1 1 0 8 0 mcl8k 8192 5 0 0 1 0 1 1 0 8 0 mcl4k 4096 109 0 0 14 0 14 14 0 8 0 mcl2k 2048 20 0 0 3 0 3 3 0 8 0 mtagpl 96 3 0 0 1 0 1 1 0 8 0 mbufpl 256 380 0 0 24 0 24 24 0 8 0 bufpl 280 2627 0 124 179 0 179 179 0 8 0 anonpl 24 122778 0 119609 48 3 45 46 0 184 13 amapchunkpl 152 13194 0 12679 26 0 26 26 0 158 5 amappl16 200 2585 0 2563 14 1 13 14 0 8 7 amappl15 192 4 0 4 1 1 0 1 0 8 0 amappl14 184 114 0 104 1 0 1 1 0 8 0 amappl13 176 10 0 10 2 2 0 1 0 8 0 amappl12 168 1178 0 1144 2 0 2 2 0 8 0 amappl11 160 48 0 38 1 0 1 1 0 8 0 amappl10 152 6 0 6 1 1 0 1 0 8 0 amappl9 144 247 0 247 2 2 0 1 0 8 0 amappl8 136 22 0 20 1 0 1 1 0 8 0 amappl7 128 98 0 87 1 0 1 1 0 8 0 amappl6 120 178 0 174 1 0 1 1 0 8 0 amappl5 112 109 0 103 1 0 1 1 0 8 0 amappl4 104 292 0 276 1 0 1 1 0 8 0 amappl3 96 2325 0 2204 4 0 4 4 0 8 0 amappl2 88 659 0 601 2 0 2 2 0 8 0 amappl1 80 9519 0 8978 14 0 14 14 0 8 0 amappl 88 3866 0 3689 5 0 5 5 0 92 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 253 0 253 1 1 0 1 0 8 0 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 72 12 0 3 1 0 1 1 0 8 0 uaddrrnd 24 580 0 546 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 580 0 546 1 0 1 1 0 8 0 vmmpekpl 168 7089 0 7044 3 0 3 3 0 8 0 vmmpepl 168 43621 0 41729 101 1 100 101 0 357 10 vmsppl 456 579 0 546 7 1 6 6 0 8 1 rwobjpl 64 17834 0 15024 48 0 48 48 0 8 0 pdppl 4096 1167 0 1092 109 28 81 95 0 8 6 pvpl 32 14611 0 0 118 0 118 118 0 265 0 pmappl 248 579 0 546 4 1 3 3 0 8 0 extentpl 40 55 0 38 1 0 1 1 0 8 0 phpool 112 298 0 31 8 0 8 8 0 8 0 ddb{0}> machine ddbcpu 0 Invalid cpu 0 ddb{0}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff833a7592) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff839142a0,1,ffff800038cbe858) at pool_do_get+0x5da pool_get(ffffffff839142a0,1) at pool_get+0x149 shmget_allocate_segment(ffff8000fffef218,ffff800038cbeab0,122,ffff800038cbea00) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000fffef218,ffff800038cbeab0,ffff800038cbea00) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff800038cbeab0) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800038cbeab0) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x49833bc4520, count: -8 ddb{0}> machine ddbcpu 1 Stopped at x86_ipi_db+0x27: addq $0x8,%rsp x86_ipi_db(ffff800029aabff0) at x86_ipi_db+0x27 sys/arch/amd64/amd64/db_interface.c:394 x86_ipi_handler() at x86_ipi_handler+0xd9 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x27 end of kernel end trace frame: 0x7d8dee657230, count: 12 ddb{1}> trace x86_ipi_db(ffff800029aabff0) at x86_ipi_db+0x27 sys/arch/amd64/amd64/db_interface.c:394 x86_ipi_handler() at x86_ipi_handler+0xd9 sys/arch/amd64/amd64/ipi.c:106 Xresume_lapic_ipi() at Xresume_lapic_ipi+0x27 end of kernel end trace frame: 0x7d8dee657230, count: -3