fatal: read error: Connection reset by peer解决办法

标签(空格分隔): ceph源码安装,git

问题描述:

源码安装ceph,克隆代码时提示如下错误:

[root@localhost ~]# git clone git://github.com/ceph/ceph
正克隆到 'ceph'...
fatal: read error: Connection reset by peer

解决办法:

首先确认是否可以访问外网:

[root@localhost ~]# ping www.baidu.com
PING www.a.shifen.com (14.215.177.38) 56(84) bytes of data.
64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=1 ttl=54 time=27.7 ms
64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=2 ttl=54 time=14.2 ms

如果可以访问外网,把 git: 修改为 http: 即可:

[root@localhost ~]# git clone http://github.com/ceph/ceph
正克隆到 'ceph'...
remote: Counting objects: 573631, done.
remote: Compressing objects: 100% (13/13), done.
...

参考文档:

fatal: read error: Connection reset by peer

点赞