rancher-sandbox / rancher-desktop

Container Management and Kubernetes on the Desktop
https://rancherdesktop.io
Apache License 2.0
5.93k stars 280 forks source link

Error Starting Kubernetes on macOS - limactl exited with code 1 connection refused #7493

Open ezhirkov opened 3 weeks ago

ezhirkov commented 3 weeks ago

Actual Behavior

Apple M1 Pro, macOS 14.6.1. Rancher desktop 1.15.1, kubernetes 1.23.17 After upgrading Rancher desktop from version 1.13.1 to 1.15.1 getting following error during start. Fixed it by factory reset, but after os restart issue appeared again.

image

Log: 'time="2024-09-17T11:21:35+04:00" level=debug msg="received an event" event="{2024-09-17 11:21:35.450349 +0400 +04 {false false true [] 0}}"\n' + 'time="2024-09-17T11:21:35+04:00" level=fatal msg="exiting, status={Running:false Degraded:false Exiting:true Errors:[] SSHLocalPort:0} (hint: see \"/Users/ezhirkov/Library/Application Support/rancher-desktop/lima/0/ha.stderr.log\")"\n', code: 1, [Symbol(child-process.command)]: '/Applications/Rancher Desktop.app/Contents/Resources/resources/darwin/lima/bin/limactl.ventura --debug start --tty=false 0' } 2024-09-17T07:21:35.452Z: Progress: errored Starting virtual machine: Error: /Applications/Rancher Desktop.app/Contents/Resources/resources/darwin/lima/bin/limactl.ventura exited with code 1

ha.stderr.log :

{"error":"exec: \"/opt/socket_vmnet/bin/socket_vmnet\": stat /opt/socket_vmnet/bin/socket_vmnet: no such file or directory","level":"debug","msg":"Failed to look up socket_vmnet path \"/opt/socket_vmnet/bin/socket_vmnet\"","time":"2024-09-17T11:21:34+04:00"} {"level":"debug","msg":"Creating iso file /Users/ezhirkov/Library/Application Support/rancher-desktop/lima/0/cidata.iso","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"Using /var/folders/lk/51_tt2nn2jzc6qs1xhl1_3bw0000gs/T/diskfs_iso2274589838 as workspace","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"Failed to detect CPU features. Assuming that AES acceleration is available on this Apple silicon.","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"OpenSSH version 9.7.1 detected","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"AES accelerator seems available, prioritizing aes128-gcm@openssh.com and aes256-gcm@openssh.com","time":"2024-09-17T11:21:35+04:00"} {"level":"info","msg":"hostagent socket created at /Users/ezhirkov/Library/Application Support/rancher-desktop/lima/0/ha.sock","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"Start udp DNS listening on: 127.0.0.1:51282","time":"2024-09-17T11:21:35+04:00"} {"level":"info","msg":"Starting VZ (hint: to watch the boot progress, see \"/Users/ezhirkov/Library/Application Support/rancher-desktop/lima/0/serial*.log\")","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"Start tcp DNS listening on: 127.0.0.1:49977","time":"2024-09-17T11:21:35+04:00"} {"level":"info","msg":"new connection from to ","time":"2024-09-17T11:21:35+04:00"} {"level":"debug","msg":"Using socketVMNet (\"/opt/rancher-desktop/bin/socket_vmnet\")","time":"2024-09-17T11:21:35+04:00"} {"level":"fatal","msg":"dial unix /private/var/run/socket_vmnet.rancher-desktop-shared: connect: connection refused","time":"2024-09-17T11:21:35+04:00"}

Steps to Reproduce

1) Upgrade rancher desktop to version 1.15.1 2) restart.

Result

image

Expected Behavior

No errors

Additional Information

No response

Rancher Desktop Version

1.15.1

Rancher Desktop K8s Version

1.23.17

Which container engine are you using?

moby (docker cli)

What operating system are you using?

macOS

Operating System / Build Version

MacOS Sonoma 14.6.1

What CPU architecture are you using?

arm64 (Apple Silicon)

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

None

Windows User Only

No response

kdyck-cb commented 2 weeks ago

FWIW, I'm seeing the same problem on Intel hardware - macOS Sonoma 14.7 - Rancher Desktop 1.15.1 darwin (x64).

jandubois commented 2 weeks ago

The critical error here is

dial unix /private/var/run/socket_vmnet.rancher-desktop-shared: connect: connection refused

You should check if the daemon is running, and if there are any errors in the daemon logs.

Alternatively, are you sure you need to run with "admin settings"? It is only required if you need a separate bridged IP address for the guest VM, or if you need the /var/run/docker.sock in the default location.