xshell为什么连接不上ubuntu---ould not connect to 'ip' (port 22): Connection failed.
来源:互联网 发布:淘宝上下架时间设置 编辑:程序博客网 时间:2024/05/22 11:36
换了电脑之后,很多环境都要重新搭建,今天我就碰到我的xshell连接不是上ubuntu的问题,分享给大家。
我用VM打开我的ubuntu之后,想用xshell连接,在windows环境下操作,毕竟这样比较方便,但是,当我使用xshell连接的时候总是发现会连接失败,如下图:
总是连接失败。
上网查了查原因:
1:可能没有开启22端口,之后上网找命令开启了22端口,命令如下:
iptables -A INPUT -p tcp -m tcp --sport 22 -j ACCEPT 发现还是无法连接,又开始在网上找资料。发现可能是没有开启ssh server,接下来就是开启服务就好。命令如下:
sudo apt-get install openssh-server
安装好ssh server之后尝试用xshell连接了一下,发现就可以连接上。如下图:
以上就是本人在学习过程中的一些经验总结。当然,本人能力有限,难免会有纰漏,希望大家可以指正。
本文出自 “做一个小小小司机” 博客,请务必保留此出处http://10799170.blog.51cto.com/10789170/1762175
0 0
- xshell为什么连接不上ubuntu---ould not connect to 'ip' (port 22): Connection failed.
- xshell为什么连接不上ubuntu---could not connect to 'ip' (port 22): Connection failed.
- XShell连接不了虚拟机linux Could not connect to '127.0.0.1' (port 22): Connection failed.
- 用xshell 连接服务器提示:Could not connect to '192.168.0.104' (port 22): Connection failed.
- Xshell远程连接Linux服务器出错——Could not connect to '114.214.166.5' (port 22): Connection failed.
- XShell连接不了(ubunt14.04)虚拟机Could not connect to ‘192.168.1.105’ (port 22): Connection failed
- Could not connect to '192.168.80.145' (port 22): Connection failed的解决办法(远程连不上xshell)
- Could not connect to '192.168.80.145' (port 22): Connection failed的解决办法(远程连不上xshell)
- Could not connect to '10.7.100.182' (port 22): Connection failed
- Could not connect to '127.0.0.1' (port 22): Connection failed.
- ssh 不能连接linux系统 Could not connect to '192.168.X.X'(port 22) Connection failed
- Could not connect to '192.168.1.188' (port 22): Connection failed.远程连接centos失败
- ubuntu能ping通却ssh不上(connect to localhost port 22: Connection refused)解决办法
- 用xshell5连接vmware10+centos6.7时报Could not connect to '192.168.54.100' (port 22): Connection failed的解法
- Xshell连接不上阿里云报错:connection failed的解决方案
- Could not connect to '10.203.87.140' (port 22): Connection faile
- MongoDB Failed to connect to <IP>:<port>, reason: errno:111 Connection refused
- ssh: connect to host xxx port 22: Connection refused -ubuntu
- 使用c语言编写程序:不允许创建第三方变量
- 顺序表和链表的模板
- 基础c++体系结构图解
- ubuntu下安装maven
- 栈面试题
- xshell为什么连接不上ubuntu---ould not connect to 'ip' (port 22): Connection failed.
- 两个栈实现一个队列
- 两个队列实现一个栈
- 广义表
- 大数运算
- HashTable
- 网络体系结构与网络协议
- Host ip is not allowed to connect to this MySQL server
- linux文件的三种时间