【问题标题】:Issue with SSH key setup while setting up github设置 github 时 SSH 密钥设置问题
【发布时间】:2012-06-07 07:03:57
【问题描述】:

我按照this教程在github上生成SSH密钥: 在上述链接教程的第 5 步,在我输入 ssh -T git@github.com 后,我应该会看到:

The authenticity of host 'github.com (207.97.227.239)' can't be established.
# RSA key fingerprint is 16:27:ac:a5:76:28:2d:36:63:1b:56:4d:eb:df:a6:48.
# Are you sure you want to continue connecting (yes/no)?

然而,我看到了这个:

Agent admitted failure to sign using the key.
Permission denied (publickey).

然后当我尝试使用 git push -u origin master 将文件推送到存储库时,我得到了这个:

Agent admitted failure to sign using the key.
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

我认为问题在于 SSH 密钥的设置。 我该如何解决这个问题?

我正在使用 Linux。

【问题讨论】:

  • 您是否在账户设置-> SSH Key中输入了SSH密钥,请确保您没有修改
  • 你用的是哪个操作系统??
  • @NixitPatel 我在 Linux - Ubuntu 12.04
  • @NixitPatel 是的,我已经输入了 SSH 密钥到帐户。并且这两个密钥(我的计算机和我的帐户中的一个)匹配。
  • 您可能已经检查过了,但请确保您的公钥具有完全权限。或者您可以做的其他事情是删除现有密钥并尝试重新生成它。

标签: git version-control github ssh-keys permission-denied


【解决方案1】:

谷歌搜索后,我发现最有可能的是您的密钥已损坏。

你可以尝试的事情是......

ssh-add也是解决了很多人的问题ssh-add ~/.ssh/id_rsa

尝试注销并登录 或

还有一些你可以尝试的东西http://sampathm.blogspot.in/2011/06/agent-admitted-failure-to-sign-using.htmlSSH cannot authenticate to git@github.com 希望对您有所帮助

【讨论】:

  • 重启电脑似乎可以解决问题!感谢您的帮助!
猜你喜欢
  • 1970-01-01
  • 2014-11-30
  • 1970-01-01
  • 2023-03-07
  • 2010-10-10
  • 1970-01-01
  • 2020-03-01
  • 1970-01-01
  • 2019-09-04
相关资源
最近更新 更多