Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

6
  • Check the permissions on your password key file. Must be read only for user.
    – WilliamKF
    Commented May 13, 2015 at 19:43
  • thanks WilliamKF for the idea; did a chmod 400 * on both systems .ssh directory.. still the same behaviour
    – Raghav
    Commented May 13, 2015 at 19:47
  • The first command I run when I hit ssh issues: 'chmod 700 ~/.ssh && chmod 600 ~/.ssh/* && chmod 644 ~/.ssh/authorized_keys'. Note: ~ is the home dir of the user. If you're performing it for another user, replace ~ with '/home/username'. Commented May 13, 2015 at 19:50
  • Thanks for quick responses. @Alex - I followed your suggestion too, still the same behaviour :(
    – Raghav
    Commented May 13, 2015 at 19:57
  • Ensure your public key is in the authorized_keys file on the target machine. Ensure /etc/ssh/sshd_config has these settings: RSAAuthentication yes, PubkeyAuthentication yes, #AuthorizedKeysFile %h/.ssh/authorized_keys. I also have UsePAM to no, but that's not necessary. Commented May 13, 2015 at 20:14