View Full Version : Error starting 2nd instance of tomcat
eponcedeleonc
28-08-2008, 22:13
I am trying to run a 2nd instace of tomcat. For this, ive duplicated the tomcat folder and modified the server.xml files with different ports. I've also created a startup script, but when I run the script I am getting this error... Can anyone help please!!
[root@balder312 tomcat5-test]# tomcat5-test start In the config file Starting tomcat5-test: [ FAILED ]
This is what i get in my catalina.out
-sh: line 0: export: `In the config file': not a valid identifier
/bin/bash: /usr/bin/tomcat5-test: Permission denied
-sh: line 0: export: `In the config file': not a valid identifier
/bin/bash: /usr/bin/tomcat5-test: Permission denied
kjkoster
29-08-2008, 09:50
Dear eponcedeleonc,
I'm curious how you duplicated the Tomcat directory. Have you checked that all file ownership and permissions were preserved? For example, what are the file permissions on /usr/bin/tomcat5-test?
Also, what is that 'In the config file' that you type in the command line?
Kees Jan
eponcedeleonc
29-08-2008, 15:32
I duplicated by copying the entire folder with cp commnad, ive checked the permission and they all seem the same.. file permission for /usr/bin/tomcat5-test is 755..
i dont type the 'In the config file' thats what i get when i run tomcat5-test start...
[root@balder312 logs]# tomcat5-test start
In the config file
Starting tomcat5-test: [ FAILED ]
this is my log... and is all talking about the origanl configuration of tomcat why?
-sh: line 0: export: `In the config file': not a valid identifier
/bin/bash: /usr/bin/tomcat5-test: Permission denied
-sh: line 0: export: `In the config file': not a valid identifier
/bin/bash: /usr/bin/tomcat5-test: Permission denied
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Password:
Session terminated, killing shell... ...killed.
su: incorrect password
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/usr/bin/tomcat5-test: line 206: /usr/share/tomcat5-test/logs/logscatalina.out: Permission denied
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/sbin/runuser: cannot set groups: Operation not permitted
[60G[ FAILED ]
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/sbin/runuser: cannot set groups: Operation not permitted
[60G[ FAILED ]
kjkoster
29-08-2008, 16:33
Dear eponcedeleonc,
Those are strange messages. Could we see your start script, please?
Kees Jan
kjkoster
29-08-2008, 16:39
Dear eponcedeleonc,
Actually, check your startup and tomcat scripts for the phrase "In the config file". I'd like to know where that comes from.
Kees Jan
eponcedeleonc
29-08-2008, 16:42
thats what I am working on Kess...this is my startup script...everytying in tomcat5-test is for the new instance, what ive done is replaced the original, which is tomcat5 for the duplicate! Thanks for the help
#!/bin/bash
#
# tomcat5 This shell script takes care of starting and stopping Tomcat
#
# chkconfig: - 80 20
#
### BEGIN INIT INFO
# Provides: tomcat5
# Required-Start: $network $syslog
# Required-Stop: $network $syslog
# Default-Start:
# Default-Stop:
# Description: Release implementation for Servlet 2.4 and JSP 2.0
# Short-Description: start and stop tomcat
### END INIT INFO
#
# - originally written by Henri Gomez, Keith Irwin, and Nicolas Mailhot
# - heavily rewritten by Deepak Bhole and Jason Corley
#
# commented out until the RHEL and FC daemon functions converge
# Source the function library
#if [ -r "/etc/rc.d/init.d/functions" ]; then
#. /etc/rc.d/init.d/functions
#fi
NAME="$(basename $0)"
unset ISBOOT
if [ "${NAME:0:1}" = "S" -o "${NAME:0:1}" = "K" ]; then
NAME="${NAME:3}"
ISBOOT="1"
fi
# For SELinux we need to use 'runuser' not 'su'
if [ -x "/sbin/runuser" ]; then
SU="/sbin/runuser"
else
SU="su"
fi
# Get the tomcat config (use this for environment specific settings)
TOMCAT_CFG="/etc/tomcat5-test/tomcat5.conf"
if [ -r "$TOMCAT_CFG" ]; then
. ${TOMCAT_CFG}
fi
# Get instance specific config file
if [ -r "/etc/sysconfig/${NAME}" ]; then
. /etc/sysconfig/${NAME}
fi
# Define which connector port to use
CONNECTOR_PORT="${CONNECTOR_PORT:-8080}"
# Path to the tomcat launch script
TOMCAT_SCRIPT="/usr/bin/tomcat5-test"
# Path to the script that will refresh jar symlinks on startup
TOMCAT_RELINK_SCRIPT="${CATALINA_HOME}/bin/relink"
# Tomcat program name
TOMCAT_PROG="$NAME"
# Define the tomcat username
TOMCAT_USER="${TOMCAT_USER:-tomcat}"
# Define the tomcat log file
TOMCAT_LOG="${TOMCAT_LOG:-/usr/share/tomcat5-test/logs/logscatalina.out}"
RETVAL="0"
# remove when the RHEL and FC daemon functions converge
# (pulled from /etc/rc.d/init.d/functions)
function checkpid() {
local i
for i in $* ; do
if [ -d "/proc/${i}" ]; then
return 0
fi
done
return 1
}
# remove when the RHEL and FC daemon functions converge
# (pulled from /etc/rc.d/init.d/functions)
function echo_failure() {
echo -en "\\033[60G"
echo -n "[ "
echo -n $"FAILED"
echo -n " ]"
echo -ne "\r"
return 1
}
# remove when the RHEL and FC daemon functions converge
# (pulled from /etc/rc.d/init.d/functions)
function echo_success() {
echo -en "\\033[60G"
echo -n "[ "
echo -n $"OK"
echo -n " ]"
echo -ne "\r"
return 0
}
# Look for open ports, as the function name might imply
function findFreePorts() {
local isSet1="false"
local isSet2="false"
local isSet3="false"
local lower="8000"
randomPort1="0"
randomPort2="0"
randomPort3="0"
local -a listeners="( $(
netstat -ntl | \
awk '/^tcp/ {gsub("(.)*:", "", $4); print $4}'
) )"
while [ "$isSet1" = "false" ] || \
[ "$isSet2" = "false" ] || \
[ "$isSet3" = "false" ]; do
let port="${lower}+${RANDOM:0:4}"
if [ -z `expr " ${listeners } " : ".*\( $port \).*"` ]; then
if [ "$isSet1" = "false" ]; then
export randomPort1="$port"
isSet1="true"
elif [ "$isSet2" = "false" ]; then
export randomPort2="$port"
isSet2="true"
elif [ "$isSet3" = "false" ]; then
export randomPort3="$port"
isSet3="true"
fi
fi
done
}
function makeHomeDir() {
if [ ! -d "$CATALINA_HOME" ]; then
echo "$CATALINA_HOME does not exist, creating"
if [ ! -d "/var/lib/${NAME}" ]; then
mkdir -p /var/lib/${NAME}
cp -pLR /var/lib/tomcat5-test/* /var/lib/${NAME}
fi
mkdir -p $CATALINA_HOME ${CATALINA_HOME}/conf /var/cache/${NAME}/temp \
/var/cache/${NAME}/work /var/log/${NAME}
for i in temp work; do
ln -fs /var/cache/${NAME}/${i} ${CATALINA_HOME}/${i}
done
for i in common server shared webapps; do
ln -fs /var/lib/${NAME}/${i} ${CATALINA_HOME}/${i}
done
ln -fs /var/log/${NAME} ${CATALINA_HOME}/logs
cp -pLR /usr/share/tomcat5-test/* ${CATALINA_HOME}/conf/
cp -pLR /usr/share/tomcat5-test/bin $CATALINA_HOME
cp -pLR /usr/share/tomcat5-test/* ${CATALINA_HOME}/work/
chown ${TOMCAT_USER}:${TOMCAT_USER} /var/log/${NAME}
fi
}
function parseOptions() {
options=""
options="$options $(
awk '!/^#/ && !/^$/ { ORS=" "; print "export ", $0, ";" }' \
$TOMCAT_CFG
)"
if [ -r "/etc/sysconfig/${NAME}" ]; then
options="$options $(
awk '!/^#/ && !/^$/ { ORS=" ";
print "export ", $0, ";" }' \
/etc/sysconfig/${NAME}
)"
fi
TOMCAT_SCRIPT="$options $TOMCAT_SCRIPT"
}
# See how we were called.
function start() {
echo -n "Starting ${TOMCAT_PROG}: "
if [ -f "/var/lock/subsys/${NAME}" ] ; then
if [ -f "/var/run/${NAME}.pid" ]; then
read kpid < /var/run/${NAME}.pid
if checkpid $kpid 2>&1; then
echo "$NAME process already running"
return -1
else
echo "lock file found but no process running for"
echo "pid $kpid, continuing"
fi
fi
fi
export CATALINA_PID="/var/run/${NAME}.pid"
touch $CATALINA_PID
chown ${TOMCAT_USER}:${TOMCAT_USER} $CATALINA_PID
if [ "$CATALINA_HOME" != "/usr/share/tomcat5-test" ]; then
# Create a tomcat directory if it doesn't exist
makeHomeDir
# If CATALINA_HOME doesn't exist modify port number so that
# multiple instances don't interfere with each other
findFreePorts
sed -i -e "s/8005/${randomPort1}/g" -e "s/8080/${CONNECTOR_PORT}/g" \
-e "s/8009/${randomPort2}/g" -e "s/8443/${randomPort3}/g" \
${CATALINA_HOME}/conf/server.xml
fi
$TOMCAT_RELINK_SCRIPT
$SU - $TOMCAT_USER -c "$TOMCAT_SCRIPT start" >> $TOMCAT_LOG 2>&1
RETVAL="$?"
if [ "$RETVAL" -eq 0 ]; then
echo_success
touch /var/lock/subsys/${NAME}
else
echo_failure
fi
echo
return $RETVAL
}
function status() {
RETVAL="1"
if [ -f "/var/run/${NAME}.pid" ]; then
read kpid < /var/run/${NAME}.pid
if checkpid $kpid 2>&1; then
echo "$0 is already running (${kpid})"
RETVAL="0"
else
echo "lock file found but no process running for pid $kpid"
fi
else
pid="$(pgrep -u tomcat java)"
if [ -n "$pid" ]; then
echo "$0 running (${pid}) but no PID file exists"
RETVAL="0"
else
echo "$0 is stopped"
fi
fi
return $RETVAL
}
function stop() {
local STOP_VERBOSE="false"
echo -n "Stopping $TOMCAT_PROG: "
if [ -f "/var/lock/subsys/${NAME}" ]; then
$SU - $TOMCAT_USER -c "$TOMCAT_SCRIPT stop" >> $TOMCAT_LOG 2>&1
RETVAL="$?"
if [ "$RETVAL" -eq "0" ]; then
count="0"
if [ -f "/var/run/${NAME}.pid" ]; then
read kpid < /var/run/${NAME}.pid
until [ "$(ps --pid $kpid | grep -c $kpid)" -eq "0" ] || \
[ "$count" -gt "$SHUTDOWN_WAIT" ]; do
if [ "$STOP_VERBOSE" = "true" ]; then
echo -n -e "\nwaiting for processes $kpid to exit"
fi
sleep 1
let count="${count}+1"
done
if [ "$count" -gt "$SHUTDOWN_WAIT" ]; then
if [ "$STOP_VERBOSE" = "true" ]; then
echo -n -e "\nkilling processes which didn't stop"
echo -n -e "after "
echo -n "$SHUTDOWN_WAIT seconds"
fi
kill -9 $kpid
fi
echo_success
if [ "$count" -gt "0" ]; then
echo -n -e "\n"
fi
fi
rm -f /var/lock/subsys/$NAME /var/run/$NAME.pid
else
echo_failure
fi
fi
}
# See how we were called.
case "$1" in
start)
parseOptions
start
;;
stop)
parseOptions
stop
;;
restart)
parseOptions
stop
sleep 2
start
;;
condrestart)
if [ -f "/var/run/${NAME}.pid" ]; then
parseOptions
stop
start
fi
;;
status)
status
;;
version)
parseOptions
"${JAVA_HOME}/bin/java" \
-classpath "${CATALINA_HOME}/server/lib/catalina.jar" \
org.apache.catalina.util.ServerInfo
;;
*)
echo "Usage: $TOMCAT_PROG {start|stop|restart|condrestart|status|version}"
exit 1
esac
exit $RETVAL
kjkoster
29-08-2008, 16:50
Dear eponcedeleonc,
That's just the stock Tomcat startup script, so that's no help.
In what file can you find the phrase 'In the config file', please?
Kees Jan
eponcedeleonc
29-08-2008, 17:38
ok.. its in the tomcat5.conf which is from the original instance... this is the file!
# you could also override JAVA_HOME here
# Where your java installation lives
export JAVA_HOME="/usr/lib/jvm/java"
export JRE_HOME="/usr/lib/jvm/java"
# Where your tomcat installation lives
# That change from previous RPM where TOMCAT_HOME
# used to be /var/tomcat.
# Now /var/tomcat will be the base for webapps only
echo "In the config file"
CATALINA_HOME="/usr/share/tomcat5"
JASPER_HOME="/usr/share/tomcat5"
CATALINA_TMPDIR="/usr/share/tomcat5/temp"
JAVA_ENDORSED_DIRS="/usr/share/tomcat5/common/endorsed"
eponcedeleonc
29-08-2008, 17:40
Ive made changes to that .conf file and that error 'in the config file' is gone..but now i am getting this...
[root@balder312 bin]# tomcat5-test start
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5-test/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5-test/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5-test/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5-test/shared/lib must be a writable directory
[ FAILED ]
Now am i making the mistake of pointing those files to tomcat5- test where instead they should be pointing to the original folder so that the necesary changes can be made! If i change the permission for those files, would that mess up my original tomcat?
kjkoster
29-08-2008, 18:52
Dear eponcedeleonc,
I've never heard of /usr/bin/rebuild-jar-repository and I have no idea what it does. Maybe someone else on the forum knows?
In *stock* Tomcat from Apache.org, you will have no problems running more than one Tomcat using the same jars and jar folder. This package I don't know, so you'll have to try and see.
Kees Jan
PS. Another reason not to use a repackaged Tomcat (http://java-monitor.com/forum/showthread.php?t=4). :-)
eponcedeleonc
29-08-2008, 20:24
how do i know if the tomcat that I am using is a repackaged or not? From what you are saying its a repackaged so that could be why I am having all this trouble!!
Dear eponcedeleonc,
Hehe. If you installed it using rpm/apt/ports or somesuch it is repackaged. If you downloaded apache-tomcat-<someversion>.zip from tomcat.apache.org yourself, it is stock.
The (single) advantage of a repackaged Tomcat is that it comes with a start script for your distribution. The disadvantages you have already experienced.
On the other hand, once it is running I have all confidence that it will keep running.
How far are you now? Have you gotten the second Tomcat to serve some HTTP requests for you yet?
Kees Jan
eponcedeleonc
29-08-2008, 21:08
the thing is that i didnt installed tomcat on the server, so i wouldnt know!! and i have made no progress. i am stuck with this errors in my logscatalina.out
-sh: line 0: export: `In the config file': not a valid identifier
In the config file
Starting tomcat5-test: /usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/common/endorsed must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/server/lib must be a writable directory
/usr/bin/rebuild-jar-repository: error: /usr/share/tomcat5/shared/lib must be a writable directory
/sbin/runuser: cannot set groups: Operation not permitted
[60G[ FAILED ]
and all those groups have write rights...
kjkoster
29-08-2008, 21:21
Dear eponcedeleonc,
How about you do this:
download a fresh Tomcat from http://tomcat.apache.org/download-60.cgi (or whatever version you need).
unzip apache-tomcat*.zip
cd apache-tomcat*/bin; chmod 755 *.sh
./catalina.sh run
The only thing is that this Tomcat will not automatically start when you reboot the system.
Kees Jan
eponcedeleonc
29-08-2008, 21:34
Kees,
what do u mena it wont start when i reboot my system...i would do that but right now we have some applications working on the current tomcat and i cant reboot the server.. moreover, if i installed a version like u said, woudl that affect the current instance i am running now? I know for a fact that we ask our server provider to installed tomcat, so I am waiting to figure out what kind did they installed. Considering they've installed the repackage.
1)If want to install a stock version like youve suggested, the for ssh dont change right? or what precautions do i need to consider?
2)Once i've installed it the way you say to, how can i start that service so that i can have multiple instances running at the same time?
3) Finally to have multiple instances would be the same steps that i was doing, that is copying the tomcat folde, edit .xml file for different ports and starting the instance manually right?
Thanks for all the help!
kjkoster
30-08-2008, 07:11
Dear eponcedeleonc,
No, you don't have to reboot your server. Come on, this isn't Windows. I said that it won't start automatically *if* you reboot.
I have no idea what "the for ssh" means. Your ssh password or the way you work through ssh won't change.
You start the Tomcat using ${TOMCAT}/bin/startup.sh and you stop with ${TOMCAT}/bin/shutdown.sh
For each new instance, you would unzip a new Tomcat from the zip you downloaded and edit the server.xml to put it on its own ports.
This way you can run as many instances as you have ports and RAM for. During testing, I routinely run four or five instances on the same machine.
Kees Jan
kjkoster
30-08-2008, 11:45
And another advantage is that you can run the Tomcat instances under your own user credentials. You don't need to be root to start and stop them.
eponcedeleonc
01-09-2008, 04:25
Kess,
If i do this..
* download a fresh Tomcat from http://tomcat.apache.org/download-60.cgi (or whatever version you need).
* unzip apache-tomcat*.zip
* cd apache-tomcat*/bin; chmod 755 *.sh
* ./catalina.sh run
would that change any of my global variables of the tomcat i already have installed in my server? And I am guessing i just need to pick a different folder for the new installation right?
Thank you,
Eduardo
kjkoster
01-09-2008, 05:51
Dear Eduardo,
No, each Tomcat would be completely independent. If you study the directory structure of a normal Tomcat, you'll see that it's neatly self contained. All configuration is in ${tomcat}/conf, webapps in ${tomcat}/webapps. Configuration is not scattered all over the place, like with the package your sysadmin installed.
Just pick any directory you like.
Kees Jan
eponcedeleonc
01-09-2008, 15:22
Kess,
why am i getting this error when i try to startup this version of tomcat.. if i've deleted all the copies i made of the original tomcat.
[root@balder312 bin]# ./catalina.sh run
Cannot find /usr/share/tomcat5/bin/setclasspath.sh
ive also tried this as it said on the README file and no succes
[root@balder312 local]# $CATALINA_HOME/bin/startup.sh
-bash: /usr/share/tomcat5/bin/startup.sh: No such file or directory
kjkoster
01-09-2008, 15:37
try unsetting CATALINA_HOME, CATALINA_BASE and TOMCAT_HOME.
eponcedeleonc
01-09-2008, 15:45
by unsetting you mean skipping CATALINA_HOME on the command line when i try to start tomcat?
ifi change the $CATALINA_HOME for the path of the folder i installed it in the catalina.sh would that work?
eponcedeleonc
01-09-2008, 19:52
Kess,
How can I check if my new installation of tomcat is running... when i start with the catalina.sh command i got this..
[root@balder312 bin]# ./catalina.sh run
Using CATALINA_BASE: /usr/local/tomcat-test
Using CATALINA_HOME_TEST: /usr/local/tomcat-test
Using CATALINA_TMPDIR_TEST: /usr/local/tomcat-test/temp
Using JRE_HOME: /usr/lib/jvm/java
WARNING: error instantiating 'org.apache.juli.ClassLoaderLogManager' referenced by java.util.logging.manager, class not found
java.lang.ClassNotFoundException: org.apache.juli.ClassLoaderLogManager not found
<<No stacktrace available>>
WARNING: error instantiating '1catalina.org.apache.juli.FileHandler,' referenced by handlers, class not found
java.lang.ClassNotFoundException: 1catalina.org.apache.juli.FileHandler,
<<No stacktrace available>>
Exception during runtime initialization
java.lang.ExceptionInInitializerError
<<No stacktrace available>>
Caused by: java.lang.NullPointerException
<<No stacktrace available>>
Then I tried this command...
[root@balder312 bin]# ./catalina.sh debug
The JAVA_HOME environment variable is not defined correctly
This environment variable is needed to run this program
NB: JAVA_HOME should point to a JDK not a JRE
Does that mean i need to install JDK on my server and have the java_home for my duplicate instance point to the jdk directory?
Thanks
eponcedeleonc
04-09-2008, 02:55
So i downloaded the stock version and installed jdk1.6.0_10 and know i am getting this error when i try to start the 2nd instance manually, any ideas?
Thank you,
Using CATALINA_BASE: /usr/local/tomcat-test
Using CATALINA_HOME_TEST: /usr/local/tomcat-test
Using CATALINA_TMPDIR_TEST: /usr/local/tomcat-test/temp
Using JRE_HOME: /usr/lib/jvm/java
WARNING: error instantiating 'org.apache.juli.ClassLoaderLogManager' referenced by java.util.logging.manager, class not found
java.lang.ClassNotFoundException: org.apache.juli.ClassLoaderLogManager not found
<<No stacktrace available>>
WARNING: error instantiating '1catalina.org.apache.juli.FileHandler,' referenced by handlers, class not found
java.lang.ClassNotFoundException: 1catalina.org.apache.juli.FileHandler,
<<No stacktrace available>>
Exception during runtime initialization
java.lang.ExceptionInInitializerError
<<No stacktrace available>>
Caused by: java.lang.NullPointerException
<<No stacktrace available>>
vBulletin® v3.8.6, Copyright ©2000-2012, Jelsoft Enterprises Ltd.