"Limited number of threads. OutOfMemoryException"

Discussion of programming on Linux, including shell scripting, perl, python, c/c++, mono, java. Whatever tickles your fancy.

"Limited number of threads. OutOfMemoryException"

Postby Saadi » Fri Mar 07, 2003 1:30 am

i am wondering if anyone has expierienced any issues with threads limitation on redhat 7.2. Is there a maximum number of threads a JVM can create per instance? I expect my server to at least be able to handle 1000-2000 clients concurrently. However while
running some tests, i have found that I run out of memory after
creating only 1024 Threads. this has been consistent on my Linux
box.

my test machine is a dual processor 2.4ghz with 2gb ram and lots of storage. I tried to increase the maximum size of the JVM stack with no
luck. Is there something I can do to increase the maximum nuber
of threads for my server?

also, i have read that compiling glibc with linuxthreads can also remedy the problem. i tried it bot to no avail because the compilation couldn't find Makecofig directory under the source tree.

if anyone out there who has had resolved such a problem, your help will be highly appreciated.

thanks.
Aziz Khawaja
Chicago, Il.
Saadi
Lance Naik
 
Posts: 33
Joined: Thu Mar 06, 2003 11:06 pm
Location: Chicago, Il - USA

Postby fawad » Fri Mar 07, 2003 8:29 am

Disclaimer: I've never done this myself.

http://www.jguru.com/faq/view.jsp?EID=237189 seems to say that you're correct. You do need to patch glibc. I'd recommend you try rebuilding from the srpms instead of doing it from scratch as the srpms tend to be compatible with the rest of your system.
fawad
Site Admin
 
Posts: 918
Joined: Wed Aug 07, 2002 8:00 pm
ICQ: 17672437
Website: http://www.fawad.net
WLM: fawadhalim@hotmail.com
Yahoo Messenger: fawad2048
AOL: fawadhalim
Location: Addison, IL

"Limited number of threads. OutOfMemoryException"

Postby Saadi » Fri Mar 07, 2003 9:04 am

fawad, thanks for posting the url link regarding my linux threads question. i'll try to rebuild the kernel (the way that have explained it) tomorrow when i go back to work. i hope my test goes successful after the change.
thanks again.
Aziz Khawaja

Chicago, Il.
Saadi
Lance Naik
 
Posts: 33
Joined: Thu Mar 06, 2003 11:06 pm
Location: Chicago, Il - USA


Return to “%s” Programming

Who is online

Users browsing this forum: No registered users and 1 guest

cron