"Kirill A. Korinsky" <kir...@korins.ky> writes:

> Greetings,
>
> When playing with autoinstall in VM I encountered a kernel panic. It doesn't
> happened each attempt, but often enough to be easy found.

Thanks for the report. It looks like you're using 7.4 for the host and
guest (based on the dmesg and the fact you're booting the ramdisk kernel
from /bsd.rd). Correct?

Any guess how frequently it occurs? 1 in 10? 1 in 100? I haven't seen
this myself but have a similar report from mbuhl@ when testing a diff I
shared in November (that hasn't been committed) so I'm curious if this
is something related to virtio(4) and vio(4) in the kernel vs. something
in vmd(8). (The diff he was testing was a complete re-write of vmd's
network device emulation.)

I need to find a way to reproduce it myself to figure out if it's a
memory corruption in the vmd network device emulation or if it's a
kernel/virtio issue in the guest.

-dv

>
> An example of panic:
>
> island$ vmctl start -c -b /tmp/bsd.rd -B net playground
> Connected to /dev/ttyp2 (speed 115200)
> Copyright (c) 1982, 1986, 1989, 1991, 1993
>       The Regents of the University of California.  All rights reserved.
> Copyright (c) 1995-2023 OpenBSD. All rights reserved.  https://www.OpenBSD.org
>
> OpenBSD 7.4 (RAMDISK_CD) #1322: Tue Oct 10 09:07:38 MDT 2023
>     dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/RAMDISK_CD
> real mem = 1056964608 (1008MB)
> avail mem = 1020968960 (973MB)
> random: boothowto does not indicate good seed
> mainbus0 at root
> bios0 at mainbus0
> acpi at bios0 not configured
> cpu0 at mainbus0: (uniprocessor)
> cpu0: AMD Ryzen 9 3900 12-Core Processor, 3100.00 MHz, 17-71-00
> cpu0: 
> FPU,VME,DE,PSE,TSC,MSR,PAE,CX8,SEP,PGE,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,SSE3,PCLMUL,SSSE3,FMA3,CX16,SSE4.1,SSE4.2,MOVBE,POPCNT,AES,XSAVE,AVX,F16C,RDRAND,HV,NXE,MMXX,FFXSR,PAGE1GB,LONG,LAHF,CMPLEG,EAPICSP,AMCR8,ABM,SSE4A,MASSE,3DNOWP,OSVW,IBS,SKINIT,TCE,TOPEXT,CPCTR,DBKP,PCTRL3,ITSC,FSGSBASE,BMI1,AVX2,SMEP,BMI2,RDSEED,ADX,SMAP,CLFLUSHOPT,CLWB,SHA,UMIP,IBRS_SM
> cpu0: 32KB 64b/line 8-way D-cache, 32KB 64b/line 8-way I-cache, 512KB 
> 64b/line 8-way L2 cache, 16MB 64b/line 16-way L3 cache
> pvbus0 at mainbus0: OpenBSD
> pci0 at mainbus0 bus 0
> pchb0 at pci0 dev 0 function 0 "OpenBSD VMM Host" rev 0x00
> virtio0 at pci0 dev 1 function 0 "Qumranet Virtio RNG" rev 0x00
> viornd0 at virtio0
> virtio0: irq 3
> virtio1 at pci0 dev 2 function 0 "Qumranet Virtio Network" rev 0x00
> vio0 at virtio1: address fe:e1:ba:05:ec:58
> virtio1: irq 5
> virtio2 at pci0 dev 3 function 0 "Qumranet Virtio Storage" rev 0x00
> vioblk0 at virtio2
> scsibus0 at vioblk0: 1 targets
> sd0 at scsibus0 targ 0 lun 0: <VirtIO, Block Device, >
> sd0: 204800MB, 512 bytes/sector, 419430400 sectors
> virtio2: irq 6
> virtio3 at pci0 dev 4 function 0 "OpenBSD VMM Control" rev 0x00
> vmmci0 at virtio3
> virtio3: irq 7
> isa0 at mainbus0
> com0 at isa0 port 0x3f8/8 irq 4: ns8250, no fifo
> com0: console
> softraid0 at root
> scsibus1 at softraid0: 256 targets
> root on rd0a swap on rd0b dump on rd0b
> WARNING: CHECK AND RESET THE DATE!
> erase ^?, werase ^W, kill ^U, intr ^C, status ^T
>
> Welcome to the OpenBSD/amd64 7.4 installation program.
> (I)nstall, (U)pgrade, (A)utoinstall or (S)hell? A
> Fetching http://192.168.0.1/fe:e1:ba:05:ec:58-install.conf?path=7.4/amd64
> Fetching 
> http://192.168.0.1/playground.island.local.-install.conf?path=7.4/amd64
> Fetching http://192.168.0.1/install.conf?path=7.4/amd64
> Response file location? [http://192.168.0.1/install.conf] 
> http://install.catap.net/install.conf
> Fetching http://install.catap.net/install.conf
> Performing non-interactive install...
> Terminal type? [vt220] vt220
> System hostname? (short form, e.g. 'foo') [playground] playground
>
> panic: pool_do_get: mcl2k free list modified: page 0xfffffd8037a41000; item 
> addr 0xfffffd8037a43000; offset 0x0=0xa0000 != 0xa9af274a93548aef
> syncing disks... done
> panic: pool_do_get: mcl2k free list modified: page 0xfffffd8037a41000; item 
> addr 0xfffffd8037a43000; offset 0x0=0xa0000 != 0xa9af274a93548aef
>
> dump to dev 17,1 not possible
> vmmci0: powerdown
> rebooting...
>
>
> VM configuration quite simple:
>
> vm "playground" {
>       memory 1G
>
>       disk "/var/vm/playground.qcow2"
>
>       interface {
>               switch "local"
>               lladdr "fe:e1:ba:05:ec:58"
>       }
>
>       owner catap
> }
>
> and disk size is 200Gb.

Reply via email to