Git Bash无法初始化

时间:2016-07-21 04:35:32

标签: git bash dll

enter image description here

当我使用git bash时,它说“无法分叉子进程:资源暂时不可用。可能需要DLL rebasing。请参阅'rebaseall --help'。” 我该如何解决这个问题?

当我使用tortoiseGit来存储时,我得到了一些像这样的消息

> git.exe stash save -- "12"

0 [main] sh (7224) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x12F0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
0 [main] sh 13140 fork: child -1 - forked process 7224 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
0 [main] sh (8240) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x1200400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
1036670 [main] sh 13140 fork: child -1 - forked process 8240 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (10380) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x12B0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
3174011 [main] sh 10992 fork: child -1 - forked process 10380 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (9232) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x1330400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
4240906 [main] sh 10992 fork: child -1 - forked process 9232 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
0 [main] sh (4164) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x13C0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
6274008 [main] sh 10992 fork: child -1 - forked process 4164 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (6172) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x1410400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
10341657 [main] sh 10992 fork: child -1 - forked process 6172 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (4008) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x13B0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
18409517 [main] sh 10992 fork: child -1 - forked process 4008 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: Resource temporarily unavailable
0 [main] sh (11752) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x1350400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
18455570 [main] sh 13140 fork: child -1 - forked process 11752 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (7824) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x1350400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
19501977 [main] sh 13140 fork: child -1 - forked process 7824 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (3708) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x13D0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
21578926 [main] sh 13140 fork: child -1 - forked process 3708 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (3908) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x11F0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
25643366 [main] sh 13140 fork: child -1 - forked process 3908 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: retry: No child processes
2 [main] sh (8904) D:\Program Files (x86)\Git\usr\bin\sh.exe: *** fatal error - cygheap base mismatch detected - 0x1360400/0x13F0400.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version.  The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.  Rebooting is also suggested if you
are unable to find another cygwin DLL.
33708123 [main] sh 13140 fork: child -1 - forked process 8904 died unexpectedly, retry 0, exit code 0xC0000142, errno 11
D:\Program Files (x86)\Git\mingw32/libexec/git-core\git-stash: fork: Resource temporarily unavailable

4 个答案:

答案 0 :(得分:21)

一天早上我遇到了同样的问题。我试图卸载Git只是为了看它是否已损坏,它指出我在任务管理器中关闭了几个类似sh.exe的进程。在我杀了它们之后,我能够成功打开Git bash。

干杯!

答案 1 :(得分:3)

这是修复。

  1. 转到Windows Defender安全中心设置
  2. 点击App&浏览器控制
  3. 点击底部的“漏洞利用保护设置”链接
  4. 转到“程序设置”,然后点击“添加要自定义的程序” - > “选择确切的文件路径”
  5. 导航至“C:\ Program Files \ Git \ usr \ bin \ sh.exe”并添加
  6. 覆盖并关闭以下内容:强制ASLR,随机化内存分配(自下而上ASLR)
  7. 点击“应用”,现在一切正常。
  8. 还要从同一文件夹添加这些其他二进制文件:expr.exe,uname.exe,grep.exe,rm.exe

    祝你好运,
    加布里埃尔

答案 2 :(得分:1)

尝试使用便携版Git for Windows 2.9.2

  • 在任意位置解压缩PortableGit-2.9.2-64-bit.7z.exe(例如D:\git\git2.9.2),
  • 从您的路径D:\Program Files (x86)\Git相关路径中删除
  • 添加到您的路径D:\git\git2.9.2;D:\git\git2.9.2\bin;D:\git\git2.9.2\cmd;D:\git\git2.9.2\usr\bin

然后,从CMD会议开始:

  • cd to a git repo
  • 输入bash -i --login并检查bash是否正常运行

答案 3 :(得分:0)

在我的情况下,因为 git bash 在重新启动我的机器之前正在工作解决了这个问题。

先尝试重启你的机器,希望它会修复它。