colima: colima start does not honor default config, but then overwrites it
Description
The vz VM type does not work on my M3 Mac, so I must use qemu. My config at ~/.config/default/colima.yaml has vmType: qemu so that when I run colima start I should use the qemu VM type. Instead it goes with the vz type, and overwrites the config file as well. It also fails for this same reason when running brew services start colima, and indeed overwrites the config too. I am able to run colima start --edit, see that it has already overwritten the vmType, edit it to qemu, then exit and it will work, but a simple colima start fails. The only way I have ever gotten it to work in brew services temporarily is to run colima delete then reinstall colima, but it breaks again after some time, and I am not sure what triggers it, possibly a reboot.
Version
colima version 0.6.8 git commit: 9b0809d0ed9ad3ff1e57c405f27324e6298ca04f limactl version 0.20.1 qemu-img version 8.2.1
Operating System
- macOS Intel <= 13 (Ventura)
- macOS Intel >= 14 (Sonoma)
- Apple Silicon <= 13 (Ventura)
- Apple Silicon >= 14 (Sonoma)
- Linux
Output of colima status
If I run colima start, then colima status:
FATA[0000] colima is not running
If I run colima start --edit, and edit it to qemu, then run colima status:
INFO[0000] colima is running using QEMU
INFO[0000] arch: aarch64
INFO[0000] runtime: docker
INFO[0000] mountType: virtiofs
INFO[0000] socket: unix:///Users/MYUSER/.colima/default/docker.sock
Reproduction Steps
- Set
vmType: qemuin~/.colima/default/colima.yaml. - Run
colima start. - Note failure and check config to see it over.written with
vmType: vz
Expected behaviour
colima start should run the profile in the config and not overwrite the config.
Additional context
colima start gives the following:
INFO[0000] runtime: docker
INFO[0000] starting ... context=vm
> Using the existing instance "colima"
> errors inspecting instance: [vz driver is running but host agent is not]
FATA[0000] error starting vm: error at 'starting': exit status 1
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 15
- Comments: 21 (2 by maintainers)
Commits related to this issue
- Use qemu by default on M3 macs This removes the special case logic for M3 macs that use the vz driver instead of qemu. A lot of people are having trouble with vz on M3 macs: - https://github.com/a... — committed to bradleyayers/colima by bradleyayers 2 years ago
- core: revert to using qemu by default on M3 macs (#1058) This removes the special case logic for M3 macs that use the vz driver instead of qemu. A lot of people are having trouble with vz on M3 macs:... — committed to abiosoft/colima by bradleyayers 2 years ago
I encountered the same issue. After running this command, it worked fine.
colima stop -fI ran into this as well but also got the following error:
Fixed it with:
colima stop -frm -rf /Users/$USER/.colima/_lima/_networkscolima startHi guys,
same problem occurred here on my Mac M3 (Sonoma) after
brew upgrade. I could get it running again withcolima deletecolima startBest regards, mscdit
P.S.: Attention … by doing so I hade to re-load all images/containers!
I have the same issue and a very naive solution worked for me. Definitely not a fix but restarting my computer worked.
Have you tried turning it off and on again?
This happened to me after updating to Sequoia 15.3.1 (macbook pro m3 max) and running
colima stop -ffixed the issue. Try this first before you trycolima deletebecause you’ll delete all your container data!This still happens randomly to me and because I am lazy I created an alias for it and added it to my
.zshrc:Had this problem recently and this quoted comment is the one that actually worked for me.
With Colima 0.7.5, I had this issue spontaneously in Mac M1, with a VZ VM that previously worked well. I can confirm that this solution from @kkarthik-1 fixed the issue:
I’m also having trouble with the same problem on my M3 Mac. Even if I rewrite the VM type of
colima.yamltoqemu, when I runcolima start, a log sayingStarting the instance "colima" with VM driver "vz"is displayed, and The VM type will be automatically rewritten tovz.I would appreciate it if it would be fixed as soon as possible.
Just for the record, I encountered the same issue but I didn’t have to run the
rm -rfcommand. Just forcing stop and starting again worked fine for me.