help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: msys2: Resource temporarily unavailable


From: Paul Smith
Subject: Re: msys2: Resource temporarily unavailable
Date: Thu, 28 Apr 2016 13:55:23 -0400

On Thu, 2016-04-28 at 10:36 -0700, David Boyce wrote:
> I think these replies are all a bit wrong. Msys2 is really just a fork of
> Cygwin as I understand it and these fork errors are a very well known
> problem (though mostly solved nowadays) in Cygwin. The very short version
> is that the Cygwin fork emulation has to guess where each dll will be
> mapped to in the child and sometimes it guesses wrong resulting a collision
> and one of these fork failures. In Cygwin the solution is to rebase the
> entire installation using a script provided (modern Cygwin installs
> actually do auto-rebasing so that isn't usually needed). I don't know how
> much of the fix has made it into msys2. If you google "Cygwin fork errors"
> or similar you'll see plenty of data about it.

Thanks David.

Just to add to that: the Cygwin port of GNU make (at least the last time
I checked) has a number of patches applied, etc.  So it's probably best
to ask about that port on the Cygwin help forums and lists first,
especially if it's an issue that appears to happen only there and not in
the other GNU make ports.

ISTR there was some effort to reduce the changes needed but I'm not sure
where that effort stands right now.


> On Wed, Apr 27, 2016 at 4:12 PM, Bob Proulx <address@hidden> wrote:
> 
> > address@hidden wrote:
> > >   We are using Gnu Make 4.1 from a somewhat recent installation of
> > >   msys2 as part of a very large build system.
> > 
> > Saying msys2 tells me that you are running on MS-Windows.
> > 
> > >   We are periodically seeing:
> > > 
> > >     make: fork: Resource temporarily unavailable
> > > 
> > >   We don't know the specific conditions to reproduce the mesasge,
> > >   yet.
> > 
> > Your system is out of memory.  It cannot fork.  The message says
> > temporary because it isn't a hard fatal error.  If memory were
> > available then it would work.  Therefore it is a temporary failure.
> > 
> > In a Unix process model new programs are spawned by using two system
> > calls back to back.  The first is fork() and the second is exec().
> > First the process forks to create two copies, a parent and a child.
> > Then the child calls exec() to launch the new process.  In your case
> > above the fork() is failing.  (It would normaly immediately be
> > followed by an exec() of a new process and therefore the memory
> > needed
> > might immediately go down.  But at the time of the fork that isn't
> > known yet.)
> > 
> > You might want to read over a man page for more details.  Here is
> > one.
> > 
> > 
> > http://www.freebsd.org/cgi/man.cgi?query=fork&apropos=0&sektion=0&ma
> > npath=FreeBSD+10.3-RELEASE&arch=default&format=html
> > 
> > To avoid this error the system needs enough virtual memory to avoid
> > the failure.  Either the system is doing too much (too many
> > processes
> > doing too many large things) or it doesn't have enough to do what it
> > is doing.
> > 
> > To increase virtual memory it is easiest is to add more swap space.
> > Better is to add more ram.  In either case the system is beyond its
> > available resources.  If the machine is doing too much then try to
> > move tasks onto other systems so that this one isn't doing as much.
> > Or spread them out in time.  Instead of doing a lot all at once
> > spread
> > the tasks out so that it is only doing a little at a time.  Or now
> > that you know it is just out of memory maybe you already know what
> > can
> > be done on your system to get it through things.
> > 
> > Bob
> > 
> > _______________________________________________
> > Help-make mailing list
> > address@hidden
> > https://lists.gnu.org/mailman/listinfo/help-make
> > 
> _______________________________________________
> Help-make mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/help-make



reply via email to

[Prev in Thread] Current Thread [Next in Thread]