hg git拉力导致太多的打开文件错误



我有一个跟踪Git存储库的Mercurial存储库。它在Windows 10上运行正常。现在,我将其作为目录将其移至Mac,然后运行hg reset -Ca只是为了清理它。现在,我正在尝试运行hg pull,这会导致这样的错误:

% hg --traceback --verbose pull                                                                                                255 ↵
pulling from git+https://someserver/somerepo.git
Traceback (most recent call last):
  File "/Users/user/.pyenv/versions/2.7.14/lib/python2.7/site-packages/mercurial/scmutil.py", line 154, in callcatch
  File "/Users/user/.pyenv/versions/2.7.14/lib/python2.7/site-packages/mercurial/dispatch.py", line 314, in _runcatchfunc
.....
  File "/Users/user/.pyenv/versions/2.7.14/lib/python2.7/site-packages/dulwich/pack.py", line 1004, in __init__
  File "/Users/user/.pyenv/versions/2.7.14/lib/python2.7/site-packages/dulwich/file.py", line 90, in GitFile
IOError: [Errno 24] Too many open files: '/Users/user/Projects/somerepo/.hg/git/objects/pack/pack-c03bf69ae597535d876f0dd30ddd6458f2c3f1ff.pack'
abort: Too many open files: /Users/user/Projects/somerepo/.hg/git/objects/pack/pack-c03bf69ae597535d876f0dd30ddd6458f2c3f1ff.pack

我检查了,看来我有hg-gitdulwich

的最新版本
dulwich (0.18.6)
hg-git (0.8.10)

Mercurial也是最新的

% hg --version 
Mercurial Distributed SCM (version 4.5)

我在Windows上检查了Mercurial的版本,如果很重要,则为4.4.2。我想知道是否有人遇到过这样的问题,也许可以解决或修复。

ulimit -n在您的Mac上怎么说?这是开放文件数量的限制。然后尝试以比以前更大的N运行ulimit -n N,然后再次运行HG命令。

您可能需要将ulimit -n N命令放入~/.bashrc中,每次登录时运行它,如果您有一个问题不仅仅是一个问题。

最新更新