Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ubuntu: Lima exited with code 1 - package omvf missing #4524

Closed
strowi opened this issue Apr 21, 2023 · 8 comments
Closed

Ubuntu: Lima exited with code 1 - package omvf missing #4524

strowi opened this issue Apr 21, 2023 · 8 comments
Assignees
Labels
kind/bug Something isn't working
Milestone

Comments

@strowi
Copy link

strowi commented Apr 21, 2023

Actual Behavior

Had a working 1.7.0 on ubuntu 22.04, just upgraded to 1.8.1 and get an error "lima exited with code 1".

   'time="2023-04-21T09:15:12+02:00" level=fatal msg="exiting, status={Running:false Degraded:false Exiting:true Errors:[] SSHLocalPort:0} (hint: see \\"/home/rvg/.local/share/rancher-desktop/lima/0/ha.stderr.log\\")"\n',
  code: 1,
  command: [
    '/opt/rancher-desktop/resources/resources/linux/lima/bin/limactl',
    'start',
    '--tty=false',
    '0'
  ]
}
~> cat .local/share/rancher-desktop/lima/0/ha.stderr.log
{"level":"debug","msg":"Creating iso file /home/rvg/.local/share/rancher-desktop/lima/0/cidata.iso","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"Using /tmp/diskfs_iso1392721507 as workspace","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"OpenSSH version 8.9.1 detected","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"AES accelerator seems available, prioritizing aes128-gcm@openssh.com and aes256-gcm@openssh.com","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"Start udp server listening on: 127.0.0.1:52262","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"Start tcp server listening on: 127.0.0.1:34013","time":"2023-04-21T09:15:12+02:00"}
{"level":"debug","msg":"firmware candidates = [/home/rvg/.local/share/qemu/edk2-x86_64-code.fd /usr/share/qemu/edk2-x86_64-code.fd /usr/share/OVMF/OVMF_CODE.fd /usr/share/qemu/ovmf-x86_64-code.bin /usr/share/edk2-ovmf/x64/OVMF_CODE.fd]","time":"2023-04-21T09:15:12+02:00"}
{"level":"fatal","msg":"could not find firmware for \"/usr/bin/qemu-system-x86_64\" (hint: try setting `firmware.legacyBIOS` to `true`)","time":"2023-04-21T09:15:12+02:00"}

Steps to Reproduce

  • install v1.8.1 on ubuntu 22.04
  • start rancher-desktop
  • see error

Result

rancher-desktop won't start

Expected Behavior

Everything working

Additional Information

After searching for the firmware mentioned in the logs, installing package ovmf seems to have done the trick.
That package probably should be installed automatically..

Rancher Desktop Version

1.8.1

Rancher Desktop K8s Version

1.24.13

Which container engine are you using?

containerd (nerdctl)

What operating system are you using?

Ubuntu

Operating System / Build Version

22.04

What CPU architecture are you using?

x64

Linux only: what package format did you use to install Rancher Desktop?

deb

Windows User Only

No response

@strowi strowi added the kind/bug Something isn't working label Apr 21, 2023
@strowi
Copy link
Author

strowi commented Apr 21, 2023

small correction: with the installed omvf, i am getting some errors, e.g. i am unable to run adminer:4.8.1 on rancher-desktop, which works on normal x86_64-cluster and rancher-desktop 1.7.0. It only throws an coredump without any other error.

@ericpromislow
Copy link
Contributor

I had no problem upgrading from 1.7.0 to 1.8.1 on Ubuntu 22.04, but I see the host already has a /usr/share/OVMF directory. The directory is about 40 minutes old, but all its contents have a datestamp of 2022-09-12 . I don't know how that directory was installed.

Could you give me specific directions for running adminer so I can try to repro that?

@strowi
Copy link
Author

strowi commented Apr 22, 2023

I gave it another shot:

  • uninstalled rancher-desktop and ovmf

  • installed rancher-desktop=1.7.0*
    Result: no /usr/share/OVMF/* but rancher-desktop works

  • upgrade rancher-desktop to 1.8.1
    Result: still no /usr/share/OVMF/* and rancher-desktop fails with the mentioned lima-error.

Not sure about ovmf-package, that was my workaround after searching, guess the file must've come from somewhere else or not being used at all with 1.7.0.

As for adminer, this might've been an unrelated side-problem - kubectl run -ti --image adminer:4.8.1 adminer seems to run now.

Not sure which logs might be helpful here.. but happy to provide more.

@julian-alarcon
Copy link

Got a similar error when I upgraded from Ubuntu 23.10 to Ubuntu 24.04 Noble Numbat.

The error was that it was not able to find the firmware.

The package ovmf in Ubuntu is the one that provides this files, but it seems that it was looking for /usr/share/OVMF/OVMF_CODE.fd but in the recent version of this package I could not find that file but this OVMF_CODE_4M.fd.

I ended up creating a symbolic link to that file and now it's working!

sudo ln -s /usr/share/OVMF/OVMF_CODE_4M.fd /usr/share/OVMF/OVMF_CODE.fd

@julian-alarcon
Copy link

julian-alarcon commented Apr 26, 2024

It seems that this has been fixed in Lime in this recent change:
lima-vm/lima@3c4a7f3
lima-vm/lima#2124

Available since version 0.20.0 of Lima.
So, this https://github.com/rancher-sandbox/lima/blob/master/pkg/qemu/qemu.go#L1130-L1131 needs to be updated and then a new version of https://github.com/rancher-sandbox/rancher-desktop-lima should be needed.

@DotNetRockStar
Copy link

Got a similar error when I upgraded from Ubuntu 23.10 to Ubuntu 24.04 Noble Numbat.

The error was that it was not able to find the firmware.

The package ovmf in Ubuntu is the one that provides this files, but it seems that it was looking for /usr/share/OVMF/OVMF_CODE.fd but in the recent version of this package I could not find that file but this OVMF_CODE_4M.fd.

I ended up creating a symbolic link to that file and now it's working!

sudo ln -s /usr/share/OVMF/OVMF_CODE_4M.fd /usr/share/OVMF/OVMF_CODE.fd

Wow, this worked for me too. Thanks for posting this.

@jandubois jandubois added this to the 1.14 milestone Apr 30, 2024
@jandubois
Copy link
Member

#6799 updates Lima to 0.21.0.

@julian-alarcon
Copy link

Confirmed as fixed in the latest version 1.14!

If you used the above workaround creating the symbolic link, you can now remove that link as it's not needed anymore:

sudo rm -f /usr/share/OVMF/OVMF_CODE.fd

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants