Skip to main content

ssh connection error

Comments

4 comments

  • cPRex Jurassic Moderator

    Hey there!  The error is telling you a specific line in the SSH configuration file that is causing the issue.  Normally I wouldn't expect all of those things to show up in that file, so you may want to just try commenting it out, saving the file, and then restarting the SSH service to see if that takes care of things, as it that text may have been accidentally placed there by mistake.

    0
  • MilesWeb

    Hey, said,

    It seems you are trying to add the Cipher fields in the sshd_config file due to an invalid format it is giving an error.

    This could be because in some Linux versions, the KexAlgorithms and Cypher variables that indicate which techniques the SSH daemon supports are missing from /etc/ssh/sshd.conf. Please try including this in the config file

    Code:
    KexAlgorithms diffie-hellman-group1-sha1,curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1
    Ciphers 3des-cbc,blowfish-cbc,aes128-cbc,aes128-ctr,aes256-ctr

    After saving, regenerate the keys:

    Code:
    "ssh-keygen -A"

    Then restart the SSH service.



    0
  • Said

    sorry for the delay in my reply. 

    i try both ways commenting out the line and restarting and nothing happen 

    and including the new code  and regenerating the keys and nothing yet. 

    but i notice some extra information when i check the status and is this: 

    sshd.service: main process exited, code=exited, status=255/n/a

    line 274: Subsystem 'sftp' already defined. 

    Failed to start OpenSSH server daemon.

    Unit sshd.service entered failed state.

    sshd.service failed

     

    0
  • cPRex Jurassic Moderator

    Do you have two entries for the sftp server?  You should only have one line that looks like this:

    Subsystem       sftp    /usr/libexec/openssh/sftp-server

    and that error message seems to indicate there is a duplicate of that line, or something similar, on your configuration file.

    0

Please sign in to leave a comment.