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.
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.
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 10.0.2.2. 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).