1 Reply Latest reply on Jul 17, 2003 11:09 PM by jonlee

    Numerous threads

    noel.rocher

      Hi,
      I'm running JBoss3.2.1-tomcat on a Linux machine (mandrake 9.1) with 2 CPUs.

      It seems that a lot of threads are running and my linux administrator think that it's not normal.

      Can anyone tell me if it is the case. His observation is done by :

      lsof -ni | grep java | wc -l

      Tx
      Noel

        • 1. Re: Numerous threads
          jonlee

          There are a lot of independent processes running in JBoss. Remember The JBoss microkernel has a servlet container that runs multiple threads (1 per active listener instance - so say you had a minimum of 10 HTTP listeners and a max of 200, each would have its own thread), container threads, MBean threads, connection threads, and so on. That doesn't mean that all of them are active - when GC is complete and JBoss is in a quiescent state (no accesses to JBoss), you shouldn't see much more than 0.7 percent activity or less (depending on how fast your CPUs are). But the processes are necessary in case accesses to EJBs and so on do come in. I think a bare bones JBoss install with no applications has about 50 threads (or Linux processes). I'd normally check with a "pstree". It is the nature of Java on Linux - each Java thread is usually marked as a native Linux process due to the Linux process/thread model.