I'm running Ubuntu in VirtualBox and I want to connect via SSH to Host (Windows 7). Is it possible? I need someone to explain me.

3 Answers 3


In order to connect via SSH from A to B you'll need a SSH server running in B. To connect to an Ubuntu machine, it's just a matter of installing openssh-server and make sure the service is started. For a Windows machine, you'll have to pick one of the third-party servers available and install it.

This question is a good starting point to select a Windows SSH server; Wikipedia also has a comparison of servers. OpenSSH for Windows, mentioned in @FatPopDoWop's answer, has not had a release in years AFAIK (last one in Sourceforge was in 2004). I've used freeSSHd in Win XP and it works well, but I can't say if it does in Win 7.

The server (your host) must be able to receive TCP connections in the SSH listening port (22 by default); check the Windows Firewall, as already mentioned.

The IP you have to connect to will depend on how the network is set up in the VM. For example, in a VM that's using NAT network mode, the host is reachable from the guest with the IP In any case, check that SSH is listening on the interface the client will use to connect. In NAT mode, the connections are made through localhost (at least in Linux; I suppose VirtualBox in Windows works that way too).


To connect to a Windows computer via ssh you need to install OpenSSH for Windows first. Once it's installed, you need to set up the config file so that your chosen Windows user(s) can log in via ssh. You will probably also need to add an exception to the Windows Firewall to allow port 22 incoming.

Find instructions and downloads here: http://sshwindows.sourceforge.net/

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .