How to remotely connect to Ubuntu in a virtual machine through SSH

Source: Internet
Author: User
Set the network connection mode to Bridge Mode in the Virtual Machine. manually set the network parameters in Ubuntu to the same network segment as windows, and ensure that the network can be pinged to each other. Run sudoapt-getinstallopenssh-server to start SSH-serversudo/etc/init. d/sshstartwindows and use the PuTTy software.

Set the network connection mode to Bridge Mode in the Virtual Machine. manually set the network parameters in Ubuntu to the same network segment as windows, and ensure that the network can be pinged to each other.

Install SSH-server

Run the following command on the terminal: sudo apt-get install openssh-server.

Start SSH-server

Sudo/etc/init. d/ssh start

In windows, use the software PuTTy, fill in the IP address of the Ubuntu you just set, and connect directly. Now let's have fun (of course, the virtual machine must be enabled first ).

Windows Linux operating tool putty-x86 (download)

P.S. Connection refused Error

If the following error occurs, it is likely that the ssh-server has not been installed:

Ssh: connect to host localhost port 22: Connection refused

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.