git错误--ssh: Could not resolve hostname ssh.github.com: Name or service not known--解决方式
错误如下:
git push origin
ssh: Could not resolve hostname ssh.github.com: Name or service not known
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
make: * [deploy] 错误 128
解决方式1:
step1. ping github.com
获取到github.com的ip为192.30.252.128
step2. 在/etc/hosts中添加一行如下:
192.30.252.128 github.com
解决方式2:
以root权限执行如下python代码
#!/usr/bin/python
#coding=utf8
import socket
host = 'github.com'
try:
with open('/etc/hosts', 'a+') as fp:
ip = socket.gethostbyname(host)
fp.write(' '.join([ip, host, '\n']))
except BaseException as e:
print(e)
else:
print('sucess')
git错误--ssh: Could not resolve hostname ssh.github.com: Name or service not known--解决方式的更多相关文章
- git提示错误关于错误:ssh: Could not resolve hostname github.com: Name or service not known.fatal: Could not read from remote repository.
关于 Git 使用中出现的错误 饥人谷_楠柒 关注 2016.11.02 15:33* 字数 746 阅读 3607评论 5喜欢 10赞赏 1 关于错误:ssh: Could not resolve ...
- ssh: Could not resolve hostname git.*****-inc.com : Temporary failure in name resolution fatal: The remote end hung up unexpectedly
问题出现的情景:使用git pull拉取开发的代码到测试服务器,报错: ssh: Could not resolve hostname git.****-inc.com : Temporary fai ...
- ssh: Could not resolve hostname gitcafe.com: nodename nor servname provided, or not known
今天 git push 的时候报如下错误: ssh: Could not resolve hostname gitcafe.com: nodename nor servname provided, o ...
- ssh: Could not resolve hostname github.com: Name or service not known
问题描述 今天早上在自己的虚拟机上用git pull命令更新github上的版本库时提示下面的错误 [root@localhost ~] git clone git@github.com:sdscbr ...
- hadoop启动时,报ssh: Could not resolve hostname xxx: Name or service not known
本文转载自:http://blog.csdn.net/wodewutai17quiet/article/details/76795951 问题:hadoop启动时,报ssh: Could not re ...
- ssh: Could not resolve hostname问题终于解决了?
1.如果系统为64位,无法启动启动hdfs: ./sbin/start-dfs.sh.并有以下错误: sed: -e expression #1, char 6: unknown option to ...
- hadoop启动报错:localhost: ssh: Could not resolve hostname localhost
hadoop启动journalnode时报错:localhost: ssh: Could not resolve hostname localhost: Temporary failure in na ...
- linux-解决/usr/bin/which: no ssh-copy-id in 和ssh: Could not resolve hostname问题
使用yum install openssh-clients 安装命令 有的系统没有此命令 有的系统缺省 就包含这一条命令! 但是我的测试机没有发现此命令 只能这样安装! 这时有报错了 1 2 [ro ...
- Xcode中git的用法介绍与"Please tell me who you are"问题的解决方式
我在之前多篇博客中解说了怎样使用命令行操作git,能够大大提高我们的工作效率.详细能够參考<Git学习札记><Git学习札记--进阶>等文章.事实上对于同一个工具,我们有不同的 ...
随机推荐
- 高淇java300集异常机制作业
1.以下关于异常的代码的执行结果是(C ).(选择一项) 1 2 3 4 5 6 7 8 9 10 11 12 public class Test { public static void m ...
- 如何用RSS订阅?
本文由云+社区发表 摘要:我们常常会有订阅别人文章的需求,有更新的时候希望能有提醒的功能,RSS就是这样一个订阅的方式.很多网站上看到RSS的入口,点进去以后总是显示一堆的XML代码,我们来看看怎么使 ...
- 20171201 - macOS High Sierra 神级 bug
昨日亲测有效,macOS High Sierra 神级 bug,系统管理员 root 密码为空,输入就可以登录,具备最高权限. 让人不禁想象 Apple Software 怎么了,人才都流失了吗?
- Python算法与数据结构--求所有子数组的和的最大值
Python算法与数据结构--求所有子数组的和的最大值 玄魂工作室-玄魂 玄魂工作室秘书 玄魂工作室 昨天 题目:输入一个整形数组,数组里有正数也有负数.数组中连续的一个或多个整数组成一个子数组,每个 ...
- C#操作剪切板(Clipboard)
剪切板是Windows系统提供的功能,从我最早接触到的Windows 3.2版本开始,就一直带着了.以前使用C++的时候,是直接使用Windows API对其进行操作的,到了.NET下,在WinFor ...
- 三种方式实现观察者模式 及 Spring中的事件编程模型
观察者模式可以说是众多设计模式中,最容易理解的设计模式之一了,观察者模式在Spring中也随处可见,面试的时候,面试官可能会问,嘿,你既然读过Spring源码,那你说说Spring中运用的设计模式吧, ...
- Nginx执行阶段
Nginx 介绍 Nginx (engine x) 是一个高性能的HTTP和反向代理服务器,也是一个IMAP/POP3/SMTP服务器. Nginx是一款轻量级的Web 服务器/反向代理服务器及电子邮 ...
- Python基础(数字,字符串方法)
数字: #二进制转十进制 a=' v=int(a,base=2) print(v) 进制转换 #当前数字的二进制至少有多少位 b=2 v2=b.bit_length() print(v2) 数值二进制 ...
- 6.Flask-WTForms
Flask-WTF是简化了WTForms操作的一个第三方库.WTForms表单的两个主要功能是验证用户提交数据的合法性以及渲染模板.还有其它一些功能:CSRF保护, 文件上传等.安装方法:pip in ...
- qml demo分析(photosurface-图片涅拉)
阅读qml示例代码已有一小段时间,也陆续的写了一些自己关于qml示例代码的理解,可能由于自己没有大量的qml开发经验,总感觉复杂的ui交互qml处理起来可能会比较棘手,但事实总是会出人意料,今天我们就 ...