abiosoft / colima

Container runtimes on macOS (and Linux) with minimal setup
MIT License
18.61k stars 380 forks source link

Error in Colima start - hostagent qemu --enable-vde #928

Open rsdetoni opened 9 months ago

rsdetoni commented 9 months ago

Description

Hi, Folks

   I was using colima normally and I stoped it with command+c when I was starting the colima, because of that now the colima is not working anymore and I have this error: 

INFO[0000] starting colima
INFO[0000] runtime: docker
INFO[0000] preparing network ... context=vm INFO[0004] starting ... context=vm

Using the existing instance "colima" "[hostagent] netdev \"vde\" is not supported by /Users/scarenci/.colima/_wrapper/deb1e70b41dbdb7e6adc33904dd8f6df01f3b72d/bin/qemu-system-x86_64 ( Hint: recompile QEMU with configure --enable-vde )" fields.level=fatal host agent process has exited: exit status 1 FATA[0004] error starting vm: error at 'starting': exit status 1

I already reinstall colima / docker and I execute the command "colima delete" and restart the mac, but this error persists.

I appreciate any suggestion

Best regards

Version

colima version v0.4.4

Operating System

Output of colima status

colima is not running

Reproduction Steps

  1. Install Colima: brew install colima
  2. Install docker: brew install docker
  3. Install jq: brew install jq
  4. colima start -c 2 -m 8 --network-address

Expected behaviour

Start with success

Additional context

No response

abiosoft commented 9 months ago

What command do you use to start colima?

rsdetoni commented 9 months ago

colima start or colima start -c 2 -m 8 --network-address

jandubois commented 9 months ago

It means your version of QEMU does not support vde. I think the Homebrew version dropped support for it in QEMU 8.2 (maybe unintentionally due to changes in the build setup). It looks like 8.1.3 still supports it:

$ qemu-system-x86_64 --version
QEMU emulator version 8.1.3
Copyright (c) 2003-2023 Fabrice Bellard and the QEMU Project developers

$ qemu-system-x86_64 -M none -netdev help
Available netdev backend types:
socket
stream
dgram
hubport
tap
user
vde
bridge
vhost-user
vmnet-host
vmnet-shared
vmnet-bridged

You should switch to using socket_vmnet instead of vde_vmnet anyways, as the latter has been deprecated.

jandubois commented 9 months ago

I'm confused now; I thought I ran into the same issue with latest QEMU from Homebrew before, but when I checked right now, it looks like 8.1.3 is still the latest. It may have been finch which was bundling a QEMU 8.2 without vde support. Sorry for the confusion, the basic issue remains the same, that you have a version of QEMU compiled without vde support.

rsdetoni commented 9 months ago

Here said that my QEMU is 7, but I have installed 8.1.3

qemu-system-x86_64 --version QEMU emulator version 7.0.0 Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developers

How can I uninstall and point to the right version?

jandubois commented 9 months ago

It looks like colima now ships its own wrapped version, so you have to wait for an answer from @abiosoft.

You can check VDE support by running

/Users/scarenci/.colima/_wrapper/deb1e70b41dbdb7e6adc33904dd8f6df01f3b72d/bin/qemu-system-x86_64 -M none -netdev help

(or same thing with --version to check the version of the bundled QEMU, but that doesn't say may about how it was compiled/configured).