git@github.com:Permission denied(publickey).fatal: Could not read form remote repository错误
文章目录
- 前言
- 问题分析
- 解决方法
- 配置客户端
- 配置服务端
- 验证
前言
在使用goland从github下载依赖时(git clone github.com/gin-gonic/gin)出现git@github.com:Permission denied(publickey).fatal: Could not read form remote repository
错误。
问题分析
Permission denied(publickey):没有权限
说明github和本地git没有生成ssh key或者ssh key不匹配
解决方法
配置客户端
- 客户端(本文为windows10电脑),打开git bash,执行
ssh-keygen -t rsa -C "github登录邮箱"
然后一路回车(不用输入)。 - 在git bash执行
ssh -v git@github.com
出现下方文字No more authentication methods to try. Permission denied(publickey)
如图:
- 在git bash执行
ssh-agent -s
,如图
- 在git bash执行
ssh-add ~/.ssh/id_rsa
,如图
出现Could not open a connection to your authentication agent
警告
在git bash执行ssh-agent bash
命令,然后再次执行ssh-add ~/.ssh/id_rsa
Identity added: /c/Users/zhandongyang/.ssh/id_rsa
,这是ssh key文件在windows电脑上的位置,用记事本打开这个路径上的id_rsa.pub
文件,复制里面的内容。
配置服务端
- 本文的服务端为github,访问github网站、登录,点击右上角的头像,然后点击Settings
- 选择SSH and GPG keys,选择New SSH key
Title写个自己记得住的名字,Key填写复制的id_rsa.pub文件内容
验证
在客户端(本文为windows10电脑)的git bash执行ssh -T git@github.com
至此结束。
git@github.com:Permission denied(publickey).fatal: Could not read form remote repository错误相关推荐
- 解决git@github.com: Permission denied (publickey). fatal: Could not read from remote repository. Pleas
今天用idea提交代码到github上,push后报错 git@github.com: Permission denied (publickey). fatal: Could not read fro ...
- gitHub报错之git@github.com: Permission denied (publickey). fatal: Could not read from remote repository
前言 当我们在新的电脑环境,本地上传到自己的github储存仓库就会出现时密钥不匹配,被拒绝上传. 第一句 git@github.com: Permission denied (publickey). ...
- git@github.com: Permission denied (publickey). fatal: Could not read from remote repository.
在使用git拉取文件时说没有权限,错误如下图所示.错误原因是没有进行SSH密钥是设置. 解决方法:(linux环境下),其他环境请转到它的主页面. 1.检测是否存在ssh keys ls -al ~/ ...
- MAC电脑gitt@github.com: Permission denied (publickey). fatal: Could not read from remote repository
本地上传代码时,执行命令:git push -u origin master遇到下面错误提示 gitt@github.com: Permission denied (publickey). fatal ...
- 报错git@gitee.com: Permission denied (publickey). fatal: Could not read from remote repository
报错如下: git@gitee.com: Permission denied (publickey). fatal: Could not read from remote repository. Pl ...
- mac下git使用ssh时候的一个小问题:Permission denied (publickey). fatal: Could not read from remote repository.
换了新电脑,配置了git的ssh keys之后就没怎么动过了,反正配置轻车熟路,就没有测试过. 今天更新一个项目的时候,怎么都更新不了,提示如下: > git clone git@github. ...
- git clone报错:Permission denied (publickey). fatal: Could not read from remote repository...
原文:git clone报错:Permission denied (publickey). fatal: Could not read from remote repository- 今天clone一 ...
- 解决方案:stderr: Permission denied (publickey). fatal: Could not read from remote repository
问题背景 代码托管在阿里云Code, Centos7 服务器上部署了Jenkins . 执行完不设置交换秘密生成SSH密钥对: ssh-keygen -t rsa -C "fairy_xin ...
- Permission denied (publickey). fatal: Could not read from remote repository.
博主在github上下载tiny face的的源代码的时候,遇到git clone命令为:git clone --recursive git@github.com:peiyunh/tiny.git 而 ...
最新文章
- php 网站内容采集器 Snoopy
- 编程之美 3.10 分层遍历二叉树
- python3爬虫入门教程-python3爬虫入门程序
- (chap7 确保WEB安全的HTTPS) HTTPS和SSL
- DotNetTextBox V2.0 Web Control(ASP.NET2.0 增强型TextBox控件,完全支持AJAX.NET)
- KlayGE的Virtual Texturing技术定名
- Label 表达式绑定
- 一道有意思的导论问题
- Confluence部署攻略 [转]
- 黑客编程为什么首选Python语言?这个高速你答案!
- 云资源中的低成本战斗机——竞价实例,AWS、阿里云等六家云厂商完全用户使用指南
- ios动态创建类Class
- 发票专用驱动sjz_税务局紧急提醒!10月31日前,不能领票,不能勾选!11月1日后,发票开具将大不同!...
- Rasterio入门
- Mezzanine 修改默认主页
- 蚂蚁金服区块链已开出近60万张医疗电子票据,市民报销看病更方便!
- Python-玩转数据-python网络编程
- 容齐的身世_白发王妃漫夭和容齐是什么关系 女主容乐跟谁睡过遭扒可怜容齐...
- 【Linux】页表的深入分析
- bat脚本实现监控进程功能-自动重启
热门文章
- open×××+Mysql+PAM构建强大的***系统
- oracle函数trunc的使用
- 华为手机应用鸿蒙os,华为手机内置应用逐渐向鸿蒙 OS 靠拢
- wdm设备驱动程序开发pdf_DWDM是什么 DWDM相关设备功能介绍【图文】
- java快捷键禁用_pycharm 掌握这些快捷键,你就是大神!!
- java 数据库连接 释放_java - 数据库连接池耗尽 - Java - 堆栈内存溢出
- 魅族15系统是android,魅族15系列评测:性能够用王者荣耀优化
- eclipse中tomcat服务器locations不能修改,解决eclipse中Tomcat服务器的server location选项不能修改的问题...
- LTNS的完整形式是什么?
- python日历模块_Python日历模块| prmonth()方法与示例