Uploaded image for project: 'Commons Daemon'
  1. Commons Daemon
  2. DAEMON-70

[daemon] Making jsvc multiple instances enabled

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 1.0.2
    • None
    • None
    • Operating System: All
      Platform: All

    • 33581

    Description

      This bug is closely related to 33580. The Tomcat5.sh script bundled with jsvc is
      not capable of handling multiple instances. According to
      http://miti.sourceforge.net this script should be adapted in the following ways:
      1) Introduce a variable $INSTANCE_NAME which is unique
      2) Introduce a variable $CATALINA_BASE_DIRS which represents a directory where
      all the instances will be located (e.g. /usr/local/tomcat/instances)
      3) Set $CATALINA_BASE in the script (or require the shell variable to be
      non-zero) to $CATALINA_BASE/$INSTANCE_NAME
      4) Introduce a parameter TMP_DIR=$CATALINA_BASE/$INSTANCE_NAME/temp
      5) Adapt the parameter in the jsvc call: "-Djava.io.tmpdir=$TMP_DIR \"
      6) Introduce a parameter PIDFILE=/var/run/jsvc-$INSTANCE_NAME.pid
      7) Add a line with "-pidfile $PIDFILE \" to the parameters for the jsvc call in
      the start section
      8) Change the stop case to
      stop)
      #

      1. Stop Tomcat
        #
        PID=`cat $PIDFILE`
        if [ -n $PID ]
        then
        kill $PID
        rm $PIDFILE
        fi
        ;;

      If the installation is for a single instance, $CATALINA_BASE will be empty and
      therefore can be set to $CATALINA_HOME.
      Point 8) might even be better addressed by the jsvc executable.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              wolf.hackl@gmx.at Wolfgang Hackl
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: