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

[BUG] [macos] virtualization error: hypervisor virtualization error #4402

Open
vandeand opened this issue Oct 16, 2024 · 6 comments
Open

[BUG] [macos] virtualization error: hypervisor virtualization error #4402

vandeand opened this issue Oct 16, 2024 · 6 comments
Labels
kind/bug Something isn't working status/need triage

Comments

@vandeand
Copy link

General information

  • OS: macOS
  • Hypervisor: vfkit
  • Did you run crc setup before starting it - Yes
  • Running CRC on: Laptop

CRC version

# Put `crc version` output here
CRC version: 2.42.0+6689ec
OpenShift version: 4.17.0
MicroShift version: 4.16.14

CRC status

DEBU CRC version: 2.42.0+6689ec                   
DEBU OpenShift version: 4.17.0                    
DEBU MicroShift version: 4.16.14                  
DEBU Running 'crc status'                         
CRC VM:          Stopped
OpenShift:       Stopped (v4.17.0)
RAM Usage:       0B of 0B
Disk Usage:      0B of 0B (Inside the CRC VM)
Cache Usage:     77.67GB
Cache Directory: /Users/vandeand/.crc/cache

CRC config

- consent-telemetry                     : no
- disk-size                             : 50
- memory                                : 16000

Host Operating System

ProductName:		macOS
ProductVersion:		14.5
BuildVersion:		23F79

Steps to reproduce

  1. Run crc start --log-level debug

Expected

crc to start up and allow access to do oc login and access https://console-openshift-console.apps-crc.testing/

Actual

Freezes after showing virtualization error: hypervisor virtualization error

Logs

Last part of logs for crc start --log-level debug

DEBU SSH command results: err: , output: machineconfig.machineconfiguration.openshift.io/99-master-ssh patched
INFO Waiting until the user's pull secret is written to the instance disk...
DEBU retry loop: attempt 0
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 1
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 2
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 3
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 4
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 5
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 6
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 7
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 8
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 9
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 10
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 11
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 12
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 13
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 14
DEBU Running SSH command:
DEBU SSH command succeeded
DEBU error: Temporary error: pull secret not updated to disk - sleeping 2s
DEBU retry loop: attempt 15
DEBU Running SSH command:
DEBU Error: virtualization error: hypervisor virtualization error
DEBU Usage:
DEBU vfkit [flags]
DEBU
DEBU Flags:
DEBU -b, --bootloader strings bootloader configuration (default [])
DEBU -c, --cpus uint number of virtual CPUs (default 1)
DEBU -d, --device stringArray devices
DEBU --gui display the contents of the virtual machine onto a graphical user interface
DEBU -h, --help help for vfkit
DEBU -i, --initrd string path to the virtual machine initrd
DEBU -k, --kernel string path to the virtual machine linux kernel
DEBU -C, --kernel-cmdline string linux kernel command line
DEBU --log-level string set log level
DEBU -m, --memory uint virtual machine RAM size in mibibytes (default 512)
DEBU --restful-uri string URI address for RestFul services (default "none://")
DEBU -t, --timesync string sync guest time when host wakes up from sleep
DEBU -v, --version version for vfkit
DEBU
DEBU virtualization error: hypervisor virtualization error

Before gather the logs try following if that fix your issue

$ crc delete -f
$ crc cleanup
$ crc setup
$ crc start --log-level debug

Please consider posting the output of crc start --log-level debug on http://gist.github.com/ and post the link in the issue.

@vandeand vandeand added kind/bug Something isn't working status/need triage labels Oct 16, 2024
@praveenkumar praveenkumar changed the title [BUG] [BUG] [macos] virtualization error: hypervisor virtualization error Oct 17, 2024
@Sysiphos
Copy link

Sysiphos commented Nov 7, 2024

Try reducing memory footprint ... that happens on my machine all the time when there is not enough memory ... you configured 16g are you sure you have more than that free memory?

@vandenan
Copy link

vandenan commented Nov 8, 2024

Try reducing memory footprint ... that happens on my machine all the time when there is not enough memory ... you configured 16g are you sure you have more than that free memory?

Thanks, that could be it, I will see if its possible to reduce the memory footprint of the application running in openshift

@kaovilai
Copy link
Contributor

If memory is the case, I think it's better to test create vm early.. not wait until after several minutes.

@cfergeau
Copy link
Contributor

Apple's virtualization has this API https://developer.apple.com/documentation/virtualization/vzvirtualmachineconfiguration/3656719-maximumallowedmemorysize?language=objc
If this is a lack of memory which is preventing the VM from starting, maybe using this API would help.

@praveenkumar
Copy link
Member

Apple's virtualization has this API https://developer.apple.com/documentation/virtualization/vzvirtualmachineconfiguration/3656719-maximumallowedmemorysize?language=objc If this is a lack of memory which is preventing the VM from starting, maybe using this API would help.

This should be part of vfkit driver side or does it already expose this API?

@cfergeau
Copy link
Contributor

Apple's virtualization has this API https://developer.apple.com/documentation/virtualization/vzvirtualmachineconfiguration/3656719-maximumallowedmemorysize?language=objc If this is a lack of memory which is preventing the VM from starting, maybe using this API would help.

This should be part of vfkit driver side or does it already expose this API?

This would need to be added to vfkit, I'm not even sure how it could be nicely exposed for use by applications :-/

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 status/need triage
Projects
None yet
Development

No branches or pull requests

6 participants