Wednesday, January 11, 2017

Why can't I ssh into (or even ping) my Ubuntu VM from the Mac OS X host?



I'm running Ubuntu 8.04 as a virtual machine using VMware Fusion 3.0 on Mac OS X 10.5.8. I want to be able to ssh into my VM from the Mac OS X host (so I can use MacFUSE and SSHFS to mount the VM's files on the Mac).



I had this working previously, but then I:





  • upgraded Fusion from 2.x to 3.0

  • rolled the VM back to a previous snapshot

  • upgraded the VMware Tools in the VM



I re-installed ssh in the VM using sudo apt-get install ssh.



I then tried ssh 172.16.193.129 from my Mac, and after some time it timed out. So I tried pinging the VM from my Mac, and 0 packets were received. (I can ping the Mac from the VM with no problem.)




Any advice on how to troubleshoot this?



Update: I tried switching from NAT to Bridged (as suggested by Stephen Thompson) and got strange "Time to live exceeded" messages when I tried to ping the VM. I realized that was due to the VPN I'm using. I disconnected from the VPN and can now ping the VPN and ssh into it, regardless of whether I use NAT or Bridged.


Answer



Try setting your network to bridged, so it picks up a network address from your lan, and you will be able to gain access to it.


No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...