git annex/ssh:ControlPath太长 [英] git annex / ssh : ControlPath too long

查看:80
本文介绍了git annex/ssh:ControlPath太长的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在运行命令:git annex sync时,出现以下错误:

when running the command : git annex sync, I get the following error:

ControlPath too long
Command ssh ["-S","<local path to git repo>/.git/annex/ssh/git@<git url>","-o","ControlMaster=auto","-o","ControlPersist=yes","git@<git url>","git-annex-shell 'configlist' '<local path to git repo>'"] failed; exit code 255

根据,问题不是git而是ssh(但在那里提出的解决方案无效).

according to this , the issue is not git but ssh (but the solution proposed there did not work).

有什么我可以避免的问题?

Anything I could to to avoid this issue ?

推荐答案

"-S","<local path to git repo>/.git/annex/ssh/git@<git url>"

此路径的长度不应超过92个字符,例如 unix(7)建议:

This path shouldn't be longer then 92 characters, as unix(7) proposes:

在编写可移植应用程序时,请记住一些 实现中的sun_path短至92个字节.

When coding portable applications, keep in mind that some implementations have sun_path as short as 92 bytes.

如果您知道自己深入目录结构并且路径将扩展此限制,则可以根据

If you know you dive too deep in the directory structure and the path will extend this limit, you can do one of these things, based on man git-anex in your .git/config:

  1. 使用annex.sshcaching=off完全关闭连接共享. 警告:这将大大增加执行所有操作所需的时间和资源!

  1. Turn off connection sharing completely using annex.sshcaching=off. Warning: This will significantly increase the time and resources that are required to do all operations!

使用annex.ssh-options="-S=~/.ssh/control-%l.%r@%h:%p" -oControlMaster=auto

这篇关于git annex/ssh:ControlPath太长的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆