panic: pool_do_get: shmpl free list modified: page 0xfffffd806dc7a000; item addr 0xfffffd806dc7a5b0; offset 0x40=0x6a0134c4 Stopped at db_enter+0x25: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 26134 45645 32767 0x10 0 0 syz-executor * 25023 45645 32767 0x10 0x4000000 1K syz-executor db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8344c04b) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a2c018,2,ffff800033bb6338) at pool_do_get+0x5df pool_get(ffffffff83a2c018,2) at pool_get+0x162 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80003c3f2030,ffff800033bb6590,14c,ffff800033bb64e0) at shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 sys_shmget(ffff80003c3f2030,ffff800033bb6590,ffff800033bb64e0) at sys_shmget+0x195 sys/kern/sysv_shm.c:484 syscall(ffff800033bb6590) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800033bb6590) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x97d23c284b0, 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{1}> ddb{1}> set $lines = 0 ddb{1}> set $maxwidth = 0 ddb{1}> show panic *cpu1: pool_do_get: shmpl free list modified: page 0xfffffd806dc7a000; item addr 0xfffffd806dc7a5b0; offset 0x40=0x6a0134c4 ddb{1}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8344c04b) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a2c018,2,ffff800033bb6338) at pool_do_get+0x5df pool_get(ffffffff83a2c018,2) at pool_get+0x162 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80003c3f2030,ffff800033bb6590,14c,ffff800033bb64e0) at shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 sys_shmget(ffff80003c3f2030,ffff800033bb6590,ffff800033bb64e0) at sys_shmget+0x195 sys/kern/sysv_shm.c:484 syscall(ffff800033bb6590) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800033bb6590) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x97d23c284b0, count: -8 ddb{1}> show registers rdi 0 rsi 0x1 rbp 0xffff800033bb6160 rbx 0xffff8000299aee07 rdx 0xffff80000159d880 rcx 0xffff80003c3f2030 rax 0xffff8000299adff0 r8 0x101010101010101 r9 0x8080808080808080 r10 0xca0aef75897b47c1 r11 0xf97a76d1081b9deb r12 0xffff8000299aec08 r13 0 r14 0 r15 0x1 rip 0xffffffff81e61b65 db_enter+0x25 cs 0x8 rflags 0x246 rsp 0xffff800033bb6150 ss 0x10 db_enter+0x25: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor) tid=25023 pid=45645 tcnt=3 stat=onproc flags process=10 proc=4000000 runpri=86, usrpri=86, slppri=17, nice=20 wchan=0x0, wmesg=, ps_single=0x0 scnt=0 ecnt=0 forw=0xffffffffffffffff, list=0xffff80003c3f34f0,0xffffffff8396deb8 process=0xffff80003c3df510 user=0xffff800033bb1000, vmspace=0xfffffd806c76a030 estcpu=36, cpticks=1, pctcpu=0.0, user=0, sys=1, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 45645 26134 4389 32767 7 0x10 syz-executor 45645 313814 4389 32767 3 0x4000090 netacc syz-executor *45645 25023 4389 32767 7 0x4000010 syz-executor 56170 351788 83500 32767 3 0x90 nanoslp syz-executor 56170 44563 83500 32767 3 0x4000090 fsleep syz-executor 56170 302179 83500 32767 3 0x4000090 sbwait syz-executor 56170 516393 83500 32767 3 0x4000090 fsleep syz-executor 48443 52195 63486 32767 3 0x90 nanoslp syz-executor 48443 39726 63486 32767 3 0x4000090 kqpoll syz-executor 89026 274792 13780 32767 3 0x90 nanoslp syz-executor 89026 166052 13780 32767 3 0x4000090 lockf syz-executor 89026 316694 13780 32767 3 0x4000090 fsleep syz-executor 83453 418377 21914 32767 3 0x90 nanoslp syz-executor 83453 87002 21914 32767 3 0x4000090 lockf syz-executor 83453 332047 21914 32767 3 0x4000090 lockf syz-executor 83453 394983 21914 32767 3 0x4000090 fsleep syz-executor 59107 318700 73854 32767 3 0x90 nanoslp syz-executor 59107 57614 73854 32767 3 0x4000090 sbwait syz-executor 59107 511537 73854 32767 3 0x4000090 fsleep syz-executor 63486 92202 3366 32767 3 0x90 nanoslp syz-executor 13780 130182 79577 32767 3 0x90 nanoslp syz-executor 91648 337268 79745 32767 3 0x90 wait syz-executor 83500 250784 91176 32767 3 0x90 nanoslp syz-executor 5620 126633 89004 32767 3 0x90 nanoslp syz-executor 4389 486103 6815 32767 3 0x90 nanoslp syz-executor 73854 217367 61158 32767 3 0x90 nanoslp syz-executor 21914 324827 99936 32767 3 0x90 nanoslp syz-executor 79577 510725 8184 0 3 0x82 wait syz-executor 3366 39022 8184 0 3 0x82 wait syz-executor 79745 94078 8184 0 3 0x82 wait syz-executor 91176 139301 8184 0 3 0x82 wait syz-executor 89004 299349 8184 0 3 0x82 wait syz-executor 61158 340075 8184 0 3 0x82 wait syz-executor 6815 63456 8184 0 3 0x82 wait syz-executor 99936 61650 8184 0 3 0x82 wait syz-executor 8184 324472 6453 0 3 0x82 kqread syz-executor 6453 336745 92642 0 3 0x10008a sigsusp ksh 92642 312257 26996 0 3 0x98 kqread sshd-session 26996 153064 40786 0 3 0x92 kqread sshd-session 76997 13337 1 0 3 0x100083 ttyin getty 40786 389569 1 0 3 0x88 kqread sshd 43532 303722 79688 73 3 0x1100090 kqread syslogd 79688 408550 1 0 3 0x100082 sbwait syslogd 38944 300407 1 0 3 0x100080 kqread resolvd 40963 243609 74695 77 3 0x100092 kqread dhcpleased 94840 375577 74695 77 3 0x100092 kqread dhcpleased 74695 387720 1 0 3 0x80 kqread dhcpleased 8996 417695 0 0 3 0x14200 bored smr 68259 504897 0 0 3 0x14200 pgzero zerothread 84076 227297 0 0 3 0x14200 aiodoned aiodoned 16078 89606 0 0 3 0x14200 syncer update 39146 82128 0 0 3 0x14200 cleaner cleaner 53827 2377 0 0 3 0x14200 reaper reaper 29539 89250 0 0 3 0x14200 pgdaemon pagedaemon 31033 467066 0 0 3 0x14200 bored viomb 77848 388215 0 0 3 0x40014200 acpi0 acpi0 606 201644 0 0 3 0x40014200 idle1 15544 320756 0 0 3 0x14200 bored softnet1 72454 452042 0 0 3 0x14200 bored softnet0 91586 363707 0 0 3 0x14200 bored systqmp 18356 342252 0 0 3 0x14200 bored systq 93303 496548 0 0 3 0x14200 tmoslp softclockmp 29037 9250 0 0 3 0x40014200 tmoslp softclock 83785 503225 0 0 3 0x40014200 idle0 1 425815 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{1}> show all locks CPU 1: exclusive mutex shmpl r = 0 (0xffffffff83a2c030) #0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160 #1 mtx_enter+0x4b4 sys/kern/kern_lock.c:487 #2 pool_get+0x124 sys/kern/subr_pool.c:585 #3 shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 #4 sys_shmget+0x195 sys/kern/sysv_shm.c:484 #5 syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] #5 syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 #6 Xsyscall+0x128 Process 45645 (syz-executor) thread 0xffff80003c3f2030 (25023) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff83a24140) #0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160 #1 syscall+0xaf4 mi_syscall sys/sys/syscall_mi.h:175 [inline] #1 syscall+0xaf4 sys/arch/amd64/amd64/trap.c:783 #2 Xsyscall+0x128 exclusive mutex shmpl r = 0 (0xffffffff83a2c030) #0 witness_lock+0x5f1 stacktrace_save sys/sys/stacktrace.h:37 [inline] #0 witness_lock+0x5f1 sys/kern/subr_witness.c:1160 #1 mtx_enter+0x4b4 sys/kern/kern_lock.c:487 #2 pool_get+0x124 sys/kern/subr_pool.c:585 #3 shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 #4 sys_shmget+0x195 sys/kern/sysv_shm.c:484 #5 syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] #5 syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 #6 Xsyscall+0x128 ddb{1}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 11061 12019K 12034K 166960K 12152 0 pcb 17 12K 12K 166960K 17 0 rtable 239 6K 7K 166960K 362 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 9K 166960K 5 0 counters 70 37K 37K 166960K 70 0 ioctlops 0 0K 4K 166960K 37 0 iov 0 0K 16K 166960K 13 0 mount 1 1K 1K 166960K 1 0 log 0 0K 0K 166960K 4 0 vnodes 1287 81K 81K 166960K 1460 0 UFS quota 1 32K 32K 166960K 1 0 UFS mount 5 36K 36K 166960K 5 0 shm 2 1K 5K 166960K 12 0 VM map 2 1K 1K 166960K 2 0 sem 12 1K 1K 166960K 20 0 dirhash 12 2K 2K 166960K 12 0 ACPI 1692 195K 286K 166960K 12470 0 file desc 26 97K 121K 166960K 409 0 sigio 1 0K 0K 166960K 11 0 proc 58 99K 180K 166960K 512 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 0 0K 0K 166960K 73 0 in_multi 99 7K 7K 166960K 114 0 ether_multi 1 0K 0K 166960K 5 0 mrt 2 0K 0K 166960K 12 0 ISOFS mount 1 32K 32K 166960K 1 0 MSDOSFS mount 1 16K 16K 166960K 1 0 ttys 109 493K 493K 166960K 109 0 exec 0 0K 1K 166960K 373 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 271 168K 187K 166960K 5297 0 UVM aobj 14 2K 2K 166960K 16 0 pinsyscall 47 94K 109K 166960K 1470 0 memdesc 1 4K 4K 166960K 1 0 crypto data 1 1K 1K 166960K 1 0 ip6_options 0 0K 0K 166960K 18 0 NDP 11 0K 2K 166960K 27 0 temp 46 9072K 9136K 166960K 4947 0 kqueue 13 20K 29K 166960K 75 0 SYN cache 2 16K 16K 166960K 2 0 ddb{1}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle plcache 128 26 0 0 1 0 1 1 0 8 0 rtpcb 120 126 0 122 3 0 3 3 0 8 2 rtentry 176 113 0 2 6 0 6 6 0 8 0 unpcb 144 326 0 305 6 0 6 6 0 8 5 syncache 336 5 0 5 1 0 1 1 0 8 1 tcpcb 736 108 0 103 1 0 1 1 0 8 0 arp 136 18 0 0 1 0 1 1 0 8 0 ipq 40 3 0 0 1 0 1 1 0 8 0 ipqe 40 3 0 0 1 0 1 1 0 8 0 inpcb 328 286 0 276 2 0 2 2 0 8 0 ip6q 72 2 0 1 1 0 1 1 0 8 0 ip6af 40 4 0 3 1 0 1 1 0 8 0 nd6 152 26 0 1 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 456 0 2 29 0 29 29 0 8 0 art_table 40 457 0 2 5 0 5 5 0 8 0 art_node 32 113 0 12 1 0 1 1 0 8 0 sysvmsgpl 40 3 0 0 1 0 1 1 0 8 0 semapl 112 15 0 5 1 0 1 1 0 8 0 shmpl 112 13 0 2 1 0 1 1 0 8 0 pool(0xffffffff83a2c018:shmpl): page inconsistency: page 0xfffffd806dc7a000; 23 on list, 11 missing, 35 items per page dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino2pl 256 2014 0 553 92 0 92 92 0 8 0 ffsino 296 2014 0 553 113 0 113 113 0 8 0 nchpl 144 2631 0 938 63 0 63 63 0 8 0 vnodes 216 2095 0 0 117 0 117 117 0 8 0 namei 1024 8197 0 8197 2 0 2 2 0 8 2 percpumem 16 50 0 0 1 0 1 1 0 8 0 kstatmem 264 25 0 0 2 0 2 2 0 8 0 scxspl 216 8574 0 8574 4 3 1 3 1 8 1 plimitpl 152 72 0 48 2 0 2 2 0 8 1 sigapl 424 695 0 641 7 0 7 7 0 8 0 knotepl 120 289 0 0 9 0 9 9 0 8 0 kqueuepl 224 158 0 148 5 0 5 5 0 8 4 pipepl 344 209 0 182 9 0 9 9 0 8 6 fdescpl 528 679 0 641 3 0 3 3 0 8 0 filepl 160 3729 0 3495 18 0 18 18 0 8 6 lockfpl 104 90 0 82 1 0 1 1 0 8 0 lockfspl 48 37 0 32 1 0 1 1 0 8 0 sessionpl 144 38 0 21 1 0 1 1 0 8 0 pgrppl 48 50 0 25 1 0 1 1 0 8 0 ucredpl 104 783 0 764 1 0 1 1 0 8 0 zombiepl 144 643 0 641 1 0 1 1 0 8 0 processpl 1232 695 0 641 5 0 5 5 0 8 0 procpl 664 1138 0 1071 7 0 7 7 0 8 0 sockpl 752 747 0 712 16 5 11 16 0 8 7 mcl64k 65536 3 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 mcl2k2 2112 1 0 0 1 0 1 1 0 8 0 mcl2k 2048 27 0 0 4 0 4 4 0 8 0 mtagpl 96 3 0 0 1 0 1 1 0 8 0 mbufpl 256 365 0 0 23 0 23 23 0 8 0 bufpl 280 2915 0 102 201 0 201 201 0 8 0 anonpl 32 5425 0 0 44 0 44 44 0 246 0 amapchunkpl 152 16564 0 15952 31 0 31 31 0 158 7 amappl16 200 1973 0 1952 5 1 4 5 0 8 1 amappl15 192 8 0 8 1 1 0 1 0 8 0 amappl14 184 411 0 410 1 0 1 1 0 8 0 amappl13 176 108 0 98 1 0 1 1 0 8 0 amappl12 168 926 0 889 2 0 2 2 0 8 0 amappl11 160 8 0 8 1 1 0 1 0 8 0 amappl10 152 59 0 49 1 0 1 1 0 8 0 amappl9 144 264 0 263 2 1 1 1 0 8 0 amappl8 136 124 0 123 1 0 1 1 0 8 0 amappl7 128 158 0 146 1 0 1 1 0 8 0 amappl6 120 153 0 152 1 0 1 1 0 8 0 amappl5 112 83 0 76 1 0 1 1 0 8 0 amappl4 104 251 0 234 1 0 1 1 0 8 0 amappl3 96 3204 0 3061 5 1 4 4 0 8 0 amappl2 88 494 0 441 2 0 2 2 0 8 0 amappl1 80 10447 0 9861 17 0 17 17 0 8 2 amappl 88 4571 0 4366 5 0 5 5 0 92 0 uvmvnodes 80 110 0 0 3 0 3 3 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 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 15 0 2 1 0 1 1 0 8 0 uaddrrnd 24 679 0 641 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 679 0 641 1 0 1 1 0 8 0 vmmpekpl 168 7324 0 7293 2 0 2 2 0 8 0 vmmpepl 168 50152 0 48023 103 0 103 103 0 357 10 vmsppl 488 678 0 641 7 1 6 6 0 8 0 rwobjpl 80 16369 0 15371 24 0 24 24 0 8 2 pdppl 4096 1365 0 1282 105 22 83 95 0 8 0 pvpl 32 12521 0 0 102 1 101 101 0 265 0 pmappl 256 678 0 641 4 1 3 3 0 8 0 extentpl 40 45 0 27 1 0 1 1 0 8 0 phpool 112 286 0 25 8 0 8 8 0 8 0 ddb{1}> machine ddbcpu 0 Stopped at x86_ipi_db+0x27: addq $0x8,%rsp x86_ipi_db(ffffffff83881ff0) 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 __mp_lock(ffffffff83a23940) at __mp_lock+0x199 __mp_lock_spin sys/kern/kern_lock.c:142 [inline] __mp_lock(ffffffff83a23940) at __mp_lock+0x199 sys/kern/kern_lock.c:173 softintr_dispatch(0) at softintr_dispatch+0x125 sys/kern/kern_softintr.c:83 dosoftint(0) at dosoftint+0x54 sys/arch/amd64/amd64/intr.c:862 Xsoftclock() at Xsoftclock+0x27 end of kernel end trace frame: 0x74217e81eae0, count: 8 ddb{0}> trace x86_ipi_db(ffffffff83881ff0) 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 __mp_lock(ffffffff83a23940) at __mp_lock+0x199 __mp_lock_spin sys/kern/kern_lock.c:142 [inline] __mp_lock(ffffffff83a23940) at __mp_lock+0x199 sys/kern/kern_lock.c:173 softintr_dispatch(0) at softintr_dispatch+0x125 sys/kern/kern_softintr.c:83 dosoftint(0) at dosoftint+0x54 sys/arch/amd64/amd64/intr.c:862 Xsoftclock() at Xsoftclock+0x27 end of kernel end trace frame: 0x74217e81eae0, count: -7 ddb{0}> machine ddbcpu 1 Stopped at db_enter+0x25: addq $0x8,%rsp db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8344c04b) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a2c018,2,ffff800033bb6338) at pool_do_get+0x5df pool_get(ffffffff83a2c018,2) at pool_get+0x162 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80003c3f2030,ffff800033bb6590,14c,ffff800033bb64e0) at shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 sys_shmget(ffff80003c3f2030,ffff800033bb6590,ffff800033bb64e0) at sys_shmget+0x195 sys/kern/sysv_shm.c:484 syscall(ffff800033bb6590) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800033bb6590) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x97d23c284b0, count: 7 ddb{1}> trace db_enter() at db_enter+0x25 sys/arch/amd64/amd64/db_interface.c:438 panic(ffffffff8344c04b) at panic+0x1e5 sys/kern/subr_prf.c:198 pool_do_get(ffffffff83a2c018,2,ffff800033bb6338) at pool_do_get+0x5df pool_get(ffffffff83a2c018,2) at pool_get+0x162 sys/kern/subr_pool.c:-1 shmget_allocate_segment(ffff80003c3f2030,ffff800033bb6590,14c,ffff800033bb64e0) at shmget_allocate_segment+0x1af sys/kern/sysv_shm.c:-1 sys_shmget(ffff80003c3f2030,ffff800033bb6590,ffff800033bb64e0) at sys_shmget+0x195 sys/kern/sysv_shm.c:484 syscall(ffff800033bb6590) at syscall+0xb17 mi_syscall sys/sys/syscall_mi.h:176 [inline] syscall(ffff800033bb6590) at syscall+0xb17 sys/arch/amd64/amd64/trap.c:783 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x97d23c284b0, count: -8