使用ganymed-ssh2连接linux报错Cannot negotiate, proposals do not match.

Posted 规格严格-功夫到家-哈工大威海人

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了使用ganymed-ssh2连接linux报错Cannot negotiate, proposals do not match.相关的知识,希望对你有一定的参考价值。

    • Description

      HostAgent fails to establish SSH Connection to RedHat EL7 host

      The error reported when the agent attempts to connect to the host matches the message in KB article 227808, but the hmac-sha1 MAC algorithm is listed in the sshd_config file on the monitored host.
       

      The following error is reported :

      2017-12-12 17:46:42.369 VERBOSE [HostActivitiesCreator[12]-0] com.quest.glue.core.remoteconnection.ssh.SSHConnectionServiceImpl - Connecting to XX.X.XX.XX:22 using RSA public key authentication
      2017-12-12 17:46:42.458 WARN [HostActivitiesCreator[12]-0] com.dell.foglight.infrastructure.services.disk.UnixPlatformDiskExclusionService - Unable to determine hostname from common topology; only using hostname "XX.X.XX.XX" provided by properties.
      com.quest.glue.api.services.RemoteConnectionException: A connection could not be established to XX.X.XX.XX
      ...
      Caused by: com.quest.glue.api.services.ConnectionRefusedException: The remote machine is visible but has refused the connection
      ...
      Caused by: java.io.IOException: Key exchange was not finished, connection is closed.
      ...
      Caused by: java.io.IOException: Cannot negotiate, proposals do not match.
    • Cause

      The diffie-hellman-group-exchange-sha1 key exchange algorithm was not enabled for the monitored host.
    • Resolution

      RESOLUTION:  Check whether the diffie-hellman-group-exchange-sha1 key exchange algorithm is enabled on the host.  On a Linux host the "sshd -T | grep kex" command can be executed to list the enabled key exchange algorithms.  If the diffie-hellman-group-exchange-sha1 key exchange algorithm is not enabled following are two options:



      - Enable the diffie-hellman-group-exchange-sha1 key exchange algorithm on the monitored host.

 
 
https://blog.csdn.net/itkool/article/details/79460408

以上是关于使用ganymed-ssh2连接linux报错Cannot negotiate, proposals do not match.的主要内容,如果未能解决你的问题,请参考以下文章

Java连接Linux服务器

Java利用 ganymed-ssh2-build.jar来上传文件到linux以及下载linux文件以及执行linux shell命令

CA agent客户端安装完成后开启报错

jedis远程连接linux报错

java使用ssh远程操作linux 提交spark jar

linux下安装rabbitmq报错