工作需要,连接几台外网的服务器.由于移动的网络直连,经常会连不上,所以想通过本地的sock5代理连接.

神奇的事情发送了,通过sock5代理,有几台主机可以连上,有几天报上面的错误.

经过反复测试,外网的服务器只要用默认的22端口,无法通过sock5连接,但国内的没问题.

不知道是不是国内的fhw问题,还是其它的问题.

最后是一个ms主机的修改ssh端口的报错:

参考解决方式:https://www.thegeekdiary.com/error-bind-to-port-2222-on-0-0-0-0-failed-permission-denied-error-while-starting-sshd-service-on-centos-rhel/

主要是ms主机内置的semanage进程的监控

# semanage port -l | grep ssh
ssh_port_t tcp 22

2. Configure SELinux to allow sshd to utilize additional port 2222.
semanage port -a -t ssh_port_t -p tcp 2222

3. Verify new SELinux permitted sshd listen ports.
# semanage port -l | grep ssh
ssh_port_t tcp 2222,22

ssh通过sock5的问题kex_exchange_identification: Connection closed by remote host的更多相关文章

  1. 【Ansible】SSH Error: ssh_exchange_identification: Connection closed by remote host

    ansible ssh到目标机器 时好时坏,报错:  SSH Error: ssh_exchange_identification: Connection closed by remote host ...

  2. ssh问题:ssh_exchange_identification: Connection closed by remote host

    ssh问题:ssh_exchange_identification: Connection closed by remote host... 刚刚一个朋友告诉我SSH连接不上服务器了,重启电脑也不管用 ...

  3. sftp修改用户home目录后登录时报connection closed by remote host

    在sftp用户需要修改登录根目录的情况下,我们可以修改/etc/ssh/sshd_config文件中ChrootDirectory /home/[path]的路径. 但是,在重启sshd服务后,sft ...

  4. ssh_exchange_identification: Connection closed by remote host

    用服务器内网ip连接同子网服务器的时候显示ssh_exchange_identification: Connection closed by remote host 防火墙什么都关闭了,还是显示这个问 ...

  5. ssh 连接不上报Connection closed by remote host

    解决办法 (1)查看这两个文件是否有阻止cat /etc/hosts.deny cat /etc/hosts.allow (2)客户端连接数过多修改/etc/ssh/sshd_config中#MaxS ...

  6. ssh连接提示 "Connection closed by remote host"

    如果原来是可以用ssh连接的, 突然连接不上通常是连接数过多导致的. 解决方法一. 把SSH连接数改大 修改服务器上的这个文件:/etc/ssh/sshd_config 找到这行: # MaxSess ...

  7. 解决 SSH Connection closed by foreign host 问题

    Xshell 报错 : 1.有可能是IP和别人冲突,改一下IP就好了 2.也有可能是文件权限的问题.改一下: cd /etc/ssh/ chmod ssh_host_* chmod *.pub 3.也 ...

  8. XShell提示Connection closed by foreign host的问题 和 路由器分配IP的规则

    情况是这样的: VMware中有三个Linux机器分别是crxy99(192.168.1.99),crxy100(192.168.1.100),crxy101(192.168.1.101),crxy1 ...

  9. Escape character is '^]'. Connection closed by foreign host.

    今天在用易汇金的接口回调时候,老是回调不到我的机器上面.我的ip通过公网映射,按说是可以访问到我的ip,思考是什么问题. 1.防火墙关闭,不行 2.防火墙开启,但是把自己的端口号改为可以访问(参考:h ...

  10. 关于xshell:Connection closed by foreign host

    因为原来系统网有时掉,有时卡(同局域网别人没事),重新做了系统. 装了xmanager3,在用xshell连接linux服务器时,提示:服务器发送了一个无效的密钥,然后输出:Connection cl ...

随机推荐

  1. 修改python下载镜像源

    找到pip.ini(可能在"C:\Users\Administrator\AppData\Roaming\pip\pip.ini")→记事本打开→添加相应源 如果没有找到,在C:\ ...

  2. 【当年笔记】集合之Map

    Map 常用的实现类如下: Hashtable :Java 早期hash类,线程安全,不支持 null 键和值,因为它的性能不如 ConcurrentHashMap,所以基本不用. HashMap : ...

  3. webpack和source map

    当 webpack 打包源代码时,可能会很难追踪到 error(错误) 和 warning(警告) 在源代码中的原始位置. 如果打包后代码有一处错误,特别是使用的vue.react这些前端框架.打包后 ...

  4. springcloud(三) - 负载均衡Ribbon

    功能介绍 基本保证每个服务不同的ip接收到的请求数量是一样的,确保在微服务下没有没有那个服务器负载过多而另外一个闲置. IRule:根据规则获取制定的服务 规则列表 RoundRobinRule:轮询 ...

  5. rt_raster_to_gdal: Could not load the output GDAL driver

    问题记录:postgis 安装后不能执行以下语句,查询入库的 tif 文件 SELECT ST_AsGDALRaster(rast, 'GTiff') As rastjpg FROM radar_da ...

  6. js 自定義event

    <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> ...

  7. 12-K8S之调度器、预选策略和优选函数

    目录 调度器.预选策略和优选函数 1.nodeSelector nodeName调度: 2.节点亲和性调度(pod亲和于node节点) 3.pod亲和度调度(pod亲和于pod) 4.pod反亲和性度 ...

  8. OSPF的安全认证

    OSPF的安全认证 OSPF通过LSA报文同步状态信息,协议根据LSA提供的状态信息,快速实行全网路由的建立.也就是一通百通,一变则变.坏处就是有人搞破坏,一坏则百坏.为防止网络破坏活动,实行认证(明 ...

  9. 【git】git子模块操作-添加子模块与克隆子模块

    https://git-scm.com/book/zh/v2/Git-%E5%B7%A5%E5%85%B7-%E5%AD%90%E6%A8%A1%E5%9D%97 git submodule upda ...

  10. sqoop mysql2hive

    a./etc/profile添加export HADOOP_CLASSPATH=$HADOOP_CLASSPATH:$HIVE_HOME/lib/*b.将hive-site.xml 拷贝到 $SQOO ...