Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights
第一次提交遇到这样的情况,怎么回事呢,我在github上提交了ssh key 的啊。
排查先看看能不能解析,
1.先 ping https://github.com
把ip添加到 host : sudo vi /etc/hosts (添加下面第三行)
127.0.0.1 localhost localhost.localdomain VM-0-6-ubuntu
127.0.1.1 TENCENT
192.30.255.113 github.com # 添加ip # The following lines are desirable for IPv6 capable hosts
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
192.30.255.113 github.com
~
2.如果不行的话看看自己有没有输入错误的创库地址
查看配置
cat .git/config
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[remote "origin"]
url = git@github:cuzz1/flask.git # 错误的
url = git@github.com:cuzz1/flask.git
fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
remote = origin
merge = refs/heads/master
3. 现在提交还出现
那就是github 上的ssh key 添加错了,我们用ssh-keygen -t rsa -C "xxxx@163.com" 会生成在很多目录下,比如root/.ssh、 /home/ubuntu/.ssh 都有ras_id.pub
所以我们不能添加错了。必须在 ~/.ssh目录下 才有用,要是当前目录,把 ~/.ssh/ras_id.pub 拷到github上就可以了。
现在提交就可以了。
感谢军哥的帮忙 ,微信公众号 Python之禅
Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights的更多相关文章
- github Permission denied (publickey). fatal: Could not read from remote repository.
github Permission denied (publickey).fatal: Could not read from remote repository. ----------------- ...
- 【git基础】Permission denied (publickey). fatal: Could not read from remote repository
运行以下git命令的时候出现错误 git push -u origin master error The authenticity of host 'github.com (13.250.177.22 ...
- git pull 出错 fatal: Could not read from remote repository.Please make sure you have the correct access rights.and the repository exists.
Warning: Permanently added the RSA host key for IP address '192.30.252.131' to the list of known hos ...
- github下载报错:Permission denied (publickey). fatal: Could not read from remote repository.
Permission denied (publickey). fatal: Could not read from remote repository. 博主在github上下载tiny face的的 ...
- Permission denied (publickey). fatal: Could not read from remote repository.
博主在github上下载tiny face的的源代码的时候,遇到git clone命令为:git clone --recursive git@github.com:peiyunh/tiny.git 而 ...
- Warning: Permanently added the RSA host key for IP address '192.30.253.113' to the list of known hosts. Permission denied (publickey). fatal: Could not read from remote repository. Please make sure y
这个应该是很多github新手经常出错的问题,这个就是没有在你github上添加一个公钥. 下面就直接说步骤: 1 可以用 ssh -T git@github.com去测试一下 图上可以明显看出缺少了 ...
- git克隆出错 github clone Permission denied (publickey) fatal Could not read from remote repo
原文网址:http://blog.csdn.net/feeling450/article/details/53067563 github clone "Permission denied ( ...
- Permission denied (publickey). fatal: The remote end hung up unexpectedly 解决办法
这两天学习git的时候,在本地创建了一个库,同时自己在GitHub上面也创建了一个库,照着廖老师的教程一步一步走到了push的环节突然出现了这样的错误: [zhangxiyu@localhost le ...
- SSH方式登录github出现Permission denied (publickey)
今天在公司上传了代码,回到家pull,结果竟然出现了“Permission denied (publickey)“这种东西.第一反应是key不对,可是上次明明用key登录过,不可能不对啊,难道是文件被 ...
随机推荐
- C# 6.0可能会支持模式匹配了
今天在CodePlex的Roslyn讨论区发现了一个帖子:Draft spec for records and pattern-matching in C#,估计MS计划在C# 6.0中支持模式匹配了 ...
- CASS 7.1 和 AutoCAD 2006的安装使用
CAD 2006由于是一个古老的版本,所以在WIN7,WIN10上直接安装的话,一般无法成功.此外,AutoCAD 2006是不分32位64位的,之后的版本都是区分的. 但是,对于我这种几年不用一次C ...
- OneThink框架的文章详情页分页
Application/Home/Controller/ArticleController.class.php的detail函数修改结果如下: /* 文档模型详情页 */public function ...
- win8 下脚本安装IIS
@echo off echo 正在添加IIS8.0 功能,依据不同的网络速率,全程大约需要5分钟时间... start /w pkgmgr /iu:IIS-WebServerRol ...
- Discuz! 7.1 & 7.2 远程代码执行漏洞
受影响产品: Discuz! 7.1 & 7.2 漏洞描述: 产生漏洞的$scriptlang数组在安装插件后已经初始化 Discuz!新版本7.1与7.2版本中的showmessage函数中 ...
- 一起來玩鳥 Starling Framework(3)Button!
週末夜來介紹個簡單的DisplayObject就好.不論是在電腦上或行動裝置上,跟使用者互動次數最多的,大概就是按鈕了.因此,Starling有個Button類別,來做出這個常用的互動元件. 同樣是因 ...
- 【AS3 Coder】任务四:噪音的魅力(中)
如果把Math.random方法作为一个生成随机数字的办法,那么bitmapData.perlinNoise就是一个生成随机颜色的办法.在这一部分的对于噪声的应用介绍文章中我们一起来看看使用柏林噪声的 ...
- Python测试Kafka集群(kafka-python)
生产者代码: import time from kafka import SimpleProducer, KafkaClient from kafka import KafkaProducer pro ...
- EffectiveJava(25)泛型和数组的使用取舍及规范
泛型和数组 泛型:1.泛型是不可变的.对于任意两个不同类型Type1,type2;List既不是List的子类型,也不是List的超类型 2.泛型是通过擦除来实现的.故泛型只在编译时强化它们的信息,并 ...
- jquery.cookie.js操作cookie实现“记住密码”,很简单很强大
//初始化页面时验证是否记住了密码 $(document).ready(function() { if ($.cookie("rmbUser") == "true&quo ...