No available terminals

16,725 views
Skip to first unread message

Dexx Mandele

unread,
Dec 19, 2016, 12:37:16 PM12/19/16
to git-for-windows
I generally run several git bash instances at a time to keep track of several interlinked packages. Once in a while I suddenly get this error when I try to open a new git bash terminal. 

Error: could not fork child process: There are no available terminals (-1).


All the running terminals remain operational, I just cannot open any new ones. If I close them all, I can usually re-open several of them, but never as many as I had to begin with. At that point the system seems to have decided on a set maximum; every time I close a terminal, I can open one, but I can never again go beyond the arbitrary max. 


Other terminals will spawn fine: I can still run new instances of git/bin/bash.exe, as well as cmd. It's just git-bash that borks. I've tried running from the start menu, explorer and from bash with the same result. 


Anyone have any idea how to tackle this? Obviously a fix would be great, but any sort of work-around that doesn't require me to restart my pc or re-install git would be a good start. Having to tear down and re-build my entire inter-linked development environment at least once a day is a major drain on my productivity. 


Environment details:
OS: Windows.
OS version: 10 64-bit
Git package: 2.10.0-64-bit

Nei Alcantara Jr

unread,
Jan 25, 2017, 7:21:26 AM1/25/17
to git-for-windows
Hello!

I have the same problem. Did you solve it?

Windows 10 64bits
Git: 2.11.0-64bits

Johannes Schindelin

unread,
Jan 25, 2017, 12:02:41 PM1/25/17
to Nei Alcantara Jr, git-for-windows
Hi,

On Wed, 25 Jan 2017, Nei Alcantara Jr wrote:

> Windows 10 64bits
> Git: 2.11.0-64bits

Could you try again with 2.11.0.3? It comes with an updated MSYS2 runtime
that is based on Cygwin 2.6.1, and that may fix that problem.

Ciao,
Johannes

Dan

unread,
Aug 3, 2017, 2:45:21 PM8/3/17
to git-for-windows
Hey All,

     I'm not sure if you guys are still having a problem with this, but I found a very simple fix that worked for me. I opened a windows command prompt and ran the command $ tasklist
     It looks as though the ssh connections I had made in my git bash shells weren't being closed when those windows were closed and were hanging the available git bash shell windows.
     This may be a dangerous solution but from the windows command prompt I ran $ taskkill /F /IM ssh.exe 
     Everything appears to be working again after this. It may not have directly been an issue of orphan processes, but this worked for at least for me. Good luck!
Message has been deleted

FOM Networks

unread,
Feb 6, 2018, 5:01:27 AM2/6/18
to git-for-windows
Hi,

I recently met the same problem and searched process ssh.exe but not found. Instead I found bash.exe. Killed this process and the problem fixed.

OS: Windows 10
Git: 2.16.1

Sohan Jangid

unread,
Jun 1, 2018, 4:47:23 AM6/1/18
to git-for-windows
Please find the ssh-agent process in task manager window.
After stop or kill the ssh-agent process the error will disappear.

Thanks

Sohan Jangid

unread,
Jun 1, 2018, 4:47:23 AM6/1/18
to git-for-windows
This will be resolved after update with the latest version of git


On Monday, December 19, 2016 at 11:07:16 PM UTC+5:30, Dexx Mandele wrote:

Sohan Jangid

unread,
Jun 1, 2018, 4:47:23 AM6/1/18
to git-for-windows
Please find the ssh-agent process in task manager window.
After stop or kill the ssh-agent process the error will disappear.

Thanks



Birger Skogeng Pedersen

unread,
Mar 25, 2019, 3:31:04 PM3/25/19
to git-for-windows
I'm afraid this error still occurs, running latest version of Git for Windows

kashga...@gmail.com

unread,
Nov 2, 2019, 7:28:47 PM11/2/19
to git-for-windows
you should try this command in  windows cmd:

TASKKILL /F /IM vim.exe


On Monday, December 19, 2016 at 11:07:16 PM UTC+5:30, Dexx Mandele wrote:
Reply all
Reply to author
Forward
0 new messages