Ubuntu安装使用SSH
2016-07-05 12:25
330 查看
Ubuntu安装使用SSH
ubuntu默认并没有安装ssh服务,如果通过ssh链接ubuntu,需要自己手动安装ssh-server。判断是否安装ssh服务,可以通过如下命令进行:
最后,应该是连接的时候了。可以用putty等ssh客户端连接。
ubuntu默认并没有安装ssh服务,如果通过ssh链接ubuntu,需要自己手动安装ssh-server。判断是否安装ssh服务,可以通过如下命令进行:
1.$ ssh localhost 2. ssh: connect to host localhost port 22: Connection refused 如上所示,表示没有还没有安装,可以通过apt安装,命令如下: 1. $ sudo apt-get install openssh-server 系统将自动进行安装,安装完成以后,先启动服务: 1. $ sudo /etc/init.d/ssh start 启动后,可以通过如下命令查看服务是否正确启动 1. $ ps -e|grep ssh 2. 29103 ? 00:00:00 sshd 如上表示启动ok。注意,ssh默认的端口是22,可以更改端口,更改后先stop, 然后start就可以了。改配置在/etc/ssh/sshd_config下,如下所示。 1. $ vi /etc/ssh/sshd_config 2. # Package generated configuration file 3. # See the sshd(8) manpage for details 4. # What ports, IPs and protocols we listen for 5. Port 22
最后,应该是连接的时候了。可以用putty等ssh客户端连接。
相关文章推荐
- Ubuntu 默认壁纸历代记
- Ubuntu Remix Cinnamon 20.04 评测:Ubuntu 与 Cinnamon 的完美融合
- 关于Ubuntu 11.10启动提示waiting for the network configuration的问题
- 在 Ubuntu 桌面中使用文件和文件夹
- Linux Generating SSH Keys
- ubuntu下chrome无法同步问题解决
- Ubuntu Linux使用体验
- 使用 GNOME 优化工具自定义 Linux 桌面的 10 种方法
- 以Ubuntu 9.04为例 将工作环境迁移到 Linux
- VirtualBox虚拟机XP与宿主机Ubuntu互访共享文件夹
- 从USB安装Ubuntu Server 10.04.3 图文详解
- Ubuntu 15.04 正式版发布下载
- Linux-Ubuntu 10.04安装Cadence-ic610 方法总结图解
- Ubuntu 12.04和Windows 7双系统安装图解
- Ubuntu /home下中文目录如何修改成英文?
- 开机出现:grub rescue的修复方法
- Ubuntu连接Android真机调试
- 你应该选择 Ubuntu 还是 Fedora?
- 100 个最佳 Ubuntu 应用(中)