Skip to content

QEMU crashes when receiving network connection on NetBSD

Host environment

  • Operating system: NetBSD
  • OS/kernel version: 9.2
  • Architecture: amd64 (x86_64)
  • QEMU flavor: qemu-system-x86_64
  • QEMU version: 6.1.0 compiled with pkgsrc
  • QEMU command line:
    qemu-system-x86_64 -m 1024 -hda vm-image.qcow2 -net nic -net user,hostfwd=tcp::2222-:22

Emulated/Virtualized environment

  • Operating system: Linux
  • OS/kernel version: 4.18.0
  • Architecture: x86_64

Description of problem

After booting the VM, connecting to the TCP port 2222 of the host immediately crashes the VM and qemu prints:

** Slirp:ERROR:../slirp/src/tcp_subr.c:477:tcp_connect: assertion failed: (ret == 0) Bail out! Slirp:ERROR:../slirp/src/tcp_subr.c:477:tcp_connect: assertion failed: (ret == 0)

Steps to reproduce

  1. start VM as indicated
  2. telnet localhost 2222
  3. crash

Additional information

** Slirp:ERROR:../slirp/src/tcp_subr.c:477:tcp_connect: assertion failed: (ret == 0) Bail out! Slirp:ERROR:../slirp/src/tcp_subr.c:477:tcp_connect: assertion failed: (ret == 0)

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information