1. Download and install the SSH client to http://www.putty.org/
2. See if the SSH service is installed
In the Ubuntu Terminal Command interface type:
If the following prompt appears, it is not installed:
22
3. Installing the SSH Service
If you see no sshserver installed through the previous steps, type the following command to install:
#apt-get Install Openssh-server
4. Start SSH When the installation is complete
5. You can use the command after the boot is complete: ps–e | grep ssh to view the SSH status,
#2342xx:XX: + sshd
Indicates that the startup was successful.
6. Turn off the firewall
#ufw Disable
7.vbox Select Nat Mode
8. Virtual machine IP Select DHCP dynamic assignment:
#vi/etc/network/interfaces
At the end of the file add:
Auto eth0 iface eth0 inet DHCP
Thus, the virtual machine can share the network with the host
9. Do port mapping on the virtual machine
Select Network--Connect by Change network address translation (NAT), and then select Advanced--Port forwarding--to map port 22 of the virtual machine to either end, such as 2222
Other services can also do the same settings, 22 is the SSH service port.
10. Connect the virtual machine with the SSH client, ip:127.0.0.1, port 2222, connect successfully.
REF:
http://blog.csdn.net/jakiechen68/article/details/9796563
http://blog.csdn.net/crave_shy/article/details/23124895
Telnet to a virtual machine in VBox using the SSH service under Winows