|
--- Adam Lang <aalang@xxxxxxxxxxxxxxxxxxxx> wrote:
> Is it possible to run Tomcat under OS/400 or do you
> have to run a Linux
> LPAR?
>
> Also, if I recall, Websphere is Tomcat underneath,
> right?
>
Adam,
You can use the IBM supplied Tomcat and work through
their Web Server Administration to set it up as
In-process or stand-alone. Though, you can even
download the Windows version of Tomcat off Jakart and
run it right out of the IFS.
I did it and it works great, though I'm not doing much
with it as of now. I'm mainly using WAS.
This is the script that I use to start it (I believe
the script comes from one of Don Dennoncourt examples
& another example I found elsewhere).
This is what's cool about Java.
If you email me, I'll attach the script.
HTH,
Don McIntyre
Examples:
Program: STARTTC
PGM
SBMJOB CMD(QSH
CMD('/tomcat/jakarta-tomcat-4.1.24/bin/catalina400.sh'))
JOB(TOMCATTC) JOBQ(TOMCATJQ)
ENDPGM
Script in Tomcat/Jakarta-Tomcat/bin
catalina400.sh
# shell script to run Tomcat 4.0 and earlier
# SBMJOB CMD(QSH
CMD('jakarta-tomcat-4.0.1/bin/catalina400.sh'))
JOB(catalina)
# To provide multiple instances of Tomcat,
development, test, and production,
# modify this script to set CATALINA_BASE to a
directory containing the conf, log,
# and work directories. Copy the conf directory found
in CATALINA_HOME to the new
# conf directory in CATALINA_BASE. I set CATALINA_BASE
to $home/jakarta-tomcat-4.0.1
# if it exists. Scan for and replace the following
original ports in the server.xml
# file found in the conf directory. I prepend a 1-6
allowing for 7 total servers.
#
# orig new
# 8005 | x8005 | Shutdown
# 8080 | x8080 | Non-SSL HTTP
# 8443 | x8443 | Redirect port - Used / SSL HTTP
Connector - Not used
# 8009 | | AJP Connector
# 8081 | | Proxied HTTP
# 8082 | | Test HTTP
# 1521 | | Oracle
# 8008 | x8008 | Warp Connector
# Set job priority to standard for interactive
(interactive - 6) by using
# the interactive priority - 6, the helper threads
that respond to requests
# will be running at the same priority as interactive
jobs.
export COMMAND='chgjob job('$JOBNAME') runpty(14)'
system $COMMAND
export QIBM_MULTI_THREADED=Y
export -s JAVA_HOME=/QIBM/ProdData/Java400/jdk13
export -s CATALINA_HOME=/tomcat/jakarta-tomcat-4.1.24
# Set CATALINA_BASE to point to a directory containing
conf, work, and logs
# directories if you want to run multiple instances of
Tomcat but share the
# the same installation found in your CATALINA_HOME
directory.
# export -s CATALINA_BASE=$HOME/$CATALINA_HOME
export -s CATALINA_BASE=$CATALINA_HOME
# The following line allows you to compile JSP pages
CP=$CATALINA_HOME/bin/bootstrap.jar:/QIBM/ProdData/Java400/jdk13/lib/tools.jar
export -s CLASSPATH=$CP
echo Using Classpath: $CP
echo Using CATALINA_BASE: $CATALINA_BASE
echo Using CATALINA_HOME: $CATALINA_HOME
echo Using JAVA_HOME: $JAVA_HOME
# Run tomcat:
# on releases prior to V5R1 systems add
-Djava.version=1.3
# to debug use -debug -Djava.compiler=NONE
# set -Duser.dir appropriately, it becomes the
relative base for file I/O
# on larger sites, consider upping the memory from
64 to something bigger
java -ms64m -Duser.dir="$CATALINA_BASE"
-Dcatalina.base="$CATALINA_BASE"
-Dcatalina.home="$CATALINA_HOME"
org.apache.catalina.startup.Bootstrap "$@" start
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.