LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-08-2004, 07:42 PM   #1
blakeless
LQ Newbie
 
Registered: Sep 2003
Posts: 28

Rep: Reputation: 15
Anybody know how to install Tomcat4 with Apache on Debian?


Basically, I have installed jdk1.3 so that jsp files can be compiled etc.. however I now need to install Tomcat and link it with Apache and I'm unsure how to do this... Should I install libapache-mod-jk (the connector for Apache 1.3 to the Tomcat Servlet Engine) first and then install tomcat4 and then install tomcat4-web-apps for documentation and examples?? Could anyone help me with this? I'm running Debian Woody..

Cheers Blake
 
Old 09-08-2004, 10:01 PM   #2
CroMagnon
Member
 
Registered: Sep 2004
Location: New Zealand
Distribution: Debian
Posts: 900

Rep: Reputation: 33
Have you tried just apt-get install tomcat4? I would expect that to sort out the config and dependencies for you.
 
Old 09-27-2004, 10:59 PM   #3
jandersen78
LQ Newbie
 
Registered: Sep 2004
Location: Provo, UT
Distribution: Fedora Core 2
Posts: 15

Rep: Reputation: 0
yes, you should install libapache-mod-jk. that's going to add the jk module into the apache modules directory. However, when I set this up I still had a fair amount of work to do. One of the tough parts was getting java installed, I went with blackdown j2sdk1.4. Make sure you export your JAVA_HOME variable and then these are the basic steps I followed... You'll of course want to adapt things to your specific needs/environment but these notes come from a debian install...

* apt-get install tomcat4
* apt-get install libapache-mod-jk
* create file /etc/apache/conf.d/mod_jk.conf with these contents:

Load mod_jk module
LoadModule jk_module /usr/lib/apache/1.3/mod_jk.so
# Declare the module for <IfModule directive>
AddModule mod_jk.c
# Where to find workers.properties
JkWorkersFile /etc/libapache-mod-jk/workers.properties
# Where to put jk logs
JkLogFile /var/log/apache/mod_jk.log
# Set the jk log level [debug/error/info]
JkLogLevel info
# Select the log format
JkLogStampFormat "[%a %b %d %H:%M:%S %Y] "
# JkOptions indicate to send SSL KEY SIZE,
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
# JkRequestLogFormat set the request format
JkRequestLogFormat "%w %V %T"
# Send servlet for context /examples to worker named worker1
JkMount /examples/servlet/* local
# Send JSPs for context /examples to worker named worker1
JkMount /examples/*.jsp local

# Special directive provided by mod_jk that tells Apache to
# forward requests (maybe only JSP requests, I'm not sure) in
# these directories to Tomcat.ajp13 is the protocol used to
# talk to Tomcat.
JkMount /struts-examples/* local

* modify /etc/libapache-mod-jk/workers.properties to create a worker called local as in the following:

# Tomcat and Java configuration
#
workers.tomcat_home=/usr/share/tomcat4
workers.java_home=/usr/lib/j2se/1.4
ps=/
worker.list=local
# Definition for local worker using AJP 1.3
#
worker.local.type=ajp13
worker.local.host=localhost
worker.local.port=8009

* check /etc/tomcat4/server.xml and make sure the ajp13 connector is uncommented
* run apachectl configtest and make sure it looks ok
* restart tomcat first so apache will be able to bind to the process: /etc/init.d/tomcat4 restart
* restart apache: apachectl restart

Last edited by jandersen78; 09-27-2004 at 11:01 PM.
 
Old 11-22-2004, 04:09 AM   #4
treotan
Member
 
Registered: Jun 2004
Posts: 126

Rep: Reputation: 15
Hi! All.

Why we don't directly use the Tomcat httpd server function? Any adventage of Tomcat work with Apache? I have interest to know. Is security concern, speed, easy management....consideration?

Thks
 
Old 11-22-2004, 10:14 AM   #5
jandersen78
LQ Newbie
 
Registered: Sep 2004
Location: Provo, UT
Distribution: Fedora Core 2
Posts: 15

Rep: Reputation: 0
Good question? I don't have any really good answer but I think I read once that apache is more efficient at serving things like images, js and css files... Anyone know? This might be best answered in a separate post...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache 1.3.33 (debian built) and Apache SSL does not respond to the proper ports lqorg_user Linux - Networking 0 11-06-2005 04:11 PM
how to install tomcat4 and how to configure in redhat linux 9.0 rajasekarvr Red Hat 1 04-23-2004 03:35 AM
Tomcat4 and Apache2 rlkiddjr Linux - Software 2 09-04-2003 12:13 PM
How can I map apache to tomcat4? gogo Linux - General 1 07-11-2002 01:25 PM
tomcat4 on OpenBSD neo77777 *BSD 1 06-19-2002 02:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:31 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration