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

Unable to ping VM host (lima/colima) #686

Open
spkane opened this issue Mar 1, 2022 · 6 comments
Open

Unable to ping VM host (lima/colima) #686

spkane opened this issue Mar 1, 2022 · 6 comments

Comments

@spkane
Copy link

spkane commented Mar 1, 2022

Description

I setup networking for lima/colima a few weeks ago and it had been working fine, but today, even after some troubleshooting, I can not ping the colima VM from my host. I have updated lima, colima, and macOS with patch releases lately, so that might be related, but I am not really sure what to check at this point.

On the mac I can see this:

bridge100: flags=8a63<UP,BROADCAST,SMART,RUNNING,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
	options=3<RXCSUM,TXCSUM>
	ether 16:7d:da:6a:3e:64
	inet 192.168.105.1 netmask 0xffffff00 broadcast 192.168.105.255
	inet6 fe80::147d:daff:fe6a:3e64%bridge100 prefixlen 64 scopeid 0x14
	inet6 fdce:1812:ad25:915f:834:c0bf:f47f:b16e prefixlen 64 autoconf secured
	Configuration:
		id 0:0:0:0:0:0 priority 0 hellotime 0 fwddelay 0
		maxage 0 holdcnt 0 proto stp maxaddr 100 timeout 1200
		root id 0:0:0:0:0:0 priority 0 ifcost 0 port 0
		ipfilter disabled flags 0x0
	member: vmenet0 flags=3<LEARNING,DISCOVER>
	        ifmaxaddr 0 port 19 priority 0 path cost 0
	nd6 options=201<PERFORMNUD,DAD>
	media: autoselect
	status: **active**

but I can not ping 192.168.105.1

One the colima VM, I can see this:

lima0     Link encap:Ethernet  HWaddr 52:55:55:74:18:4D
          inet addr:192.168.105.2  Bcast:0.0.0.0  Mask:255.255.255.0
          inet6 addr: fdce:1812:ad25:915f:5055:55ff:fe74:184d/64 Scope:Global
          inet6 addr: fe80::5055:55ff:fe74:184d/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:158 errors:0 dropped:0 overruns:0 frame:0
          TX packets:14 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:42873 (41.8 KiB)  TX bytes:1720 (1.6 KiB)

and I can ping both 192.168.105.2 and 192.168.105.1

I'm not sure exactly what the next step would be in figuring out what bit is likely broken.

Pointers would be much appreciated.

@spkane
Copy link
Author

spkane commented Mar 1, 2022

I also posted this in lima-vm/vde_vmnet as I am not really sure where the issue lies. lima-vm/vde_vmnet#37

@spkane
Copy link
Author

spkane commented Mar 2, 2022

This is what I see in the logs:

$ cat shared_switch.stderr.log
/opt/vde/bin/vde_switch: EOF data port: Interrupted system call
/opt/vde/bin/vde_switch: Reading  data: Connection reset by peer

@abiosoft
Copy link
Contributor

abiosoft commented Mar 12, 2022

$ cat shared_switch.stderr.log
/opt/vde/bin/vde_switch: EOF data port: Interrupted system call
/opt/vde/bin/vde_switch: Reading  data: Connection reset by peer

I am noticing same behaviour, I get same error output when attempting to start vde_vmnet manually.
And the vde_vmnet output looks like a fatal error

Initializing vmnet.framework (mode 1001)
start(): vmnet_return_t VMNET_FAILURE
start: Undefined error: 0

@abiosoft
Copy link
Contributor

abiosoft commented Mar 12, 2022

I am noticing same behaviour, I get same error output when attempting to start vde_vmnet manually. And the vde_vmnet output looks like a fatal error

Initializing vmnet.framework (mode 1001)
start(): vmnet_return_t VMNET_FAILURE
start: Undefined error: 0

It is working fine for me again. I am still not sure how to reproduce this but I suspect it is related to network connections.

@spkane
Copy link
Author

spkane commented Mar 21, 2022

host and bridged networking seems to work fine, but shared is still exhibiting this issue consistently for me.

@alazycoder101
Copy link

It's still happening to me as well with M1 shared won't work. But it's working with bridged.

❯ sudo /opt/homebrew/Cellar/socket_vmnet/1.1.1/bin/socket_vmnet --pidfile=/private/var/run/lima/shared_socket_vmnet.pid --socket-group=everyone --vmnet-mode=shared --vmnet-gateway=192.168.105.1 --vmnet-dhcp-end=192.168.105.254 --vmnet-mask=255.255.255.0 /private/var/run/lima/socket_vmnet.shared
Initializing vmnet.framework (mode 1001)
start(): vmnet_return_t VMNET_FAILURE
start: No such process

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants