JIRA Crashes with "Failed to fork OS thread" Error Message
The JIRA instance crashes a couple of times due to OutOfMemoryError. However, a "Failed to fork OS thread" error message is shown instead of a common insufficient memory exception.
The following appears in the
Cause: java.lang.OutOfMemoryError: Failed to fork OS thread Stack Trace: [hide] java.lang.OutOfMemoryError: Failed to fork OS thread at java.lang.Thread.startImpl(Native Method) at java.lang.Thread.start(Thread.java:966) at jcifs.util.transport.Transport.connect(Transport.java:171) at jcifs.smb.SmbTransport.connect(SmbTransport.java:290) at jcifs.smb.SmbSession.getChallenge(SmbSession.java:146) ...
This error occurs when you are using IBM WebSphere Application Server. It indicates that the maximum number of concurrent VM's is exceeded.
Quoting the IBM article which covers this error: You can avoid this error by inserting a very small delay between starting successive threads (even as small as 1 millisecond). This delay can cause performance to decrease a little, but the error would disappear.