tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Korambath, Prakashan" <>
Subject Persistent thread problem while doing system call in jakarta tomcat to run globus jobs using globus tool kit 3.0
Date Fri, 17 Oct 2003 22:04:21 GMT

We have been creating a web site to provide Grid services.  It will
allow users to submit jobs to various compute clusters using the Globus
toolkit 3.0. Our Java code runs under a Jakarta Tomcat container and
submits jobs to the compute clusters by handing off the jobs to the
Globus software, specifically globusrun.  

We have a thread problem while doing a system call in Jakarta tomcat.
Jakarta tomcat is being run under the userid "globus". However, it needs
to submit each job to a compute cluster under the user's userid.  In the
class, we make a system call which runs a setuid C binary, in that
setuid C binary, we fork a process under the user's userid and that
process runs a shell script as the user.  That script then runs another
java program. That 
program is the managed-globus-run program from the Globus toolkit 3.0.

So here we have a Java servlet running under a Jakarta Tomcat container
calling a C program which in turn is calling a shell script which calls
a Java program.  The problem we have is that the Java program can never
be terminated.  It completes but then always goes into a sleep mode
after it has run. It turns into a process that can never be killed.
When we try to kill the java process, a number of child processes are
forked. The number of processes that reappear seem to be random, from 1
to as many as 20 each time. These processes eventually bring down the
system as they take up memory and then we have to reboot it.

We experience the same behavior when we write a little test Java program
which runs under Jakarta Tomcat and calls a C program which forks a
thread and calls a script which then calls another test Java program.
The second Java 
program completes but never terminates and cannot be killed manually.

Is there any solution to this problem?  Our Operating system is Linux,
Jakarta tomcat version is 4.1.24 and java version is 1.4.2.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message