首页 > 技术文章 > [Linux] Windows10下使用Putty连接Linux虚拟机

immjc 2017-09-02 16:01 原文

1. 首先在Linux虚拟机上安装ssh服务(以Ubuntu16.04 LTS为例)。

sudo apt-get install openssh-server

2. 测试ssh服务是否安装成功并且运行ssh

sudo /etc/init.d/ssh start

3. 查看Linux的IP地址(inet addr)

ifconfig 

4. 在虚拟机(以VirtualBox为例)设置网络

控制 -> 设置 -> 网络 -> 连接方式:桥接网卡 -> 界面名称:VirtualBox Host-Only (or物理机网卡) -> OK

5. 设置Putty

Host Name(or IP address): Linux中ifconfig下的inet addr

Port: 22

Connection type: SSH

6. 登陆SSH

Login as: root

Password: xxx

推荐阅读