Re: JSP not forwarded to Tomcat

2003-01-28 Thread Pascal Robert
I think it's a context problem, but I don't know how to fix it.

I have this directory:

/Library/WebServer/Documents/clic-agent.com

Inside this directory, I have a mix of HTML and JSP files, and one WEB-INF
directory (with the default 'lib' and 'classes' directories).  I DON'T have
a ROOT directory, so '/Library/.../clic-agent.com' is the appBase.

Inside server.xml, I have this Host directive:

--
Service name=Tomcat-Apache-modjk
Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
modJk=/usr/libexec/httpd/mod_jk.so
jkDebug=info
workersConfig=/usr/local/tomcat-4/conf/jk/workers.properties
jkLog=/usr/local/tomcat-4/logs/mod_jk.log
noRoot=true
forwardAll=false/

Host name=test.clic-agent.com debug=4
appBase=/Library/WebServer/Documents/clic-agent.com
   unpackWARs=true autoDeploy=true

Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
   append=true /
--

Inside httpd.conf, I have this VirtualHost:

--
VirtualHost *
ServerName test.clic-agent.com
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
DocumentRoot /Library/WebServer/Documents/clic-agent.com
/VirtualHost
--

Now, I have a JSP file called 'liste.jsp' inside, so the URL should be:

http://test.clic-agent.com/liste.jsp

I get an good old 'Internal Server Error' when I try this URL.  In
mod_jk.log, I get:

--
[jk_uri_worker_map.c (460)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (477)]: Attempting to map URI '/liste.jsp'
[jk_uri_worker_map.c (558)]: jk_uri_worker_map_t::map_uri_to_worker, Found a
suffix match ajp13 - *.jsp
[jk_worker.c (132)]: Into wc_get_worker_for_name ajp13
[jk_worker.c (136)]: wc_get_worker_for_name, done did not found a worker
--
 
I try to add:

[uri:/*.jsp]

To my workers.properties file, same error in the log file.

 This is a bug with either Tomcat or the Jk (or Jk2) connector.  I also had
 this problem and I have reported it as a bug to the Tomcat-Developers group.
 
 In order to work around this fix ... do NOT rely upon the httpd.conf file in
 order to make your vhosts/web-apps work.
 
 Instead ... make sure you create uri's in the workers2.properties file (if
 you are using Jk2).  Look at how they declare the /examples and do this
 for your own vhosts.
 
 The /test is the location of where you have your files.
 
 If you need any more information, please let me know.Thanks.
 
 [uri:/test]
 info=Example webapp in the default context.
 context=/test
 debug=0
 
 [uri:/test/*.jsp]
 info=Extension mapping
 
 [uri:/test/*]
 info=Map the whole webapp
 
 - Original Message -
 From: Pascal Robert [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Monday, January 27, 2003 10:57 AM
 Subject: JSP not forwarded to Tomcat
 
 
 Hi list,
 
 First, the setup:
 
 - Mac OS X 10.2
 - Tomcat/4.1.18
 - Apache/1.3.27
 - mod_jk-1.3.27.so (build from OS X from Jakarta's site), renamed to
 mod_jk.so
 
 I tried to get some Virtual Host to work with Tomcat (the webapps for each
 VirtualHost are outside Tomcat's directory).  Instead of getting the
 generated JSP, I get the source, just like if the JSP was sent as
 text/plain
 and was not parsed by Tomcat.  If I look at the 'mod_jk.log' log, I see
 requests for static HTML files, but I don't see any log information for my
 JSP files, so it look like mod_jk don't handle them, even if they should.
 
 Apache's config:
 
 
 LoadModule jk_modulelibexec/httpd/mod_jk.so
 AddModule mod_jk.c
 
 JkLogFile /usr/local/tomcat-4/logs/mod_jk.log
 JkLogLevel debug
 JkWorkersFile /usr/local/tomcat-4/conf/jk/workers.properties
 
 VirtualHost *
 ServerName my.host
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 DocumentRoot /path/to/the/web/app
 /VirtualHost
 
 
 Tomcat's config (server.xml):
 
 Host name=my.host debug=1
 appBase=/path/to/the/web
 unpackWARs=true autoDeploy=true
 
 Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
 append=true /
 
 Valve className=org.apache.catalina.valves.AccessLogValve
 directory=logs
 prefix=clic_agent_log.
 suffix=.txt
 pattern=common/
 
 Logger className=org.apache.catalina.logger.FileLogger
 directory=logs
 prefix=clic_agent_catalina_log.
 suffix=.txt
 timestamp=true/
 
 Context path= docBase=app debug=1/
 /Host
 
 
 
 
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 
 


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: JSP not forwarded to Tomcat

2003-01-28 Thread Turner, John

OK, you told us the Host and the appBase, what do you have for Context and
docBase?

John


 -Original Message-
 From: Pascal Robert [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, January 28, 2003 7:37 AM
 To: Tomcat Users List
 Cc: Tom Holmes Jr.
 Subject: Re: JSP not forwarded to Tomcat
 
 
 I think it's a context problem, but I don't know how to fix it.
 
 I have this directory:
 
 /Library/WebServer/Documents/clic-agent.com
 
 Inside this directory, I have a mix of HTML and JSP files, 
 and one WEB-INF
 directory (with the default 'lib' and 'classes' directories). 
  I DON'T have
 a ROOT directory, so '/Library/.../clic-agent.com' is the appBase.
 
 Inside server.xml, I have this Host directive:
 
 --
 Service name=Tomcat-Apache-modjk
 Listener 
 className=org.apache.ajp.tomcat4.config.ApacheConfig
 modJk=/usr/libexec/httpd/mod_jk.so
 jkDebug=info
 
 workersConfig=/usr/local/tomcat-4/conf/jk/workers.properties
 jkLog=/usr/local/tomcat-4/logs/mod_jk.log
 noRoot=true
 forwardAll=false/
 
 Host name=test.clic-agent.com debug=4
 appBase=/Library/WebServer/Documents/clic-agent.com
unpackWARs=true autoDeploy=true
 
 Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
append=true /
 --
 
 Inside httpd.conf, I have this VirtualHost:
 
 --
 VirtualHost *
 ServerName test.clic-agent.com
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 DocumentRoot /Library/WebServer/Documents/clic-agent.com
 /VirtualHost
 --
 
 Now, I have a JSP file called 'liste.jsp' inside, so the URL 
 should be:
 
 http://test.clic-agent.com/liste.jsp
 
 I get an good old 'Internal Server Error' when I try this URL.  In
 mod_jk.log, I get:
 
 --
 [jk_uri_worker_map.c (460)]: Into 
 jk_uri_worker_map_t::map_uri_to_worker
 [jk_uri_worker_map.c (477)]: Attempting to map URI '/liste.jsp'
 [jk_uri_worker_map.c (558)]: 
 jk_uri_worker_map_t::map_uri_to_worker, Found a
 suffix match ajp13 - *.jsp
 [jk_worker.c (132)]: Into wc_get_worker_for_name ajp13
 [jk_worker.c (136)]: wc_get_worker_for_name, done did not 
 found a worker
 --
  
 I try to add:
 
 [uri:/*.jsp]
 
 To my workers.properties file, same error in the log file.
 
  This is a bug with either Tomcat or the Jk (or Jk2) 
 connector.  I also had
  this problem and I have reported it as a bug to the 
 Tomcat-Developers group.
  
  In order to work around this fix ... do NOT rely upon the 
 httpd.conf file in
  order to make your vhosts/web-apps work.
  
  Instead ... make sure you create uri's in the 
 workers2.properties file (if
  you are using Jk2).  Look at how they declare the 
 /examples and do this
  for your own vhosts.
  
  The /test is the location of where you have your files.
  
  If you need any more information, please let me know.Thanks.
  
  [uri:/test]
  info=Example webapp in the default context.
  context=/test
  debug=0
  
  [uri:/test/*.jsp]
  info=Extension mapping
  
  [uri:/test/*]
  info=Map the whole webapp
  
  - Original Message -
  From: Pascal Robert [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Monday, January 27, 2003 10:57 AM
  Subject: JSP not forwarded to Tomcat
  
  
  Hi list,
  
  First, the setup:
  
  - Mac OS X 10.2
  - Tomcat/4.1.18
  - Apache/1.3.27
  - mod_jk-1.3.27.so (build from OS X from Jakarta's site), 
 renamed to
  mod_jk.so
  
  I tried to get some Virtual Host to work with Tomcat (the 
 webapps for each
  VirtualHost are outside Tomcat's directory).  Instead of 
 getting the
  generated JSP, I get the source, just like if the JSP was sent as
  text/plain
  and was not parsed by Tomcat.  If I look at the 
 'mod_jk.log' log, I see
  requests for static HTML files, but I don't see any log 
 information for my
  JSP files, so it look like mod_jk don't handle them, even 
 if they should.
  
  Apache's config:
  
  
  LoadModule jk_modulelibexec/httpd/mod_jk.so
  AddModule mod_jk.c
  
  JkLogFile /usr/local/tomcat-4/logs/mod_jk.log
  JkLogLevel debug
  JkWorkersFile /usr/local/tomcat-4/conf/jk/workers.properties
  
  VirtualHost *
  ServerName my.host
  JkMount /*.jsp ajp13
  JkMount /servlet/* ajp13
  DocumentRoot /path/to/the/web/app
  /VirtualHost
  
  
  Tomcat's config (server.xml):
  
  Host name=my.host debug=1
  appBase=/path/to/the/web
  unpackWARs=true autoDeploy=true
  
  Listener 
 className=org.apache.ajp.tomcat4.config.ApacheConfig
  append=true /
  
  Valve className=org.apache.catalina.valves.AccessLogValve
  directory=logs
  prefix=clic_agent_log.
  suffix=.txt
  pattern=common/
  
  Logger className=org.apache.catalina.logger.FileLogger
  directory=logs
  prefix=clic_agent_catalina_log.
  suffix=.txt
  timestamp=true/
  
  Context path= docBase=app debug

Re: JSP not forwarded to Tomcat

2003-01-28 Thread Pascal Robert
Ok, I got it to work with:

- workers.properties :
---
worker.list=test
worker.test.port=8009
worker.test.host=test.clic-agent.com
worker.test.type=ajp13
---

- httpd.conf:
---
ServerName test.clic-agent.com
JkMount /*.jsp test
JkMount /servlet/* test
---

- server.xml
---
...
Connector className=org.apache.ajp.tomcat4.Ajp13Connector
   port=8009 minProcessors=5 maxProcessors=75
   acceptCount=10 debug=0 /
...
Host name=test.clic-agent.com debug=4
appBase=/Library/WebServer/Documents/clic-agent.com
   unpackWARs=true autoDeploy=true
...
Context path= docBase= debug=4/
...
---

Thanks to all!


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




JSP not forwarded to Tomcat

2003-01-27 Thread Pascal Robert
Hi list,

First, the setup:

- Mac OS X 10.2
- Tomcat/4.1.18
- Apache/1.3.27
- mod_jk-1.3.27.so (build from OS X from Jakarta's site), renamed to
mod_jk.so

I tried to get some Virtual Host to work with Tomcat (the webapps for each
VirtualHost are outside Tomcat's directory).  Instead of getting the
generated JSP, I get the source, just like if the JSP was sent as text/plain
and was not parsed by Tomcat.  If I look at the 'mod_jk.log' log, I see
requests for static HTML files, but I don't see any log information for my
JSP files, so it look like mod_jk don't handle them, even if they should.

Apache's config:


LoadModule jk_modulelibexec/httpd/mod_jk.so
AddModule mod_jk.c

JkLogFile /usr/local/tomcat-4/logs/mod_jk.log
JkLogLevel debug
JkWorkersFile /usr/local/tomcat-4/conf/jk/workers.properties

VirtualHost *
ServerName my.host
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
DocumentRoot /path/to/the/web/app
/VirtualHost 


Tomcat's config (server.xml):

Host name=my.host debug=1
appBase=/path/to/the/web
unpackWARs=true autoDeploy=true
   
Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
append=true /

Valve className=org.apache.catalina.valves.AccessLogValve
directory=logs
prefix=clic_agent_log.
suffix=.txt
pattern=common/

Logger className=org.apache.catalina.logger.FileLogger
directory=logs
prefix=clic_agent_catalina_log.
suffix=.txt
timestamp=true/

Context path= docBase=app debug=1/
/Host

   



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: JSP not forwarded to Tomcat

2003-01-27 Thread Turner, John

What's your workers.properties file look like?  Do you have a connector
listening for JK requests from Apache?

John


 -Original Message-
 From: Pascal Robert [mailto:[EMAIL PROTECTED]]
 Sent: Monday, January 27, 2003 10:57 AM
 To: [EMAIL PROTECTED]
 Subject: JSP not forwarded to Tomcat
 
 
 Hi list,
 
 First, the setup:
 
 - Mac OS X 10.2
 - Tomcat/4.1.18
 - Apache/1.3.27
 - mod_jk-1.3.27.so (build from OS X from Jakarta's site), renamed to
 mod_jk.so
 
 I tried to get some Virtual Host to work with Tomcat (the 
 webapps for each
 VirtualHost are outside Tomcat's directory).  Instead of getting the
 generated JSP, I get the source, just like if the JSP was 
 sent as text/plain
 and was not parsed by Tomcat.  If I look at the 'mod_jk.log' 
 log, I see
 requests for static HTML files, but I don't see any log 
 information for my
 JSP files, so it look like mod_jk don't handle them, even if 
 they should.
 
 Apache's config:
 
 
 LoadModule jk_modulelibexec/httpd/mod_jk.so
 AddModule mod_jk.c
 
 JkLogFile /usr/local/tomcat-4/logs/mod_jk.log
 JkLogLevel debug
 JkWorkersFile /usr/local/tomcat-4/conf/jk/workers.properties
 
 VirtualHost *
 ServerName my.host
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 DocumentRoot /path/to/the/web/app
 /VirtualHost 
 
 
 Tomcat's config (server.xml):
 
 Host name=my.host debug=1
 appBase=/path/to/the/web
 unpackWARs=true autoDeploy=true

 Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
 append=true /
 
 Valve className=org.apache.catalina.valves.AccessLogValve
 directory=logs
 prefix=clic_agent_log.
 suffix=.txt
 pattern=common/
 
 Logger className=org.apache.catalina.logger.FileLogger
 directory=logs
 prefix=clic_agent_catalina_log.
 suffix=.txt
 timestamp=true/
 
 Context path= docBase=app debug=1/
 /Host
 
    
 
 
 
 --
 To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: JSP not forwarded to Tomcat

2003-01-27 Thread Tom Holmes Jr.
This is a bug with either Tomcat or the Jk (or Jk2) connector.  I also had
this problem and I have reported it as a bug to the Tomcat-Developers group.

In order to work around this fix ... do NOT rely upon the httpd.conf file in
order to make your vhosts/web-apps work.

Instead ... make sure you create uri's in the workers2.properties file (if
you are using Jk2).  Look at how they declare the /examples and do this
for your own vhosts.

The /test is the location of where you have your files.

If you need any more information, please let me know.Thanks.

[uri:/test]
info=Example webapp in the default context.
context=/test
debug=0

[uri:/test/*.jsp]
info=Extension mapping

[uri:/test/*]
info=Map the whole webapp

- Original Message -
From: Pascal Robert [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, January 27, 2003 10:57 AM
Subject: JSP not forwarded to Tomcat


 Hi list,

 First, the setup:

 - Mac OS X 10.2
 - Tomcat/4.1.18
 - Apache/1.3.27
 - mod_jk-1.3.27.so (build from OS X from Jakarta's site), renamed to
 mod_jk.so

 I tried to get some Virtual Host to work with Tomcat (the webapps for each
 VirtualHost are outside Tomcat's directory).  Instead of getting the
 generated JSP, I get the source, just like if the JSP was sent as
text/plain
 and was not parsed by Tomcat.  If I look at the 'mod_jk.log' log, I see
 requests for static HTML files, but I don't see any log information for my
 JSP files, so it look like mod_jk don't handle them, even if they should.

 Apache's config:

 
 LoadModule jk_modulelibexec/httpd/mod_jk.so
 AddModule mod_jk.c

 JkLogFile /usr/local/tomcat-4/logs/mod_jk.log
 JkLogLevel debug
 JkWorkersFile /usr/local/tomcat-4/conf/jk/workers.properties

 VirtualHost *
 ServerName my.host
 JkMount /*.jsp ajp13
 JkMount /servlet/* ajp13
 DocumentRoot /path/to/the/web/app
 /VirtualHost
 

 Tomcat's config (server.xml):
 
 Host name=my.host debug=1
 appBase=/path/to/the/web
 unpackWARs=true autoDeploy=true

 Listener className=org.apache.ajp.tomcat4.config.ApacheConfig
 append=true /

 Valve className=org.apache.catalina.valves.AccessLogValve
 directory=logs
 prefix=clic_agent_log.
 suffix=.txt
 pattern=common/

 Logger className=org.apache.catalina.logger.FileLogger
 directory=logs
 prefix=clic_agent_catalina_log.
 suffix=.txt
 timestamp=true/

 Context path= docBase=app debug=1/
 /Host

 



 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]