tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@shareowner.com
Subject RE: Tomcat and Apache
Date Thu, 06 Feb 2003 15:33:13 GMT
So how does ssl play in this checklist?

Regards,
 
 
PQ
 
"This Guy Thinks He Knows Everything"
"This Guy Thinks He Knows What He Is Doing"

-----Original Message-----
From: Turner, John [mailto:JTurner@AAS.com] 
Sent: February 6, 2003 10:06 AM
To: 'Tomcat Users List'
Subject: RE: Tomcat and Apache


OK, is "999.99.999.99" == "localhost"?  You have "localhost" as your Host in
server.xml.  Are you just being paranoid by disguising "localhost" with
"999.99.999.99" or are you actually using some other value besides
"localhost" in your request URL?

Basically, everything is a chain.  One missing piece in the chain, and it
doesn't work.

- request www.host.com/avcweb/servlet/MyClass
- Apache scans httpd.conf, looking for a match for www.host.com.  If none
found, uses global defaults.  If VirtualHost found, checks ServerName
- ServerName = no match, continue
- ServerName = match, scan VirtualHost directives
- does VirtualHost have JkMount? Check URL against JkMount
- if match to JkMount, lookup worker
- make worker connection to Tomcat
- send request to Tomcat
- Tomcat receives request on connector
- looks for Host match for www.host.com
- no match, falls to "defaultHost"
- match, looks for Context to match URL
- find Context match, try to resolve the rest of the URL into a valid,
available servlet, and serve content
- no Context match, 404 or some other error.

So, things to check:

- the VirtualHost in httpd.conf that you expect to use is the one actually
being used
- it's ServerName is the one in the URL
- there's a valid JkMount
- there's a definition for the worker used in JkMount in workers.properties
- the Tomcat host configured in workers.properties is available on port 8009
(or some other port as long as it is consistent)
- Tomcat has a Host to match the one in the URL (and the one in ServerName)
- Tomcat has a Context to match the URL
- Tomcat has a valid servlet mapping, explicit or implicit, for the request

You probably know all of this, but it is hard for me to see the big picture
just by getting config snippets, so I am trying to provide a description of
the "debugging method" that I would use if I was having the same problem.

HTH

John


> -----Original Message-----
> From: Richard Johnstone
> [mailto:Richard.Johnstone@appleyard-contracts.co.uk]
> Sent: Thursday, February 06, 2003 9:53 AM
> To: tomcat-user@jakarta.apache.org
> Subject: RE: Tomcat and Apache
> 
> 
> Nope. Do I need to?
> I didn't realise I need to as the page loaded using
> http://999.99.999.99:8080/avcweb/servlet/MyClass, it's just
> http://999.99.999.99/avcweb/servlet/MyClass that doesn't seem to work
> 
> >>> JTurner@AAS.com 02/06/03 02:35pm >>>
> 
> Did you map that servlet in web.xml??
> 
> John
> 
> 
> > -----Original Message-----
> > From: Richard Johnstone
> > [mailto:Richard.Johnstone@appleyard-contracts.co.uk] 
> > Sent: Thursday, February 06, 2003 9:28 AM
> > To: tomcat-user@jakarta.apache.org 
> > Subject: RE: Tomcat and Apache
> > 
> > 
> > OK, took all the stuff out of httpd.conf so all that is in 
> > there in the
> > "loadmodule" and "include"
> > 
> > In mod_jk.conf it has
> > 
> >     JkMount /avcweb ajp13
> >     JkMount /avcweb/* ajp13
> > 
> > So to call I am trying
> > 
> > http://999.99.999.99/avcweb/servlet/MyClass 
> > 
> > Still no luck
> > 
> > >>> JTurner@AAS.com 02/06/03 01:27pm >>>
> > 
> > Well, what URL are you using?
> > 
> > What ServerName are those JkMount statements tied to?
> > 
> > If you're doing an Include of mod_jk.conf, you shouldn't have
> anything
> > in
> > httpd.conf but the "LoadModule" line and the "Include" line.
> > 
> > My guess is your manually entered JK config in httpd.conf is
> > conflicting
> > with the generated config.
> > 
> > Looks also like you are using Solaris, perhaps my Solaris HOWTO can
> > help:
> > 
> > http://www.johnturner.com/howto 
> > 
> > John
> > 
> > 
> > > -----Original Message-----
> > > From: Richard Johnstone
> > > [mailto:Richard.Johnstone@appleyard-contracts.co.uk] 
> > > Sent: Thursday, February 06, 2003 6:02 AM
> > > To: tomcat-user@jakarta.apache.org 
> > > Subject: Tomcat and Apache
> > > 
> > > 
> > > I apologise for sending this as I know there are about 50 
> > > posts daily on
> > > this subject but I can't get the 2 of these to link.
> > > I have checked the archives and help docs and everything 
> > > seems in place
> > > but when I call my servlet without the 8080 port I get 
> > > nothing. Looking
> > > at the apache logs it says 
> > > 
> > > /opt/webFrontEnd/examples/servlet/avc.web.Clients.ClientsHomePage
> > > 
> > > The /opt/webfrontend is my document root for apache
> > > 
> > > There is no lines in the tomcat logs so apache isn't even posting
> to
> > > tomcat
> > > 
> > > I must have missed something simple but I can't see what it is.
> > > Any Help Please
> > > 
> > > Here is what I have set up in the conf files
> > > 
> > > SERVER.XML
> > > 
> > > <Server port="8005" shutdown="SHUTDOWN" debug="0">
> > > <Listener className="org.apache.ajp.tomcat4.config.ApacheConfig"
> > >           modJk="/opt/apache/libexec/mod_jk.so"
> > >           jkLog="/opt/apache/logs/mod_jk.log" jkDebug="info"
> > >  />
> > > 
> > >       <Host name="localhost" debug="0" appBase="webapps"
> > > unpackWARs="true">
> > >       <Listener
> > className="org.apache.ajp.tomcat4.config.ApacheConfig"
> > > append="true" />
> > > 
> > > 
> > > HTTPD.CONF
> > > 
> > > Include /opt/tomcat-4.0.6/conf/auto/mod_jk.conf
> > > LoadModule jk_module /opt/apache/libexec/mod_jk.so
> > > AddModule mod_jk.c
> > > 
> > > JkWorkersFile /opt/tomcat-4.0.6/conf/jk/workers.properties
> > > JkLogFile /opt/apache/logs/mod_jk.log
> > > JkLogLevel info
> > > 
> > > JkMount /* ajp13
> > > JkMount /examples/* ajp13
> > > JkMount /avcweb/* ajp13
> > > 
> > > WORKERS.PROPERTIES
> > > 
> > > workers.tomcat_home=/opt/tomcat-4.0.6
> > > workers.java_home=/opt/jdk1.4.1
> > > ps=/
> > > worker.list=ajp13
> > > 
> > > worker.ajp13.port=8009
> > > worker.ajp13.host=localhost 
> > > worker.ajp13.type=ajp13
> > > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org 
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> > 
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org 
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message