Ok... just to be clear, after more testing:

On the same machine, using apache 2.2 mod_proxy_ajp:

1) set ProxyPass to localhost
2) use application server.xml

All works.

Move apache to a different machine.

1) Set ProxyPass to IP or DNS name of tomcat server

Apache gives a 400 and I get no content.

2) Move stock server.xml into place

I get content.

I have no idea what's going on there... any ideas / suggestions?

S.


On Tue, Aug 12, 2008 at 8:45 AM, Stephen Nelson-Smith
<[EMAIL PROTECTED]> wrote:
> I have a server running apache 2.2, configured to proxy to another
> tomcat server, running 6.0.16.  This works fine with the stock
> server.xml, and the webapps, but when I move my own server.xml into
> place, apache reports a 400, and I get no page.
>
> Some background:
>
> * The apache config works in production with Tomcat 6 when running on
> the same machine as tomcat, with "tomcat1" substituted for the IP of
> the virtual host.
> * My server.xml was not originally written by me, and has been handed
> down and modified over the ages.  It was originally from Tomcat 4.1
> * Tomcat works fine in standalone mode - the app works.
>
> I have some questions:
>
> 1) How do I configure logging?  I don't see any information such as
> 200s or 400s anywhere in the logs directory.  I also don't see my
> tomcat1 log file, although I suspect that is because Logger no longer
> works in tomcat 6.  I don't see how to troubleshoot without this
> information
> 2) All I want to happen is for http://loadbalancer/login.jsp to be
> passed to http://tomcat/login.jsp using ajp/1.3.  What is the simplest
> thing that could possibly work?
>
> The configs are:
>
> Apache:
>
> <VirtualHost 192.168.0.1>
> ProxyRequests Off
> <Proxy *>
>    Order deny,allow
>    Allow from all
> </Proxy>
> ProxyPass / ajp://tomcat1:8009/
> ProxyPass /servlet ajp://tomcat1:8009/servlet
> ProxyPass /piston ajp://tomcat1:8009/piston
> ProxyPass /manager ajp://tomcat1:8009/manager
> ProxyPass /link ajp://tomcat1:8009/link
> ProxyPass /ajax ajp://tomcat1:8009/ajax
> ProxyVia on
> </VirtualHost>
>
> Tomcat:
>
> <?xml version='1.0' encoding='ISO-8859-1'?>
> <Server port="8005" shutdown="SHUTDOWN">
>  <Listener className="org.apache.catalina.core.AprLifecycleListener"
> SSLEngine="on" />
>  <Listener className="org.apache.catalina.core.JasperListener" />
>  <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener" />
>  <Listener 
> className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"
> />
>  <GlobalNamingResources>
>    <Resource name="UserDatabase" auth="Container"
>              type="org.apache.catalina.UserDatabase"
>              description="User database that can be updated and saved"
>              factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
>              pathname="conf/tomcat-users.xml" />
>  </GlobalNamingResources>
>  <Service name="Catalina">
>    <Connector port="8080" protocol="HTTP/1.1"
>               connectionTimeout="20000"
>               redirectPort="8443" />
>    <Connector port="8009" protocol="AJP/1.3" redirectPort="8443"
>               enableLookups="false"
>               connectionTimeout="0" disableUploadTimeout="false"
>               proxyName="tomcat1" proxyPort="80"
>               acceptCount="10" bufferSize="2048" compression="off"
>               connectionLinger="-1" connectionUploadTimeout="300000"
>               debug="0" maxKeepAliveRequests="100"
> maxProcessors="500" minProcessors="5"
>               scheme="http" secure="false" serverSocketTimeout="0"
> tcpNoDelay="true"
>               tomcatAuthentication="true"
> useBodyEncodingForURI="true" useURIValidationHack="false"/>
>    <Engine name="Catalina" defaultHost="localhost">
>      <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
>             resourceName="UserDatabase"/>
>      <Host appBase="/home/sites/home/web" liveDeploy="false"
> autoDeploy="false" debug="4" name="tomcat1" >
>        <Alias>tomcat1</Alias>
>        <Context cachingAllowed="true" cookies="true"
> crossContext="true" debug="0" docBase=""  path="" privileged="false"
> reloadable="true" >
>          <Logger className="org.apache.catalina.logger.FileLogger"
> debug="0" directory="logs" prefix="tomcat1" suffix=".txt"
> timestamp="true" verbosity="1"/>
>        </Context>
>      </Host>
>    </Engine>
>  </Service>
> </Server>
>
>
> Thanks,
>
> S.
>

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to