31

Started recently, basically every time I try to fetch or commit it gives me this weird error. It'll continuously try to "refetch/recommit" until I give up and CtrlC.

C:\cygwin\home\git\new_trunk>git sf
      1 [main] perl 760 child_info_fork::abort: address space needed by 'cygreadline7.dll' (0x960000) is already occupied

C:\cygwin\home\git\new_trunk>git svn dcommit
      1 [main] perl 2672 child_info_fork::abort: address space needed by 'cygreadline7.dll' (0x980000) is already occupied

Any idea why this is happening?

3
  • Something is wrong with your cygwin install As an alternative, you could use the official git build (which uses msys) instead. Jun 19, 2012 at 20:20
  • @MatthewFlaschen probable, i did update cygwin with some other stuff. will try Jun 19, 2012 at 20:42
  • Had the same problem while using Git Bash spawned from SourceTree in Windows for command git add -p. This doesn't occur when Git Bash is opened from the Explorer context menu. Mar 11, 2021 at 9:11

4 Answers 4

33

Rebasing my Cygwin install solved this for me. I followed the doc Rebaseall, running dash as admin from Windows Explorer and then issuing the following:

/usr/bin/rebaseall -v

P.S.: No Cygwin service should be running for this to work.

2
  • This was a temporary solution for me. Fixed the problem for few hours only. Dec 7, 2015 at 5:02
  • 1
    Tip: ash is usually found in cygwin installation dir: C:\cygwin\bin\ash.exe Jun 6, 2018 at 15:17
16

Take a look at this Cygwin FAQ section and this too. In my case, disabling Avast's Behavior and Filesystem Realtime shields and then restarting Cygwin was the answer.

So, probably, you are running windows programs that hooks their DLLs into forked processes, disrupting addresses and thus causing fork to malfunction.

5
  • 1
    I think I experienced similar behavior with Microsoft Security Essentials.
    – DavidS
    Mar 27, 2016 at 17:47
  • 1
    Confirming this problem with Sophos' Behavior Monitoring - uncheck behavior monitoring, restart cygwin.
    – sCiphre
    Jan 6, 2017 at 11:08
  • I my case it was Windows 10's Virus & Threat Protection causing the problem. Jun 28, 2017 at 8:33
  • @Koning what about W10's virus settings did you change to fix it?
    – cmeza
    Jul 28, 2017 at 16:55
  • I turned off everything including real-time protection. Aug 3, 2017 at 6:45
7

I had this same fork() problem when my virus scanner, Symantec Endpoint Protection, was upgraded to 64-bit, but I was still running the 32-bit version of Cygwin. 'Rebaseall' didn't help. Upgrading to the 64-bit version of Cygwin has fixed the problem for me.

2
  • I had similar issues; was having this error doing a [git difftool -dirdiff] and hadn't recognised that a new version of SEP (32bit) was installed and asking to be rebooted to complete installation. Problem went away after rebooting and SEP was completely installed.
    – Zodman
    Sep 16, 2016 at 3:06
  • I had a similar issue trying to use git svn to clone a repo. It endlessly reported that mysqlite.dll was already in a given memory location. The command line in mingw32 was something like "C:\Program Files (x86)\git\git.exe" svn clone ..... anyway the exe was wrapped in dquotes. So I scraped out the command and changed it to just say svn git clone ..... and MAGIC - it runs. So apparently the use of the fully qualified EXE name in the shell was invoking a second copy of git.exe that attempted to lay itself into the same memory area or somesuch rather than running in its own space
    – Allen
    Apr 7, 2017 at 12:26
2

As mentioned by Tarc, no Cygwin services should be running to rebaseall. Otherwise you get

https://superuser.com/questions/231590/running-rebaseall-on-cygwin

Even after seemingly closing all Cygwin/Msys2 instances, you may find problems, as I did. Using Win 10 and Msys2 from PortableApps, I went to Task Manager, I sorted the list by the column "Command line". There I found my ssh-agent from Msys2 still running. I killed it, and then I could rebaseall .

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.