Computer receives ping but doesn't respond
Also posted on SuperUser StackExchange.
I found multiple similar questions but none of them helped me.
I have a home network with 2 machines connected to the wifi router. Ping from A to B fails on timeout. tcpdump shows that machine B does see the incoming requests. Ping from B to A works. Both machines run on Mac OS, firewalls disabled, tried connecting them using my Android phone's hotspot wifi with the same result.
I want to connect my laptop (MacBook) to the stationary PC (mac mini) via remote desktop.
This forum has a limit of 5000 characters, so I had to cut out some stuff.
Router
IP = 192.168.1.1
Macbook
IP = 192.168.1.231
Firewall: off
ping works on: localhost, 127.0.0.1, 192.168.1.1 (router), 192.168.1.231 (itself)
ping timeouts on: 192.168.1.185 (mac mini)
nslookup sams-mac-mini successfully resolves to 192.168.1.185
ifconfig: see SuperUser post
netstat -rn (routing table): see SuperUser post
Mac Mini
IP = 192.168.1.185
Firewall: off
ping works on: localhost, 127.0.0.1, 192.168.1.1 (router), 192.168.1.185 (itself), 192.168.1.231 (MacBook)
nslookup sams-mbp successfully resolves to 192.168.1.231
Note: I do have a VPN installed but it's not connected/used at the moment, so you might see something here related to that.
ifconfig: see SuperUser post
netstat -rn:
Routing tables
Internet:
Destination Gateway Flags Netif Expire
default 192.168.1.1 UGSc en1
127 127.0.0.1 UCS lo0
127.0.0.1 127.0.0.1 UH lo0
169.254 link#7 UCS en1 !
192.168.1 link#7 UCS en1 !
192.168.1.1/32 link#7 UCS en1 !
192.168.1.1 20:1f:31:aa:e5:90 UHLWIir en1 1196
192.168.1.185/32 link#7 UCS en1 !
192.168.1.255 ff:ff:ff:ff:ff:ff UHLWbI en1 !
... see SuperUser post
Tests
Listen for ping requests on mac mini
- Run tcpdump -v host 192.168.1.231 on mac mini
- Run ping -c 4 192.168.1.185 on MacBook
- Mac mini output: see SuperUser post
MacBook got no responses, all 4 requests timed out but as you can see mac mini got all requests and seems to even respond to ARP but ICMP is left without a response.
Disabling IPv6
This gave me an idea it may be caused by Ipv6 so I ran networksetup -setv6off Wi-Fi on both machines which caused no changes, so I enabled it back.
Setting a manual IP for mac mini
This suggests that if I set the IP of mac mini to something else in the DHCP pool it may do something but it didn't (I tried 192.168.1.230 and 192.168.1.232), so I put auto address back.
Disable other network interfaces
Reverse Path Filter seems extremely close to what I have but it's about Linux and Mac OS treats this differently. I didn't spend much time on this but I thought it's related to the machine being confused with network interfaces, so I disabled all of them except the 192.168.* on the mac mini but it didn't fix the problem.
Try a different router
I tried connecting the MacBook and the Mac Mini to my android phone's wifi hotspot but the situation is the same.
Hopefully, we can find a solution and it will even help somebody else in the future.
Mac mini, macOS 10.15