Unable to ssh to my Ubuntu VM
Posted: 1. May 2015, 14:50
I'm having a difficult time getting my VM network setting setup correctly so I can ssh to it from my OS X host machine. I have OpenSSH Server installed and can connect to from within the VM. However, when trying to connect to it from the OS X Terminal Shell, no such luck. I've setup port forwarding on my network adapter as follows - . Is there something else I'm missing?
UPDATE: When I set the Network Adapter to Bridged, I can successfully ssh into the VM. Seems like it has something to do with the NAT and port forward. Ideally, I'd like to be able to connect to the VM(s) by hostname of the VM from a terminal session on my OS X environment. I did use this command to enable that without success. Seems like when the (NAT) port forwarding is resolved this will likely work as well. Thanks!
Code: Select all
vboxmanage modifyvm $VM_NAME --natpf1 "guestssh,tcp,,2222,,22"UPDATE: When I set the Network Adapter to Bridged, I can successfully ssh into the VM. Seems like it has something to do with the NAT and port forward. Ideally, I'd like to be able to connect to the VM(s) by hostname of the VM from a terminal session on my OS X environment. I did use this command to enable that without success.
Code: Select all
vboxmanage modifyvm $VM_NAME --natdnshostresolver1 on