You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用SSH连接无法操作自有仓库:提示无法读取远程仓库

关于SSH密钥验证下Git仓库访问失败的问题

我尝试向仓库推送变更时持续遇到错误,甚至无法克隆仓库,使用SSH密钥进行身份验证。错误信息如下:

Cloning into 'MyRepoThatDefinitelyExists'...
ERROR: Repository not found.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

已完成的排查操作

  • ssh-agent 服务处于运行状态:
    PS C:\windows\system32> Get-Service ssh-agent | Select Status
    
     Status
     ------
    Running
    
  • 执行 ssh -T git@github.com 验证SSH身份认证成功:
    Hi DefinitelyMyUsername! You've successfully authenticated, but GitHub does not provide shell access.
    
  • 确认SSH密钥已添加至GitHub账户和ssh-agent中
  • 将仓库可见性改为公开后,可正常与仓库交互,但不清楚原因
  • 仍可将仓库添加为Git的远程仓库
  • 重新生成SSH密钥,问题未解决

完全不知道该如何解决

内容的提问来源于stack exchange,提问作者Beatrice Laplan

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.14 11:08:15