You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by François Andromaque <fr...@sib.fr> on 2001/06/06 09:39:41 UTC

apache don't find my jsp files but works whith examples jsp files

Hello
I've developped a jsp WEB site, so i've my web site directory with the jsp directory which contains my jsp files, the html directory wich contains my html files and the WEB-INF directory which contains the JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my jsp files using apache server, even so i can access via apache to the tomcat jsp examples. What the way to do to make apache to find the jsp files.

i'm getting the following
Error: 404
Location: /jsp/jsp_file.jsp

this is yet the right emplacement of the file

Thanks in advance for your help.



Re: apache don't find my jsp files but works whith examples jsp files

Posted by François Andromaque <fr...@sib.fr>.
i've nothing in the webapp directory, all the Beans, all the the html file
and all the the jsp file are in the directory /my_web_directory
if i try /jsp/requested.jsp or /web_directory_name/jsp/requested.jsp
the requested.jsp is not found.
----- Original Message -----
From: "Jim Cheesman" <jc...@msl.es>
To: <to...@jakarta.apache.org>
Sent: Wednesday, June 06, 2001 10:01 AM
Subject: Re: apache don't find my jsp files but works whith examples jsp
files


>
> > > François Andromaque wrote:
> > >
> > > Hello
> > > I've developped a jsp WEB site, so i've my web site directory with the
> > > jsp directory which contains my jsp files, the html directory wich
> > > contains my html files and the WEB-INF directory which contains the
> > > JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> > > jsp files using apache server, even so i can access via apache to the
> > > tomcat jsp examples. What the way to do to make apache to find the jsp
> > > files.
> > >
> > > i'm getting the following
> > > Error: 404
> > > Location: /jsp/jsp_file.jsp
> > >
>
>
> One thing I've noticed when using apache and tomcat is that the paths are
> treated differently - from within tomcat /jsp will be within your webapp,
> while from apache it is not.
>
> (i.e.:
> /webapps/app/jsp - tomcat
> /webapps/jsp - apache
>
> Try adding the webapp name to the path.
>
> HTH,
> Jim
>
>
> --
>
>                            *   Jim Cheesman   *
>              Trabajo:
> jchees@msl.es - (34)(91) 724 9200 x 2360
>                  I am becoming
> increasingly worried that
>                   there isn't enough anxiety in
> my life.
>


Re: apache don't find my jsp files but works whith examples jsp files

Posted by Jim Cheesman <jc...@msl.es>.
> > François Andromaque wrote:
> >
> > Hello
> > I've developped a jsp WEB site, so i've my web site directory with the
> > jsp directory which contains my jsp files, the html directory wich
> > contains my html files and the WEB-INF directory which contains the
> > JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> > jsp files using apache server, even so i can access via apache to the
> > tomcat jsp examples. What the way to do to make apache to find the jsp
> > files.
> >
> > i'm getting the following
> > Error: 404
> > Location: /jsp/jsp_file.jsp
> >


One thing I've noticed when using apache and tomcat is that the paths are 
treated differently - from within tomcat /jsp will be within your webapp, 
while from apache it is not.

(i.e.:
/webapps/app/jsp - tomcat
/webapps/jsp - apache

Try adding the webapp name to the path.

HTH,
Jim


--

                           *   Jim Cheesman   *
             Trabajo: 
jchees@msl.es - (34)(91) 724 9200 x 2360
                 I am becoming 
increasingly worried that
                  there isn't enough anxiety in 
my life.



Re: apache don't find my jsp files but works whith examples jsp files

Posted by François Andromaque <fr...@sib.fr>.
and wher must be the JAVA BEANS, in tomcat/webapps/root/my/WEB-INF?


----- Original Message -----
From: "Krishna Kant T" <kr...@compulsesys.com>
To: <to...@jakarta.apache.org>
Sent: Wednesday, June 06, 2001 10:40 AM
Subject: Re: apache don't find my jsp files but works whith examples jsp
files


> an alias in httpd.conf of apache as to include my-apache-tomcat.conf which
> contains the directive as to where to look for files under
> http://localhost/my/
>
> the jsp files are present in tomcat/webapps/root/my/....
>
> i am running tomcat under a different login. could that be a possible
problem?
>
> -krishnakant
>
> François Andromaque wrote:
>
> > I'm using jserv but it's the same thing
> > Here is my tomcat.conf added to my httpd.conf :
> >
> > #################### All jsp files will go to tomcat
####################
> > #ApJServMount default /root
> >
> > ApJServMount default /my_web_directory
> > AddType text/jsp .jsp
> > AddHandler jserv-servlet .jsp
> >
> > ############################## Context mapping - all requests go to
tomcat
> >
> > ApJServMount /examples /my_web_directory
> >
> > here is the returned error
> > Syntax error on line 39 of /usr/jakarta-tomcat/conf/tomcat.conf:
> > ApJServMount: secret file (3rd field): cannot entirely read file
> > '/my_web_directory
> >
> > what do you mean by alias statement?
> >
> > ----- Original Message -----
> > From: "P.Miller" <p....@brocom.de>
> > To: <to...@jakarta.apache.org>
> > Sent: Wednesday, June 06, 2001 9:56 AM
> > Subject: Re: apache don't find my jsp files but works whith examples jsp
> > files
> >
> > > Hi Francois,
> > >
> > > you have to add an 'Alias' statement for your context in the
mod_jk.conf
> > > (which you should 'Include' in the httpd.conf) and also a 'JKMount
> > > /context/*.jsp ajp13' in the same file.
> > >
> > > HTH
> > > Peter
> > >
> > > > François Andromaque wrote:
> > > >
> > > > Hello
> > > > I've developped a jsp WEB site, so i've my web site directory with
the
> > > > jsp directory which contains my jsp files, the html directory wich
> > > > contains my html files and the WEB-INF directory which contains the
> > > > JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> > > > jsp files using apache server, even so i can access via apache to
the
> > > > tomcat jsp examples. What the way to do to make apache to find the
jsp
> > > > files.
> > > >
> > > > i'm getting the following
> > > > Error: 404
> > > > Location: /jsp/jsp_file.jsp
> > > >
> > > > this is yet the right emplacement of the file
> > > >
> > > > Thanks in advance for your help.
> > > >
> > > >


Re: apache don't find my jsp files but works whith examples jsp files

Posted by Krishna Kant T <kr...@compulsesys.com>.
an alias in httpd.conf of apache as to include my-apache-tomcat.conf which
contains the directive as to where to look for files under
http://localhost/my/

the jsp files are present in tomcat/webapps/root/my/....

i am running tomcat under a different login. could that be a possible problem?

-krishnakant

François Andromaque wrote:

> I'm using jserv but it's the same thing
> Here is my tomcat.conf added to my httpd.conf :
>
> #################### All jsp files will go to tomcat ####################
> #ApJServMount default /root
>
> ApJServMount default /my_web_directory
> AddType text/jsp .jsp
> AddHandler jserv-servlet .jsp
>
> ############################## Context mapping - all requests go to tomcat
>
> ApJServMount /examples /my_web_directory
>
> here is the returned error
> Syntax error on line 39 of /usr/jakarta-tomcat/conf/tomcat.conf:
> ApJServMount: secret file (3rd field): cannot entirely read file
> '/my_web_directory
>
> what do you mean by alias statement?
>
> ----- Original Message -----
> From: "P.Miller" <p....@brocom.de>
> To: <to...@jakarta.apache.org>
> Sent: Wednesday, June 06, 2001 9:56 AM
> Subject: Re: apache don't find my jsp files but works whith examples jsp
> files
>
> > Hi Francois,
> >
> > you have to add an 'Alias' statement for your context in the mod_jk.conf
> > (which you should 'Include' in the httpd.conf) and also a 'JKMount
> > /context/*.jsp ajp13' in the same file.
> >
> > HTH
> > Peter
> >
> > > François Andromaque wrote:
> > >
> > > Hello
> > > I've developped a jsp WEB site, so i've my web site directory with the
> > > jsp directory which contains my jsp files, the html directory wich
> > > contains my html files and the WEB-INF directory which contains the
> > > JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> > > jsp files using apache server, even so i can access via apache to the
> > > tomcat jsp examples. What the way to do to make apache to find the jsp
> > > files.
> > >
> > > i'm getting the following
> > > Error: 404
> > > Location: /jsp/jsp_file.jsp
> > >
> > > this is yet the right emplacement of the file
> > >
> > > Thanks in advance for your help.
> > >
> > >


Re: apache don't find my jsp files but works whith examples jsp files

Posted by François Andromaque <fr...@sib.fr>.
I'm using jserv but it's the same thing
Here is my tomcat.conf added to my httpd.conf :

#################### All jsp files will go to tomcat ####################
#ApJServMount default /root

ApJServMount default /my_web_directory
AddType text/jsp .jsp
AddHandler jserv-servlet .jsp

############################## Context mapping - all requests go to tomcat

ApJServMount /examples /my_web_directory

here is the returned error
Syntax error on line 39 of /usr/jakarta-tomcat/conf/tomcat.conf:
ApJServMount: secret file (3rd field): cannot entirely read file
'/my_web_directory

what do you mean by alias statement?


----- Original Message -----
From: "P.Miller" <p....@brocom.de>
To: <to...@jakarta.apache.org>
Sent: Wednesday, June 06, 2001 9:56 AM
Subject: Re: apache don't find my jsp files but works whith examples jsp
files


> Hi Francois,
>
> you have to add an 'Alias' statement for your context in the mod_jk.conf
> (which you should 'Include' in the httpd.conf) and also a 'JKMount
> /context/*.jsp ajp13' in the same file.
>
> HTH
> Peter
>
> > François Andromaque wrote:
> >
> > Hello
> > I've developped a jsp WEB site, so i've my web site directory with the
> > jsp directory which contains my jsp files, the html directory wich
> > contains my html files and the WEB-INF directory which contains the
> > JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> > jsp files using apache server, even so i can access via apache to the
> > tomcat jsp examples. What the way to do to make apache to find the jsp
> > files.
> >
> > i'm getting the following
> > Error: 404
> > Location: /jsp/jsp_file.jsp
> >
> > this is yet the right emplacement of the file
> >
> > Thanks in advance for your help.
> >
> >


Re: apache don't find my jsp files but works whith examples jsp files

Posted by "P.Miller" <p....@brocom.de>.
Hi Francois,

you have to add an 'Alias' statement for your context in the mod_jk.conf
(which you should 'Include' in the httpd.conf) and also a 'JKMount
/context/*.jsp ajp13' in the same file.

HTH
Peter

> François Andromaque wrote:
> 
> Hello
> I've developped a jsp WEB site, so i've my web site directory with the
> jsp directory which contains my jsp files, the html directory wich
> contains my html files and the WEB-INF directory which contains the
> JAVA-BEAN, it perfectly works with TOMCAT, but i can't access to my
> jsp files using apache server, even so i can access via apache to the
> tomcat jsp examples. What the way to do to make apache to find the jsp
> files.
> 
> i'm getting the following
> Error: 404
> Location: /jsp/jsp_file.jsp
> 
> this is yet the right emplacement of the file
> 
> Thanks in advance for your help.
> 
>