colima icon indicating copy to clipboard operation
colima copied to clipboard

Cannot start colima on Ubuntu

Open pbarnes-tibco opened this issue 1 year ago • 2 comments

Description

New to colima but looking for an alternative to docker desktop on linux. I installed colima as described in the readme. When I try to start it I get the following:

$ colima start
INFO[0000] starting colima                              
INFO[0000] runtime: docker+k3s                          
INFO[0000] creating and starting ...                     context=vm
> Terminal is not available, proceeding without opening an editor
> "Attempting to download the image from \"https://github.com/abiosoft/alpine-lima/releases/download/colima-v0.4.2-1/alpine-lima-clm-3.14.6-x86_64.iso\"" digest="sha512:229121f3ff3cb645a602e3f21d687207ad14c48330001330430c84e88fb0311a70b4a94250c2e24e80e8d3522ee573e169fef76337214136d1dde9bbc4ec1354"
> Using cache "/home/pbarnes/.cache/lima/download/by-url-sha256/43232d22d3e3b6258c10f697dcf6098c7d7a2d49fc6e04a2bf290065fb7800a7/data"
> "[hostagent] exec: \"/home/pbarnes/.colima/_wrapper/0da2e7b69d03a689f956672a9719bf933bae1c88/bin/qemu-system-x86_64\": stat /home/pbarnes/.colima/_wrapper/0da2e7b69d03a689f956672a9719bf933bae1c88/bin/qemu-system-x86_64: no such file or directory" fields.level=fatal
> host agent process has exited: exit status 1

It is looking for qemu-system-x86_64 under ~/.colima/wrapper but it is not there. Not sure if this is supposed to be a link to /usr/bin/qemu-system-x86_64 or what...

I'm running Ubuntu 22.04.1.

Version

Colima Version: 0.4.4 Lima Version: 0.11.3 Qemu Version: 6.2.0

It was not clear from install instructions that Lima needed to be installed. I went ahead and installed it when I saw that the version was requested here; but it made no difference.

Operating System

  • [ ] macOS Intel
  • [ ] macOS M1
  • [X] Linux

Reproduction Steps

  1. nix-env -iA nixpkgs.colima
  2. colima start

Expected behaviour

Colima should start

Additional context

No response

pbarnes-tibco avatar Sep 09 '22 22:09 pbarnes-tibco

Having the same issue. Did someone find any workaround for this?

mag2007 avatar Sep 16 '22 08:09 mag2007

I am currently on a trip and mainly on mobile at the moment. Will have a look over the weekend.

abiosoft avatar Sep 16 '22 10:09 abiosoft

This is fixed already but not yet on Nix.

abiosoft avatar Sep 18 '22 15:09 abiosoft

confirmed that I can build from source as described here and start colima successfully on linux.

pbarnes-tibco avatar Sep 23 '22 00:09 pbarnes-tibco

Same for me, I build the source and installed in, but still not working, it fails because: "exec: \"qemu-system-x86_64\": executable file not found in $PATH"

nicoandresr avatar Jan 16 '23 18:01 nicoandresr

@nicoandresr you need to have Qemu installed. That would be qemu-system package on Debian and Ubuntu based distros

abiosoft avatar Jan 16 '23 21:01 abiosoft

Thank you @abiosoft , I'm on Arch Linux, I installed qemu-system-x86 package and fixed the problem, but now, I get stuck in another issue when I run colima start the command keeps in Waiting for the essential requirement 1 of 5: "ssh" I saw the issue 411 but not success in run colima at this point, the complete message is:

> colima start                                                                                                                                                                  
> INFO[0000] starting colima                              
> INFO[0000] runtime: docker                              
> INFO[0000] starting ...                                  context=vm
> [hostagent] failed to exit SSH master
> [hostagent] Shutting down QEMU with ACPI
> [hostagent] failed to open the QMP socket "/home/nicoandresr/.lima/colima/qmp.sock", forcibly killing QEMU
> [hostagent] failed to kill QEMU
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"
> [hostagent] Waiting for the essential requirement 1 of 5: "ssh"

My versions are:

colima version v0.5.2-8-g1d3e117
git commit: 1d3e117bfaf4fbba0818c90705a721f6c3fcdff0
qemu-img version 7.2.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developers
limactl version 0.14.1
QEMU emulator version 7.2.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developers

nicoandresr avatar Jan 17 '23 07:01 nicoandresr

@nicoandresr seems the VM is in a broken state. Have you tried a force kill?

# forcefully kill colima and qemu
colima stop --force
# reset
colima delete
# start afresh
colima start

abiosoft avatar Jan 17 '23 08:01 abiosoft

Thank you @abiosoft for your patience, I figured out my problem was with the incomplete qemu installation, I installed qemu-system-x86, but, I needed qemu-base (full headless qemu setup), I unknown the dependencies required by colima, so, I messed up with them, but, now my problem is gone installing the package qemu-base in my arch system, so, for future readers, I left here the steps to install and run colima in Arch,

Install qemu dependency

sudo pacman -S qemu-base go docker

Install lima and colima from Aur

yay -S colima-bin lima-bin

After install correctly qemu-base I can start colima correctly.

nicoandresr avatar Jan 17 '23 11:01 nicoandresr