Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

OutOfMemory-unable to create native thread

 
ramkumar meyyappan
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
while trying to test the performance of my jboss server, i create 100 threads per second with a delay of 50 milli seconds between threads, i get this exception (java.lang.OutOfMemoryError: unable to create new native thread) in less than 10 minutes. iam running my jvm with -Xms1024m -Xmx1024.

jboss is throwing ThreadGroupFull Error also.

Iam unable to test the performance of my Application Server.

I would be really happy, if u could help me put in this.
waiting for ur reply, as i dont have anyother lead....

Thank You!
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you building a test client that calls into your server? Maybe trying to see how many calls your server can handle at the same time?

Whatever you're building, you can't just create threads forever. Each new thread chews up some memory and CPU resources so you will hit a limit in fairly short order. If you need to simulate 100 concurrent users you only need 100 threads, which is probably not out of reach.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!