Integrating Tomcat with Apache

Hi there,
I'm really stuck here. I'm trying to integrate Apache with Tomcate. Not having much luck. I have a number of things that aren't quite right. For whatever reason the connector (mod_jk2) between Apache and Tomcat isn't doing its thing. First things first however. I'm not so sure about the log from Tomcat:
17-Jan-2005 3:56:07 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 6517 ms
17-Jan-2005 3:56:08 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
17-Jan-2005 3:56:08 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/5.5.4
17-Jan-2005 3:56:08 PM org.apache.catalina.core.StandardHost start
INFO: XML validation disabled
17-Jan-2005 3:56:14 PM org.apache.catalina.core.ApplicationContext log
INFO: org.apache.webapp.balancer.BalancerFilter: init(): ruleChain: [org.apache.webapp.balancer.RuleChain: [org.apache.webapp.balancer.rules.URLStringMatchRule: Target string: News / Redirect URL: http://www.cnn.com], [org.apache.webapp.balancer.rules.RequestParameterRule: Target param name: paramName / Target param value: paramValue / Redirect URL: http://www.yahoo.com], [org.apache.webapp.balancer.rules.AcceptEverythingRule: Redirect URL: http://jakarta.apache.org]]
17-Jan-2005 3:56:16 PM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
17-Jan-2005 3:56:16 PM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
17-Jan-2005 3:56:17 PM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
17-Jan-2005 3:56:17 PM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
17-Jan-2005 3:56:21 PM org.apache.jk.common.ChannelSocket init
INFO: JK2: ajp13 listening on /0.0.0.0:8009
17-Jan-2005 3:56:21 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/632 config=null
17-Jan-2005 3:56:22 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 14657 ms
Shouldn't this line: INFO: JK2: ajp13 listening on /0.0.0.0:8009
read like this: INFO: JK2: ajp13 listening on /127.0.0.1:8009
or: INFO: JK2: ajp13 listening on /localhost:8009
If I'm right, then how do I make it listen on the localhost address 127.0.0.1?
Please help,
Alan
My configuration files under tomcat are like so:
# file://usr/local/tomcat/conf/jk2.properties
## THIS FILE MAY BE OVERRIDEN AT RUNTIME. MAKE SURE TOMCAT IS STOPED
## WHEN YOU EDIT THE FILE.
## COMMENTS WILL BE LOST
## DOCUMENTATION OF THE FORMAT IN JkMain javadoc.
# Set the desired handler list
# handler.list=apr,request,channelJni
# Override the default port for the socketChannel
# channelSocket.port=8019
# Default:
# channelUnix.file=${jkHome}/work/jk2.socket
# Just to check if the the config is working
# shm.file=${jkHome}/work/jk2.shm
# In order to enable jni use any channelJni directive
# channelJni.disabled = 0
# And one of the following directives:
# apr.jniModeSo=/opt/apache2/modules/mod_jk2.so
# If set to inprocess the mod_jk2 will Register natives itself
# This will enable the starting of the Tomcat from mod_jk2
# apr.jniModeSo=inprocess
# Socket Configuration
channelSocket.port=8009
channelSocket.address=127.0.0.1
channelSocket.maxPort=port+10
# file://usr/local/tomcat/conf/workers.properties
#------ DEFAULT worket list ------------------------------------------
# The workers that your plugins should create and work with
# Add 'inprocess' if you want JNI connector
worker.list=ajp13
# , inprocess
#------ DEFAULT ajp13 WORKER DEFINITION ------------------------------
# Defining a worker named ajp13 and of type ajp13
# Note that the name and the type do not have to match.
worker.ajp13.port=8009
worker.ajp13.host=127.0.0.1
worker.ajp13.type=ajp13
# Specifies the load balance factor when used with
# a load balancing worker.
# Note:
# ----> lbfactor must be > 0
# ----> Low lbfactor means less work done by the worker.
worker.ajp13.lbfactor=50
# Specify the size of the open connection cache.
worker.ajp13.cachesize=10
# file://usr/local/tomcat/conf/workers2.properties
[channel.socket:localhost:8009]
info=Ajp13 forwarding over socket
debug=0
tomcatId=localhost:8009
...

Hi Alan.
I've discovered the exact same problem.... 0.0.0.0 instead of 127.0.0.1
You've obviously not had any replys here, but di you end up working it out on your own?

Similar Messages

  • Hello Friends...About integrating tomcat with apache

    Hello Friends...
    I want to integrate apache with tomcat. using JK connector.
    It is working for red hat 7.3 n 9.
    But it is not working for Red Hat Enterprise ES (Red Hat 3.2.3-47)
    I search for jk connector for Red Hat Enterprise ES.
    Cannot get help..
    Plz. help me
    Isparks

    Hi Alan.
    I've discovered the exact same problem.... 0.0.0.0 instead of 127.0.0.1
    You've obviously not had any replys here, but di you end up working it out on your own?

  • Why integrate Tomcat with Apache?

    What's the reason to integrate Tomcat with Apache? What are the benefits?

    Apache is way faster and more scaleable than Tomcat.
    So if your website provides also static content (pages, pictures) etc this would be the reason.
    Additionally if you have other technology to include, that Tomcat cannot handle (PHP for example) you would do this with Apache, too.

  • Integrate Tomcat with apache

    I need a procedure to check my installation of Tomcat 4.0.3 and it¹s
              integration with apache. I was told I need mod_jk, but I can¹t find it even
              in the source files of tomcat. Any word on where I can find it?
              Any procedures and insights would be greatly appreciated, thank you!
              Tim Best
              [att1.html]
              

    I am ttrying integrate tomcat/aoache on my local machine.But i can able to run html files only.No jsp,servlets.can you tell me how did u configure that.

  • Help! difficulties in using mod_jk.so to combine tomcat with apache

    apache 1.3.19 in rh7.1;
    tomcat 3.2.1;
    i do not know whether i need to complier a mod_jk.so before i configurate both tomcat and apache, right now i only put the mod_jk.so,which download from jakarta.com, into libexec directory. then configurate the server.xml for connector in port 8009 with Ajp13Connector; then edit workers.properties for every items; include the mod_jk.conf-auto in place of tomat-apache-conf-auto
    however, once the apache apachectl start after tomcat boot up; error logged in tomcat.logs.mod_jk.log and apache.logs.error_log both:
    error_log:
    no such fire or directory :error while opening the workers
    (but workers.properties is actually available in the path which set in mod_jk.conf-auto);
    mod_jk.log:
    jk_worker.c :wc_create_worker NULL factory for ajp13*ajp13;
    jk_worker.c(229): build_workder_map failed to crtete workerajp13;
    what is the problem, could you help me?
    frederick

    resovle by edit in mod_jk.conf by manuel.

  • Tomcat with Apache

    Hi,
    I have followed the tutorial on this website to configure tomcat to connect with Apache.
    I am on a CENTOS 5 system.
    Apache was already installed and serving three web sites without problems.
    I wanted to add the ability to work with .jsp files and others.
    I loaded Tomcat with incident and it is running.
    I also loaded mod_jk to connect the two as directed by the tutorial.
    However, I cannot access a .jsp file unless I add the port number 8080 in the location bar along with the url.
    Can someone point me to a good guide for getting this up and running? Or maybe provide some insight in what I might be doing wrong.
    Thank You,
    Mike

    On this website? Which tutorial are you talking about? Apache is in no way related to Sun.
    At least you should read the documentation which come along with the Tomcat Connector: [http://tomcat.apache.org/connectors-doc/].

  • Integrating Tomcat and Apache - typo in the instructions??

    I'm a total newbie at this, but one line in the "Flashguide" instructions I found on Galatea http://galatea.com/flashguides/home looked wierd to me:
    In the instructions for integrating Tomcat 4.0.x to Apache 2.0.x using mod_jk, it states that the mod_jk.so file should go in the APACHE_HOME/libexsec folder.
    Then, further on down in section 5 it says that, for Apache 2.0, one should add the line:
    "LoadModule jk_module modules/mod_jk.so" to the httpd.conf file.
    Shouldn't that be "LoadModule jk_module libexec/mod_jk.so"?? Thats what is says to do for Apache 3.x,
    The Galatea instructions otherwise seem pretty succinct and easy to follow.

    Tomcat 4.0.6 happens to be on the server - and I can't change it (yet). Right now it isn't working in either folder, I am trying to remove this issue as an unknown before looking at other things. Do the math - it'll save about half my time when I try to correct other things.

  • Integrating tomcat with derby

    Hi all,
    Can anyone tell me how to integrate tomcat server with derby? thank you in advance.

    asiridol wrote:
    Hi all,
    Can anyone tell me how to integrate tomcat server with derby? thank you in advance.Standalone it is no different than doing it with any other database.
    Embedded, which I wouldn't think would be exactly ideal, would require more work because I believe you have to 'start' and 'stop' it. That would require hooking into tomcat at some point outside the normal servlet interface.

  • Tomcat vs APache

    I have a few questions I've looked for in the apache and tomcat documentations. The moer I read the more I get confused
    1) Can tomcat be used as a stand alone server?
    2) Why should anyone integrate tomcat with apache?

    1) Yes you can.
    2) If my knoledge about tomcat is correct it is not properly optimized for static content. So normally you put tomcat behind an apache server and set the apache handle the ststic content. and tomcat to handle dynamic content.
    That way you can also get some load off from the tomcat too
    Also tomcat can be intigrated to already existing apache servers to enable servlet/jsps in the server.
    Someware I saw an artical about tomcat being intigrated with IIS to allow servlets in it.

  • Integrating tomcat 5.0.28 with apache web server 2.2

    hi all
    i tried a lot on net but could not get the steps for
    connctivity between tomcat 5.0.28 with apache web server 2.2.
    any one pzl do help me in finding the solution
    pzl do tel me the step by step process for this connectivity
    sus

    hi :-)
    you need jk modules ;-)
    i havent try the integrating the version of apache web
    and tomcat you specify but you can refer to the links below :-)
    gudluck :-)
    http://www.serverwatch.com/tutorials/article.php/2203891
    http://www.onjava.com/lpt/a/2826
    http://raibledesigns.com/tomcat/
    regards,

  • Right problem with apache and tomcat

    Bonjour;
    I use a user login "apache" to stop/start Apache and tomcat. Because never launching apache et tomcat as root.
    But I have the following problem with apache (file error.log) :
    [Tue May  6 17:26:22 2003] [error] Connection "warpConnection" cannot connect
    [Tue May  6 17:26:22 2003] [error] Cannot open connection "warpConnection"
    [Tue May  6 17:27:01 2003] [error] Re-Trying to deploy connections
    As root the error msg does'nt exists (lost)
    Best regards;
    A+;

    Run it from the shell to see whats wrong:
    # httpd

  • Servlet mapping with Apache + Tomcat

    I'm trying to set up my servlet with apache + Tomcat(3.2.3), and i'm using mod_jk as the Tomcat-Apache plug-in.
    The HelloWorld servlet that comes with the examples app worked fine at: http://localhost/examples/servlet/HelloWorldExample,
    but how do I change the configurations, so that it can be invoked at:
    http://localhost/examples/HelloWorldExample ?
    It appears to me that '/servlet/' is the default prefix for Tomcat's RequestInterceptor, there is no way to get around that.
    Any insights will be greatly appreciated, thanks!
    Elaine

    hi
    Try this:
    add below code in web.xml file in examples/WEB-INF
    F directory
    <servlet-mapping>
    <servlet-name>
    HelloWorldExample
    </servlet-name>
    <url-pattern>
    /HelloWorldExample
    </url-pattern>
    </servlet-mapping>
    Thanks for the reply, the web.xml is already set up this way, in fact, I'm able to invoke the servlet through tomcat(running on port 8080): http://localhost:8080/examples/HelloWorldExample,
    tomcat reads the web.xml without any problems.
    The problem comes from Apache(port 80), http://localhost:80/examples/HelloWorldExample wouldn't work, only http://localhost:80/examples/servlet/HelloWorldExample works.
    It appears to me that when requests are relayed from Apache to tomcat, you need to tell tomcat that you intend to invoke a servlet by prefixing '/servlet/', if you look in the server.xml, it has
    <RequestInterceptor
    className="org.apache.tomcat.request.InvokerInterceptor"
    debug="0" prefix="/servlet/" />
    I've tried to change this to something else, it didn't seem to make any difference.

  • Client authentication with apache+mod_ssl+tomcat

    Hello.
    My question is a little bit off topic.
    I try to read client certificates with request.getAttribute("javax.servlet.request.X509Certificate"), but the result is always null.
    Probably it's null because I have nothing on the session. So my tomcat does not have the certificate. I use apache + mod_ssl + mod_jk + tomcat.
    And here is my question: how did you configured apache and tomcat so that tomcat has the client cert ?
    Thanks.

    usually u generate a keystore for client, and mention that in ur SSL connector of tomcat
    in apache, we need to configure things in ssl.conf

  • The tab is bad with apache web server and tomcat

    the tab not run with apache web server + tomcat.
    It is very bad..

    Fijate que solo he estado experimentando con JSC, no he tenido oportunidad de poner nada en producci�n usando la combinaci�n Apache Web Server y Tomcat JSP container y no cuento en �ste momento con �sta configuraci�n para probar.
    Nosotros (en donde trabajo) usamos IBM Web Server (basado en Apache Web Server 2), IBM Websphere 6 y las aplicaciones JSF en producci�n est�n hechas con Rational Web Developer.
    Ahora he estado muy ocupado con un proyecto urgente, si tengo alg�n tiempo libre la semana entrante tratar� de probar tu combinaci�n (no te prometo nada) pero para ello necesito que me digas las versiones que est�s usando de Apache Web Server y de Tomcat, como est�s enlazando entre ambos con un m�dulo o con ProxyPass y mejor si me mandas el httpd.conf.
    Saludos.

  • Integrating Apex with Cocoon (does it make pdf from taking data from DB)

    Friends,
    I integrated Apex with appache with cocoon. Its working fine with reports but i want it to work with form on a table or view.The steps below which i have followed for integrating Apex with Cocoon
    Steps of pdf Printing of Report with cocoon:
    1) Download and unzip the following needed files in D:\Apex_fop directory.
    2) Open your command prompt .
    Change the directory to D:\Apex_fop\cocoon-2.1.11.
    Set the Java_Home environment variable as: set JAVA_HOME= C:\Program Files\Java\jdk1.5.0_21
    then type build war
    3) After getting the prompt back as D:>Apex_fop>cocoon-2.1.11>
    Copy coocon.war file from the folder D:\Apex_fop\cocoon-2.1.11\build\cocoon.
    Paste this file into webapps subdirectory in main tomcat directory having path as D:\APEX_FOP\apache-tomcat-6.0.26\webapps.....place it in the top
    level of webapps directory.
    4) Now just startup tomcat as D:>APEX_FOP>apache-tomcat-6.0.26>bin>startup.bat
    The cocoon.war file will automatically uncompressed as directory.
    5) To change the port of apache tomcat , edit apache-tomcat-6.0.26\conf\server.xml & change port attribute of Connector element from 8080 to 8181.
    Just check whether Tomcat is running or not as http://localhost:8181/
    & to check cocoon type http://localhost:8181/cocoon/
    6) Now copy fop_post directory & paste it undes new cocoon directory in webapps having path as D:\APEX_FOP\apache-tomcat-6.0.26\webapps
    \cocoon.
    7) Now you need to do some apex settings as follows:
    In APEX, just log in as ADMIN into apex/apex_admin and went to Instance Settings and did the following:
    - Print Serverr: Standard Support
    - Print Server Protocol: HTTP
    - Print Server Host Address:localhost
    - Print Server Port: 8181
    - Print Server Script: /cocoon/fop_post
    In your APEX application, in the Regions section, Click on the Print link next to your report and do the following settings:
    - Enable Report Printing: Yes
    - Link Label: Print
    - Response Header: Report Settings
    - View File As: Attachment
    - Output Format: PDF
    - Report Layout: Default Report Layout
    - Print URL: f?p=&APP_ID.:1:&SESSION.:FLOW_XMLP_OUTPUT_R1063230002781575
    8) Open up the Report Page and click Print , You will get the pdf report.
    But my requirement is bit different. I have made form on a table or view , so when i am submitting my form the record is getting updated in my database and at the same time a new button is appearing at same page as i have branched it in same page. The new button name is print. I want when i click this print button it should print the record which submitted recently. How can i enable the print functionality on form. Its simple in report but how can it be done on form?
    Looking forward for this to know wthr it is achievable or not and if yes what all are the ways?
    Thanks in advance for all who is going to post here and to them also who is giving their time in reading my thread
    Regards
    Adi
    Edited by: Adi's on Mar 23, 2010 8:54 PM
    Edited by: Adi's on Mar 23, 2010 8:54 PM

    You could redirect to a report page instead of to the form page. Then simply print the report.
    This makes sense. You would have one page for entering the data and another page for displaying and printing it.

Maybe you are looking for

  • Custom Paper Size : Migrating from 6i to 10g report server engine

    Hi, pardon my bad english !! I'm studying to migrate form/reports 6i to 10G. In report 6i we have reports with custom paper size ("A5" format that is half of "A4", 15x21cm). In report server 6i environment (Win2000 server) we have done this configura

  • How can I uninstall my Photoshop CS 3 from my Mac, without an uninstaller?

    How can I uninstall my Photoshop CS3 from my Mac OS Extended (Journaled)?   It has never opened, since I increased the Mac's capacity to 2 TB.  Now I want to throw the Photoshop CS3 away and get a brand new Photoshop CS5.    There does not seem to be

  • What are the do's and dont's in the design phase of abap oo classes

    Hi , Previously in C++ i use to code in OO . But that was as a beginner some years ago. Now i am doing ABAP OO for past few months . I am somewhat familiar with OO concepts. Lets take local classes in a program. I am facing difficulty in design phase

  • Problem with pre-loader and video playback

    Hi! I've got a real problem - I managed to put together a pre-loader OK but it doesn't load the entire movie. Instead it loads a little bit and tries to stream, but it stutters of course because the server can't cope. So what I want to do is: - make

  • After the last update, Thunderbird can not get mail from RCN POP3?

    On a WINDOWS 7 PC (Dell Inspiron 15) Thunderbird was automatically updated June 12. After the update it can not get my email from my service provider (RCN). It seems to connect with pop.rcn.com but then it hangs, and no email comes. Your troubleshoot