Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/git/23.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Git 吉特和;服务器中止了SSL握手";错误_Git_Ssl_Github_Ssh - Fatal编程技术网

Git 吉特和;服务器中止了SSL握手";错误

Git 吉特和;服务器中止了SSL握手";错误,git,ssl,github,ssh,Git,Ssl,Github,Ssh,通常,当我想要推送到我的私有回购时,会出现“服务器中止SSL握手”错误。经过几次尝试后,它通常会突然起作用。我还没能在互联网上找到解决办法 如果今天这还不够烦人的话,我想通过git clone安装torchhttps://github.com/torch/distro.git ~/torch——递归的 每次在public cutorch.git上都会失败 致命:无法访问'https://github.com/torch/cutorch.git/': 服务器中止了SSL握手致命:的克隆 'http

通常,当我想要推送到我的私有回购时,会出现“服务器中止SSL握手”错误。经过几次尝试后,它通常会突然起作用。我还没能在互联网上找到解决办法

如果今天这还不够烦人的话,我想通过git clone安装torchhttps://github.com/torch/distro.git ~/torch——递归的

每次在public cutorch.git上都会失败

致命:无法访问'https://github.com/torch/cutorch.git/': 服务器中止了SSL握手致命:的克隆 'https://github.com/torch/cutorch.git'插入子模块路径 “额外/剪切”失败

但是,当我自己执行这一行时,它运行良好:

git clone https://github.com/torch/cutorch.git/ extra/cutorch
现在我必须重新启动安装过程,该过程失败,因为文件夹已经存在。所以除非这是固定的,否则我没有手电筒

我安装了最新版本的git(2.8.1),并使用MacOS10.11.4

如何修复这个恼人的SSL握手错误

更新:可能是我的ISP造成的。我也经历过HTTPS和iTunes商店连接出现问题的阶段

git clone https://github.com/torch/distro.git ~/torch --recursive
我刚刚尝试过克隆(使用上面的命令),效果很好。我看到所有的子模块都只托管在github.com上。这可能是github.com端的SSL证书出现了一些临时问题

或者,如果对您有效,您可以尝试通过SSH克隆它

克隆的子模块:

Submodule 'exe/env' (https://github.com/torch/env.git) registered for path 'exe/env'
Submodule 'exe/luajit-rocks' (https://github.com/torch/luajit-rocks.git) registered for path 'exe/luajit-rocks'
Submodule 'exe/qtlua' (https://github.com/torch/qtlua.git) registered for path 'exe/qtlua'
Submodule 'exe/trepl' (https://github.com/torch/trepl.git) registered for path 'exe/trepl'
Submodule 'extra/argcheck' (https://github.com/torch/argcheck.git) registered for path 'extra/argcheck'
Submodule 'extra/audio' (https://github.com/soumith/lua---audio.git) registered for path 'extra/audio'
Submodule 'extra/cudnn' (https://github.com/soumith/cudnn.torch.git) registered for path 'extra/cudnn'
Submodule 'extra/cunn' (https://github.com/torch/cunn.git) registered for path 'extra/cunn'
Submodule 'extra/cunnx' (https://github.com/nicholas-leonard/cunnx.git) registered for path 'extra/cunnx'
Submodule 'extra/cutorch' (https://github.com/torch/cutorch.git) registered for path 'extra/cutorch'
Submodule 'extra/fftw3' (https://github.com/soumith/fftw3-ffi.git) registered for path 'extra/fftw3'
Submodule 'extra/graph' (https://github.com/torch/graph) registered for path 'extra/graph'
Submodule 'extra/graphicsmagick' (https://github.com/clementfarabet/graphicsmagick.git) registered for path 'extra/graphicsmagick'
Submodule 'extra/lua-cjson' (https://github.com/mpx/lua-cjson) registered for path 'extra/lua-cjson'
Submodule 'extra/luaffifb' (https://github.com/facebook/luaffifb) registered for path 'extra/luaffifb'
Submodule 'extra/luafilesystem' (https://github.com/keplerproject/luafilesystem.git) registered for path 'extra/luafilesystem'
Submodule 'extra/nn' (https://github.com/torch/nn.git) registered for path 'extra/nn'
Submodule 'extra/nngraph' (https://github.com/torch/nngraph) registered for path 'extra/nngraph'
Submodule 'extra/nnx' (https://github.com/clementfarabet/lua---nnx.git) registered for path 'extra/nnx'
Submodule 'extra/penlight' (https://github.com/stevedonovan/Penlight.git) registered for path 'extra/penlight'
Submodule 'extra/sdl2' (https://github.com/torch/sdl2-ffi.git) registered for path 'extra/sdl2'
Submodule 'extra/signal' (https://github.com/soumith/torch-signal.git) registered for path 'extra/signal'
Submodule 'extra/threads' (https://github.com/torch/threads-ffi.git) registered for path 'extra/threads'
Submodule 'pkg/cwrap' (https://github.com/torch/cwrap.git) registered for path 'pkg/cwrap'
Submodule 'pkg/dok' (https://github.com/torch/dok.git) registered for path 'pkg/dok'
Submodule 'pkg/gnuplot' (https://github.com/torch/gnuplot.git) registered for path 'pkg/gnuplot'
Submodule 'pkg/image' (https://github.com/torch/image.git) registered for path 'pkg/image'
Submodule 'pkg/optim' (https://github.com/torch/optim.git) registered for path 'pkg/optim'
Submodule 'pkg/paths' (https://github.com/torch/paths.git) registered for path 'pkg/paths'
Submodule 'pkg/qttorch' (https://github.com/torch/qttorch.git) registered for path 'pkg/qttorch'
Submodule 'pkg/sundown' (https://github.com/torch/sundown-ffi.git) registered for path 'pkg/sundown'
Submodule 'pkg/sys' (https://github.com/torch/sys.git) registered for path 'pkg/sys'
Submodule 'pkg/torch' (https://github.com/torch/torch7.git) registered for path 'pkg/torch'
Submodule 'pkg/xlua' (https://github.com/torch/xlua.git) registered for path 'pkg/xlua'
通常,当我想要推送到我的私有回购时,会出现“服务器中止SSL握手”错误。经过几次尝试后,它通常会突然起作用。我还无法在互联网上找到解决方案:(

这可能是您使用的不同ssl版本的问题

为了修复它,请生成一个新的ssl(
RSA
)证书,并使用此新证书更新您的GitHub帐户

以下是如何设置它:
  • 生成新的ssh密钥。*将-t设置为rsa,以避免将来的连接问题

    ssh-keygen -t rsa
    
  • 一旦在
    %HOME%/.ssh
    目录(windows:
    Users/.ssh
    )中生成了文件,打开它并复制
    .pub
    的内容


如何在GitHub帐户下设置ssh密钥?
  • 登录GitHub帐户
  • 单击右上角的牧场主(
    设置

  • 单击SSH密钥和GPG密钥
  • 单击
    新SSH密钥

  • 粘贴密钥并保存

注意
第一次设置open terminal并运行
git fetch
后,将测试密钥并将其添加到您的
已知主机文件中。

这可能会帮助您:

生成SSH密钥:


然后将它添加到您的git帐户:

通过更新到最新版本的MacOS(从Sierra到High Sierra)解决了这个问题。我猜有些过时的东西被更新了,它直接开始工作。也许今天有人来到这里,也经历了同样的事情。

我在克隆repo时遇到了这个问题, 在MacOSX环境中为此问题挣扎了几天。 我最近还更改了我的帐户密码

分享对我有效的解决方案: (对所有代理进行注释,仅对所需代理进行注释)

1) 如上所述安装了SSH密钥

2) 在文本板中打开具有代理配置的所有脚本并平铺它们。1) .bash_profile,2.gitconfig,3.npmrc 4.curlrc

3) 通过在前面添加#注释所有文件中的所有代理设置行

4) 对我来说,我正在从一个安全服务器上进行git克隆,因此我取消了.gitconfig文件中[https]代理行的注释


5) 再次执行克隆命令,提示输入用户名和密码,克隆成功。

适用于您,但不适用于我。这就是我寻求帮助的原因:)我不认为这是一个暂时的问题,因为我的推送问题已经困扰了好几个月了。用ssh替换https会给我“权限被拒绝(公钥)。致命:无法从远程存储库读取。”您是否尝试了git克隆git@github.com:torch/distro.git--recursive
?正如其他成员所建议的,您需要将SSH公钥添加到github.com帐户,然后重试。您好,您也可以尝试一下吗?1.登录到您的Github帐户2。转到设置->SSH和GPG密钥3。删除旧的或未使用的密钥。另外,我看到github.com也面临一些问题:不错的指南,但是关于git fetch:“服务器中止了SSL握手”,我做了很多修改,今天它成功了。也许这不是解决方案,但它仍然有助于因此标记为可接受的答案。可能只是github端出现了一些问题。在设置ssh密钥之后,您需要从https切换到ssh。我在bitbucket repo上执行git fetch upstream命令时出错。但正如你提到的,第二次尝试时,它没有做任何事情就神奇地工作了。对我来说,这是一个暂时的问题。大约2分钟后,我又试着推了一下,效果很好。OP可能不是这样,但对于一些来这里查看此错误消息的人来说,值得一试。对我来说,我所需要做的就是重新启动Mac。很明显,一些储藏室把工作弄脏了。