panic: pool_do_get: shmpl free list modified: page 0xfffffd806894f000; item addr 0xfffffd806894fb60; offset 0x40=0x67a5e665 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 7651 90869 32767 0x10 0 1 syz-executor * 63677 90869 32767 0x10 0x4000000 0K syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff833a4737) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff838cfbb8,1,ffff80003c51c708) at pool_do_get+0x5da pool_get(ffffffff838cfbb8,1) at pool_get+0x149 shmget_allocate_segment(ffff8000384def58,ffff80003c51c960,1,ffff80003c51c8b0) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000384def58,ffff80003c51c960,ffff80003c51c8b0) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c51c960) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c51c960) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x14d225b2330, 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 0xfffffd806894f000; item addr 0xfffffd806894fb60; offset 0x40=0x67a5e665 ddb{0}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:437 panic(ffffffff833a4737) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff838cfbb8,1,ffff80003c51c708) at pool_do_get+0x5da pool_get(ffffffff838cfbb8,1) at pool_get+0x149 shmget_allocate_segment(ffff8000384def58,ffff80003c51c960,1,ffff80003c51c8b0) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000384def58,ffff80003c51c960,ffff80003c51c8b0) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c51c960) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c51c960) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x14d225b2330, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff80003c51c540 rbx 0xffffffff837b1dc7 cpu_info_full_primary+0x2dc7 rdx 0 rcx 0xffff8000384def58 rax 0xffffffff837b0ff0 cpu_info_full_primary+0x1ff0 r8 0x101010101010101 r9 0x8080808080808080 r10 0xb863431f4317df90 r11 0x267d8bc027032bfe r12 0xffffffff837b1bc8 cpu_info_full_primary+0x2bc8 r13 0 r14 0 r15 0x1 rip 0xffffffff82b5c385 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff80003c51c530 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor) tid=63677 pid=90869 tcnt=2 stat=onproc flags process=10 proc=4000000 runpri=32, usrpri=50, slppri=32, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff8000384df468,0xffffffff838a3d58 process=0xffff80003a4fbdd0 user=0xffff80003c517000, vmspace=0xfffffd806be5bca8 estcpu=36, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 90869 7651 68389 32767 7 0x10 syz-executor *90869 63677 68389 32767 7 0x4000010 syz-executor 96593 315105 95930 32767 2 0x10 syz-executor 96593 298868 95930 32767 3 0x4000090 fsleep syz-executor 37786 455774 1365 32767 2 0x10 syz-executor 37786 128360 1365 32767 3 0x4000090 fsleep syz-executor 29418 26842 12491 32767 3 0x90 nanoslp syz-executor 29418 187991 12491 32767 3 0x4000090 netacc syz-executor 29418 112346 12491 32767 3 0x4000090 fsleep syz-executor 56164 326758 60372 32767 3 0x90 nanoslp syz-executor 56164 80512 60372 32767 3 0x4000090 netcon syz-executor 98049 411162 20557 32767 3 0x90 nanoslp syz-executor 98049 413113 20557 32767 3 0x4000090 kqread syz-executor 98049 191309 20557 32767 3 0x4000090 kqread syz-executor 98049 252237 20557 32767 3 0x4000090 fsleep syz-executor 47106 233199 0 0 3 0x14200 bored sosplice 1365 109091 30010 32767 3 0x90 nanoslp syz-executor 60372 389006 27306 32767 3 0x90 nanoslp syz-executor 12491 265164 34221 32767 3 0x90 nanoslp syz-executor 20557 317198 69370 32767 3 0x90 nanoslp syz-executor 95930 270286 82249 32767 3 0x90 nanoslp syz-executor 76755 496649 3558 32767 3 0x90 nanoslp syz-executor 73806 442700 76891 32767 3 0x90 nanoslp syz-executor 68389 121414 85405 32767 2 0x10 syz-executor 30010 506399 52243 0 3 0x82 wait syz-executor 27306 7379 52243 0 3 0x82 wait syz-executor 82249 18194 52243 0 3 0x82 wait syz-executor 69370 498861 52243 0 3 0x82 wait syz-executor 3558 94118 52243 0 3 0x82 wait syz-executor 34221 352166 52243 0 3 0x82 wait syz-executor 76891 277412 52243 0 3 0x82 wait syz-executor 85405 515620 52243 0 3 0x82 wait syz-executor 52243 351308 30817 0 3 0x82 kqread syz-executor 30817 184119 68562 0 3 0x10008a sigsusp ksh 68562 389876 79112 0 3 0x98 kqread sshd-session 79112 250488 97212 0 3 0x92 kqread sshd-session 93041 356779 1 0 3 0x100083 ttyin getty 97212 315635 1 0 3 0x88 kqread sshd 31586 469624 14362 73 3 0x1100090 kqread syslogd 14362 151810 1 0 3 0x100082 sbwait syslogd 96724 106094 1 0 3 0x100080 kqread resolvd 63421 250582 42093 77 3 0x100092 kqread dhcpleased 7050 314993 42093 77 3 0x100092 kqread dhcpleased 42093 373507 1 0 3 0x80 kqread dhcpleased 24247 227778 0 0 3 0x14200 bored smr 44776 25486 0 0 2 0x14200 zerothread 69500 419810 0 0 3 0x14200 aiodoned aiodoned 69015 435240 0 0 3 0x14200 syncer update 77321 333116 0 0 3 0x14200 cleaner cleaner 11209 470769 0 0 3 0x14200 reaper reaper 80430 27346 0 0 3 0x14200 pgdaemon pagedaemon 51540 342684 0 0 3 0x14200 bored viomb 50454 306353 0 0 3 0x40014200 acpi0 acpi0 23570 138398 0 0 3 0x40014200 idle1 68680 106328 0 0 3 0x14200 bored softnet3 67557 283052 0 0 3 0x14200 bored softnet2 97124 394287 0 0 3 0x14200 bored softnet1 35749 69386 0 0 3 0x14200 bored softnet0 84753 53537 0 0 3 0x14200 bored systqmp 94825 280030 0 0 3 0x14200 bored systq 61713 97292 0 0 3 0x14200 tmoslp softclockmp 29888 360542 0 0 3 0x40014200 tmoslp softclock 53027 90013 0 0 3 0x40014200 idle0 1 491204 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 (0xffffffff838cfbd0) #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 90869 (syz-executor) thread 0xffff8000384def58 (63677) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff839b39d0) #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 (0xffffffff838cfbd0) #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 10189 10954K 10966K 166960K 11268 0 pcb 17 14K 16K 166960K 19 0 rtable 234 6K 6K 166960K 352 0 pf 31 16K 16K 166960K 31 0 ifaddr 42 7K 7K 166960K 44 0 ifgroup 50 2K 2K 166960K 50 0 sysctl 1 1K 1K 166960K 1 0 counters 64 36K 36K 166960K 64 0 ioctlops 0 0K 2K 166960K 30 0 iov 0 0K 12K 166960K 3 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1332 84K 84K 166960K 1352 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 3 0 VM map 2 1K 1K 166960K 2 0 sem 8 0K 0K 166960K 8 0 dirhash 12 2K 2K 166960K 12 0 ACPI 1690 195K 286K 166960K 12468 0 file desc 26 97K 129K 166960K 238 0 sigio 0 0K 0K 166960K 4 0 proc 58 79K 127K 166960K 493 0 subproc 72 4K 4K 166960K 72 0 NFS srvsock 1 0K 0K 166960K 1 0 NFS daemon 1 16K 16K 166960K 1 0 ip_moptions 2 0K 0K 166960K 29 0 in_multi 99 7K 7K 166960K 109 0 ether_multi 1 0K 0K 166960K 1 0 mrt 1 0K 0K 166960K 1 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 79 360K 360K 166960K 79 0 exec 0 0K 1K 166960K 343 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 265 74K 88K 166960K 3578 0 UVM aobj 6 2K 2K 166960K 7 0 pinsyscall 47 94K 112K 166960K 1233 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 2 0K 0K 166960K 6 0 NDP 11 0K 2K 166960K 27 0 temp 74 8640K 8704K 166960K 4046 0 kqueue 14 22K 26K 166960K 36 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 76 0 73 2 0 2 2 0 8 1 rtentry 112 111 0 1 4 0 4 4 0 8 0 unpcb 144 146 0 130 3 0 3 3 0 8 2 syncache 336 3 0 3 1 0 1 1 0 8 1 tcpcb 808 233 0 225 14 5 9 14 0 8 8 arp 120 18 0 0 1 0 1 1 0 8 0 inpcb 376 335 0 320 14 4 10 14 0 8 8 nd6 136 24 0 0 1 0 1 1 0 8 0 kcovpl 48 8 0 0 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 452 0 0 29 0 29 29 0 8 0 art_table 32 453 0 0 4 0 4 4 0 8 0 art_node 16 110 0 10 1 0 1 1 0 8 0 semapl 112 6 0 0 1 0 1 1 0 8 0 shmpl 112 4 0 1 1 0 1 1 0 8 0 pool(0xffffffff838cfbb8:shmpl): page inconsistency: page 0xfffffd806894f000; 31 on list, 3 missing, 35 items per page dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 1669 0 167 95 0 95 95 0 8 0 ffsino 280 1669 0 167 108 0 108 108 0 8 0 nchpl 144 1998 0 325 63 0 63 63 0 8 0 uvmvnodes 80 1750 0 0 36 0 36 36 0 8 0 vnodes 216 1750 0 0 98 0 98 98 0 8 0 namei 1024 5879 0 5879 1 0 1 1 0 8 1 percpumem 16 46 0 0 1 0 1 1 0 8 0 kstatmem 264 22 0 0 2 0 2 2 0 8 0 scxspl 216 6349 0 6349 3 2 1 2 1 8 1 plimitpl 152 49 0 24 2 0 2 2 0 8 1 sigapl 424 510 0 453 8 0 8 8 0 8 0 futexpl 64 1273 0 1269 1 0 1 1 0 8 0 knotepl 120 73 0 0 3 0 3 3 0 8 0 kqueuepl 216 40 0 28 1 0 1 1 0 8 0 pipepl 328 143 0 116 6 0 6 6 0 8 3 fdescpl 504 491 0 453 7 1 6 6 0 8 1 filepl 152 2128 0 1906 14 0 14 14 0 8 4 lockfpl 104 35 0 33 1 0 1 1 0 8 0 lockfspl 48 14 0 12 1 0 1 1 0 8 0 sessionpl 144 21 0 5 1 0 1 1 0 8 0 pgrppl 48 29 0 5 1 0 1 1 0 8 0 ucredpl 104 183 0 164 1 0 1 1 0 8 0 zombiepl 144 455 0 453 1 0 1 1 0 8 0 processpl 1168 510 0 453 5 0 5 5 0 8 0 procpl 648 688 0 622 7 0 7 7 0 8 0 sosppl 168 1 0 1 1 0 1 1 0 8 1 sockpl 688 558 0 523 15 4 11 15 0 8 7 mcl64k 65536 3 0 0 1 0 1 1 0 8 0 mcl16k 16384 5 0 0 1 0 1 1 0 8 0 mcl12k 12288 2 0 0 1 0 1 1 0 8 0 mcl8k 8192 2 0 0 1 0 1 1 0 8 0 mcl4k 4096 122 0 0 16 0 16 16 0 8 0 mcl2k 2048 24 0 0 3 0 3 3 0 8 0 mtagpl 96 1 0 0 1 0 1 1 0 8 0 mbufpl 256 243 0 0 16 0 16 16 0 8 0 bufpl 280 2376 0 124 161 0 161 161 0 8 0 anonpl 24 107947 0 104571 33 0 33 33 0 184 11 amapchunkpl 152 11368 0 10728 33 0 33 33 0 158 8 amappl16 200 2015 0 1990 5 1 4 5 0 8 2 amappl15 192 73 0 73 1 1 0 1 0 8 0 amappl14 184 103 0 93 1 0 1 1 0 8 0 amappl13 176 9 0 9 1 1 0 1 0 8 0 amappl12 168 1082 0 1044 2 0 2 2 0 8 0 amappl11 160 46 0 36 1 0 1 1 0 8 0 amappl10 152 9 0 9 1 1 0 1 0 8 0 amappl9 144 250 0 250 1 1 0 1 0 8 0 amappl8 136 25 0 22 1 0 1 1 0 8 0 amappl7 128 92 0 82 1 0 1 1 0 8 0 amappl6 120 172 0 169 1 0 1 1 0 8 0 amappl5 112 112 0 106 1 0 1 1 0 8 0 amappl4 104 291 0 279 1 0 1 1 0 8 0 amappl3 96 1847 0 1698 4 0 4 4 0 8 0 amappl2 88 594 0 539 2 0 2 2 0 8 0 amappl1 80 7704 0 7154 13 0 13 13 0 8 0 amappl 88 3243 0 3026 6 0 6 6 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 6 0 1 1 0 1 1 0 8 0 uaddrrnd 24 491 0 453 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 491 0 453 1 0 1 1 0 8 0 vmmpekpl 168 5649 0 5620 2 0 2 2 0 8 0 vmmpepl 168 36302 0 34231 91 0 91 91 0 357 0 vmsppl 456 490 0 453 7 1 6 6 0 8 0 rwobjpl 64 14854 0 12225 43 0 43 43 0 8 0 pdppl 4096 990 0 906 110 24 86 100 0 8 2 pvpl 32 12937 0 0 105 0 105 105 0 265 0 pmappl 248 490 0 453 4 1 3 3 0 8 0 extentpl 40 55 0 38 1 0 1 1 0 8 0 phpool 112 307 0 32 9 0 9 9 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:437 panic(ffffffff833a4737) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff838cfbb8,1,ffff80003c51c708) at pool_do_get+0x5da pool_get(ffffffff838cfbb8,1) at pool_get+0x149 shmget_allocate_segment(ffff8000384def58,ffff80003c51c960,1,ffff80003c51c8b0) at shmget_allocate_segment+0x1a7 sys_shmget(ffff8000384def58,ffff80003c51c960,ffff80003c51c8b0) at sys_shmget+0x1b2 sys/kern/sysv_shm.c:482 syscall(ffff80003c51c960) at syscall+0xb08 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff80003c51c960) at syscall+0xb08 sys/arch/amd64/amd64/trap.c:577 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x14d225b2330, 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:393 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: 0x71a78fd68d80, count: 12 ddb{1}> trace x86_ipi_db(ffff800029aabff0) at x86_ipi_db+0x27 sys/arch/amd64/amd64/db_interface.c:393 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: 0x71a78fd68d80, count: -3