Thanks Andre.
I fixed the file and now my code looks like as follows but still my servlets
are not being called. Basically apache is not passing requests to tomcat,
only Alias is working but not JkMount

*So now my worker's file looks like this, i  added testWorker*

worker.list=wlb,jkstatus,testWorker

worker.testWorker.type=ajp13
worker.testWorker.host=localhost
worker.testWorker.port=8009

worker.ajp13w.type=ajp13
worker.ajp13w.host=localhost
worker.ajp13w.port=8010

worker.wlb.type=lb
worker.wlb.balance_workers=ajp13w

worker.jkstatus.type=status

*My Server.xml of Tomcat looks like this*

<Connector className="org.apache.ajp.tomcat4.Ajp13Connector"
port="8009" minProcessors="5" maxProcessors="75"
acceptCount="10" debug="0"/>

*jk.conf loks like this(its in conf.d dir)
*
LoadModule jk_module modules/mod_jk.so

JkWorkersFile /etc/httpd/conf/workers.properties


*and httpd.conf looks like this

*
Include conf.d/*.conf


JkLogFile libexec/mod_jk.log
JkLogLevel debug
Alias /ex /usr/java/tomcat-5.5/webapps/servlets-examples
JkMount /ex/servlet/* testWorker
JkMount /temp/*.jsp testWorker
<Location "/usr/java/tomcat-5.5/webapps/examples/WEB-INF/">
AllowOverride None
deny from all
</Location>

*Still a Problem*

When i access www.jaatmusic.com/ex  <http://www.jaatmusic.com/ex>(try this
link please), it shows me the index page of my application(servlet-example)
which is a index.html page.So this step work fine. That means it usage the
Alias thing(Alias /ex /usr/java/tomcat-5.5/webapps/servlets-examples)
Now from this page there are links to invoke some servlet examples
http://www.jaatmusic.com/ex/servlet/HelloWorldExample, this link doesn't
work. As per my understanding it should have worked because of this
line - *JkMount
/ex/servlet/* testWorker*

When i access above link i got follwoing in apache log files
*file not exists usr/java/tomcat-5.5/webapps/servlets-examples/servlet,
referer: http://www.jaatmusic.com/ex/
*
and jk mod log says
* missing uri map for jaatmusic.com:/ex/servlet/HelloWorldExample*
but i have defined it *JkMount /ex/servlet/* testWorker

*and there is no log in tomcat as tomcat has not been hit.

i dont know what i am missing everything seems to be ok now but still not
working

also in my web.xml servlet is defined like this

    <servlet>
        <servlet-name>HelloWorldExample</servlet-name>
        <servlet-class>HelloWorldExample</servlet-class>
    </servlet>
    <servlet-mapping>
        <servlet-name>HelloWorldExample</servlet-name>
        <url-pattern>*/servlet/HelloWorldExample*</url-pattern>
    </servlet-mapping>

Please help.

Thanks,
Ravi.

On Sat, Jul 19, 2008 at 8:25 PM, André Warnier <[EMAIL PROTECTED]> wrote:

> Ravi Sharma wrote:
> [...]
>
> I'm not as competent as Rainer, but your problem may be here :
>
>>
>> worker.list=wlb,jkstatus,testWorker
>>
>
> and here
>
>  worker.ajp13w.type=ajp13
>> worker.ajp13w.host=localhost
>> worker.ajp13w.port=8009
>>
>>
> In other words, in the "workers list", you are mentioning the worker
> "testWorker", but in the following "worker.*" lines, you don't mention
> "testWorker", but "ajp13w".
>
> Maybe you want to change these 3 lines to
>  worker.testWorker.type=ajp13
>  worker.testWorker.host=localhost
>  worker.testWorker.port=8009
> and try again ?
>
>
> Personally, I would also change this :
>
>  <Location "/examples/WEB-INF/">
>> AllowOverride None
>> deny from all
>> </Location>
>>
>>  to this :
>
> <Directory "/var/www/xyz/examples/WEB-INF"> (*)
>  Order allow,deny
>  deny from all
> </Directory>
>
> (*) replace this by the real disk path to WEB-INF
>
> the reason being that, if you are under Windows e.g., someone requesting
> the URI "/examples/web-inf" would get to the directory, because it does not
> match exactly the <Location>, and for Windows the directory path is
> case-insensitive, so Apache will serve it.
> See here :
> http://httpd.apache.org/docs/2.2/mod/core.html#location
>
>
>
> ---------------------------------------------------------------------
> 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