This is the mail archive of the
mailing list for the Cygwin project.
Re: 1.7.10 cygrunsrv.exe fails with "fork: 11, Resource temporarily unavailable"
On Mar 4 15:53, Ulf-Dietrich Braumann wrote:
> Yes, Corinna, I reverted this setting again to the default 384MB
> heap size calling:
> $ peflags --cygwin-heap=0 /usr/sbin/sshd.exe
> $ peflags --cygwin-heap=0 /usr/bin/cygrunsrv.exe
> Later on, someone has recommended me to downgrade cygrunsrv from
> 1.36-1 to 1.34-1. This helped, so now under cygwin1.dll 1.7.11 the
> sshd can be started. However, the mechanism behaves strange
> reporting problems:
> C:\>net start sshd
> The CYGWIN sshd service is starting.
> The CYGWIN sshd service could not be started.
> The service did not report an error.
> More help is available by typing NET HELPMSG 3534.
> Having a look into the Event Viewer of my Win2k3 64bit machine, I
> correspondingly find:
> ... `sshd' service stopped, exit status: 0.
I can't reproduce this one, but I can reproduce the original problem
System error 1067 has occurred.
The process terminated unexpectedly.
on Windows 2003 64 bit. It works fine on W7, Windows 2008 R2, and
even on Windows 2003 32 bit.
I'm still looking into it, but I made an astonishing discovery:
If I build cygrunsrv with gcc-3.x, it works. Only when building
cygrunsrv with gcc-4.x, it fails as above.
However, the reason why starting the service fails is the following:
When cygrunsrv runs under SCM, it gets started, then it registers, then
scm starts another thread in cygrunsrv. This thread then starts the
actual service application like sshd by calling fork/exec.
What happens is that forking cygrunsrv fails, because the child process
can't duplicate the parent processes stack, because the memory addresses
are already taken by something else in the child.
Why this only fails when cygrunsrv has been built with gcc-4 but not with
gcc-3 is most puzzeling.
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple