java/lang/OutOfMemoryError":"Failed to fork OS thread请教

> OS Name:        AIX
> OS Version:     5.3

xms768m
xmx1024m

javacore:
heap space free: asfcfb58
heap space allocated:30000000

在运行一天左右,就会出现java/lang/OutOfMemoryError":"Failed to fork OS thread的异常,jvm打出一个core文件。这时,大部分线程将进入wait状态,导致很多业务不能运行,请教各位大侠是否遇到过同样的情况。
上周突然就这样了,之前一直也没有事。到底什么原因啊???
参与9

8同行回答

luckydevil_2001luckydevil_2001其它others
另一种可能:The problems was solved setting Xmx parameters for example, your OS has 3 gb RAM. your java processs is -Xmx1440m, that means almost 1.5 gb . ok. your process starts, it works for a while.... but at any moment after get that much memory it ...显示全部
另一种可能:
The problems was solved setting Xmx parameters

for example, your OS has 3 gb RAM.
your java processs is -Xmx1440m, that means almost 1.5 gb .
ok. your process starts, it works for a while.... but at any moment after get that much memory it blows up saying Failed to fork OS thread.
that is because, at least in windows, allows you to allocate as max the half of memory for a process, but you are not counting on java overhead. Then, if it tries to get more "permitted" memory it will blow up because the OS is not allowing to create new threads.

my advice.

1. if you want to allocate a lot of memory, use 40% as max of the total RAM of the OS (in windows) using Xmx params.
2. also, tweak the parameter -XX:ThreadStackSize=128 to reduce it, the default is 512 and that is too much收起
互联网服务 · 2015-08-06
浏览1638
luckydevil_2001luckydevil_2001其它others
以下是一种可能:This section explains the following error:java.lang.OutOfMemoryError: Failed to fork OS threadThis error occurs when thousands of threads are started in very quick succession (almost simultaneously). The error indicates that the upper l...显示全部
以下是一种可能:
This section explains the following error:
java.lang.OutOfMemoryError: Failed to fork OS thread

This error occurs when thousands of threads are started in very quick succession (almost simultaneously). The error indicates that the upper limit on the number of concurrent threads for the JVM has been reached.

Normally this error occurs when a Javascript loop starts thousands of threads in a very short period of time. This error should not occur in normal conditions in which Tivoli® Directory Integrator solutions usually operate.

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.收起
互联网服务 · 2015-08-06
浏览1611
暗黑城堡new暗黑城堡new其它XXX科技有限公司
应用做过修改吧。显示全部
应用做过修改吧。收起
金融其它 · 2015-07-21
浏览1737
bisubisu售后技术支持SYNNEX
上传个javacore,大家帮你分析分析显示全部
上传个javacore,大家帮你分析分析收起
IT咨询服务 · 2015-07-21
浏览1572
huangdoshuangdosCTO深圳乐凯撒股份有限公司
需要使用 内存分析工具,分一下 dump 文件显示全部
需要使用 内存分析工具,分一下 dump 文件收起
互联网服务 · 2015-07-20
浏览1556
seijaseija系统运维工程师用友
回复 3# bisu     无法做主,不明白的人会说之前也没有问题的啊。所以有没有 解决方案啊。显示全部
回复 3# bisu


    无法做主,不明白的人会说之前也没有问题的啊。所以有没有 解决方案啊。收起
互联网服务 · 2015-07-20
浏览1546
bisubisu售后技术支持SYNNEX
最简单的办法就是使用64位WebSphere显示全部
最简单的办法就是使用64位WebSphere收起
IT咨询服务 · 2015-07-20
浏览1674
yinxinyinxin项目经理某金融机构
看看机器的剩余内存还有多少显示全部
看看机器的剩余内存还有多少收起
银行 · 2015-07-20
浏览1563

提问者

seija
系统运维工程师用友

相关问题

相关资料

相关文章

问题状态

  • 发布时间:2015-07-20
  • 关注会员:1 人
  • 问题浏览:6845
  • 最近回答:2015-08-06
  • X社区推广