For sake of brevity, I did not include the entire init script. I did set the
TOMCAT_HOME, JAVA_HOME, and CLASSPATH environment variables in the init
script.

TOMCAT_HOME=/usr/local/tomcat
export TOMCAT_HOME
JAVA_HOME=/opt/java1.2
export JAVA_HOME
PATH=$TOMCAT_HOME/bin:/usr/sbin:/usr/bin:/sbin
export PATH
CLASSPATH=${CLASSPATH}:/apps/InformixJdbcDriver/lib/ifxjdbc.jar
export CLASSPATH

I also placed a sleep statement at the end of the tomcat init script and can
verify that the "java" process runs successfully, just as it does manually.
It is just when then "rc" process completes executing the init scripts that
the "java" process seems to die. There are no error messages at all.

I am assuming that someone out there has gotten Tomcat to startup with an
init script on HP-UX, Solaris, or SUN-OS. Some system that doesn't use the
"daemon" command like Linux does.

Any assistance is sincerely appreciated.


----- Original Message -----
From: "Vladimir Grishchenko" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, March 23, 2001 4:47 PM
Subject: Re: Tomcat startup problem


> It might be that you don't set $TOMCAT_HOME.
> The following script works on Linux, set vars to your values:
>
> #!/bin/sh
>
> TOMCAT_HOME=/usr/local/tomcat
> export TOMCAT_HOME
>
> JAVA_HOME=/opt/IBMJava2-13
> export JAVA_HOME
>
> case "$1" in
>   start)
>         echo -n "Starting Tomcat: "
>         $TOMCAT_HOME/bin/startup.sh
>         echo
>         ;;
>   stop)
>         echo -n "Shutting down Tomcat: "
>         $TOMCAT_HOME/bin/shutdown.sh
>         echo
>         ;;
>   *)
>         echo "Usage: $0 {start|stop}"
>         exit 1
> esac
>
> exit 0
>
>
> > Jon Small wrote:
> >
> > O/S: HP-UX 11.0
> > Apache: 1.3.12
> > Tomcat: 3.1
> >
> > Anyone have/had the same problem? I can start Tomcat manually just fine,
but
> > not successfully with an init script. It seems that the "java" process
> > starts initially, but at some point dies. I think that it dies when the
init
> > script exits. We have it running fine with Linux, but it uses a "daemon"
> > command to make the "java" process a daemon. Any clues?
> >
> > I use the standard SystemV init script:
> >
> > case "$1" in
> >    start)
> >          echo -n "Starting tomcat: "
> >          /usr/local/tomcat/bin/startup.sh
> >          ;;
> >    stop)
> >          echo -n "Shutting down tomcat: "
> >          /usr/local/tomcat/bin/shutdown.sh
> >          ;;
> >    *)
> >          echo "Usage: $0 {start|stop}"
> >          exit 1
> > esac
> >
> > exit 0
>

Reply via email to