Re: full path of 404 file

2007-09-02 Thread Peter Boughton
I'm not really trying to use webapps at all - I want each Host to be
associated with a user account, like this:
Host name=user1.com appBase=/home/user1/public_html.../Host
Host name=user2.com appBase=/home/user2/public_html.../Host
Host name=user3.com appBase=/home/user3/public_html.../Host


On 9/2/07, Bill Barker [EMAIL PROTECTED] wrote:


 Peter Boughton [EMAIL PROTECTED] wrote in message
 news:[EMAIL PROTECTED]
 I mean full system path. (eg: /usr/local/jakarta/tomcat/webapps/index.jsp
 or
  /home/user/domain/public_html/index.jsp or whatever)
  As far as I can tell, the appBase and docBase are correctly pointing to
  the
  webroot dir, but cPanel/WHM auto-configured server.xml/etc so it could
 be
  doing anything.
 

 This looks like you are attempting the common, but unsupported
 configuration
 of trying to make webapps the root of your webapp.  The file should be
 something like /usr/local/jakarta/tomcat/webapps/ROOT/index.jsp.

  I'm tempted to just try wiping the conf dir and manually build up from a
  mimimal configuration...
 
 
  On 9/1/07, Hassan Schroeder [EMAIL PROTECTED] wrote:
 
  On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
   Thanks for the suggestion. I tried access logging, but it's only
   listing
  the
   /index.jsp, not the full path.
 
  Uh, then that *is* the full path; sounds like you need to double-check
  your Tomcat appBase/docBase/etc. configuration...
 
  --
  Hassan Schroeder  [EMAIL PROTECTED]
 
  -
  To start a new topic, e-mail: users@tomcat.apache.org
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
  --
  \ \
  Peter Boughton
  blog.bpsite.net
  / /
 




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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-02 Thread Peter Boughton
Ooops.
This is what I currently have:
Host name=localhost appBase=webapps/
Host name=mydomain.com appBase=/home/user0/public_html
Aliaswww.mydomain.com/Alias
Context path= docBase=/home/user0/public_html reloadable=true/
/Host

What do I need to change so that mydomain.com/whatever will load
/home/user0/public_html/whatever ?

On 9/2/07, Mark Thomas [EMAIL PROTECTED] wrote:

 Peter Boughton wrote:
  As far as I can tell, the appBase and docBase are correctly pointing to
 the
  webroot dir,

 and there is the problem. appBase == docBase will result in all sorts
 of pain and grief. The appBase should never point to the root of any
 web application.

 Mark


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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-02 Thread Mark Thomas
Peter Boughton wrote:
 Ooops.
 This is what I currently have:
 Host name=localhost appBase=webapps/
 Host name=mydomain.com appBase=/home/user0/public_html
 Aliaswww.mydomain.com/Alias
 Context path= docBase=/home/user0/public_html reloadable=true/
 /Host
 
 What do I need to change so that mydomain.com/whatever will load
 /home/user0/public_html/whatever ?

I would use:
Host name=localhost appBase=webapps/
Host name=mydomain.com appBase=/home/user0/webapps
Aliaswww.mydomain.com/Alias
/Host

and not define any contexts in server.xml

Contents for the root web application would then be placed in
/home/user0/webapps/ROOT

context for the foobar context in
/home/user0/webapps/foobar

etc

Mark


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



Re: full path of 404 file

2007-09-02 Thread Peter Boughton
Ok, tried using that configuration, but I'm still getting the 405 method not
supported error for any jsp file.

Does the fact that it is apparently reaching the right directory now mean
that this is more likely to be a new problem with web.xml rather than
server.xml?


Thanks,

Peter

On 9/2/07, Mark Thomas [EMAIL PROTECTED] wrote:

 Peter Boughton wrote:
  Ooops.
  This is what I currently have:
  Host name=localhost appBase=webapps/
  Host name=mydomain.com appBase=/home/user0/public_html
  Aliaswww.mydomain.com/Alias
  Context path= docBase=/home/user0/public_html
 reloadable=true/
  /Host
 
  What do I need to change so that mydomain.com/whatever will load
  /home/user0/public_html/whatever ?

 I would use:
 Host name=localhost appBase=webapps/
 Host name=mydomain.com appBase=/home/user0/webapps
 Aliaswww.mydomain.com/Alias
 /Host

 and not define any contexts in server.xml

 Contents for the root web application would then be placed in
 /home/user0/webapps/ROOT

 context for the foobar context in
 /home/user0/webapps/foobar

 etc

 Mark


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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


RE: full path of 404 file

2007-09-02 Thread Caldarale, Charles R
 From: Peter Boughton [mailto:[EMAIL PROTECTED] 
 Subject: Re: full path of 404 file
 
 Does the fact that it is apparently reaching the right 
 directory now mean that this is more likely to be a new
 problem with web.xml rather than server.xml?

Sounds like you really need to post your server.xml and WEB-INF/web.xml
files, rather than just hinting about them.  Also, is there anything in
the WEB-INF/lib or WEB-INF/classes directories (e.g., precompiled JSPs)?

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

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



Re: full path of 404 file

2007-09-02 Thread Peter Boughton
 /usr/local/jakarta/tomcat/webapps

JkMount /* ajp13
JkUnMount /*.html ajp13
JkUnMount /*.jpg ajp13
JkUnMount /*.gif ajp13
JkUnMount /*.png ajp13
JkUnMount /*.php ajp13



Thanks,

Peter

On 9/2/07, Caldarale, Charles R [EMAIL PROTECTED] wrote:

  From: Peter Boughton [mailto:[EMAIL PROTECTED]
  Subject: Re: full path of 404 file
 
  Does the fact that it is apparently reaching the right
  directory now mean that this is more likely to be a new
  problem with web.xml rather than server.xml?

 Sounds like you really need to post your server.xml and WEB-INF/web.xml
 files, rather than just hinting about them.  Also, is there anything in
 the WEB-INF/lib or WEB-INF/classes directories (e.g., precompiled JSPs)?

 - Chuck


 THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
 MATERIAL and is thus for use only by the intended recipient. If you
 received this in error, please contact the sender and delete the e-mail
 and its attachments from all computers.

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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-02 Thread Hassan Schroeder
On 9/2/07, Peter Boughton [EMAIL PROTECTED] wrote:

 I don't have a WEB-INF directory created yet - it does get auto-created,
 right?

No.

 Anyway, here's /usr/local/jakarta/tomcat/conf/web.xml

You shouldn't have to touch this at all, and I certainly wouldn't make
any changes there until you've got your basic config working.

 ... I should probably say that I'm doing this via mod_jk from Apache,

Yes, you probably should :-) and you absolutely should get your
webapp working properly through direct access first.

It will simplify your debugging immensely...

-- 
Hassan Schroeder  [EMAIL PROTECTED]

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



Re: full path of 404 file

2007-09-02 Thread Peter Boughton
  I don't have a WEB-INF directory created yet - it does get auto-created,
  right?

 No.

Ooops. :$

I created WEB-INF, chmod-ed, and it starts working now.


(Well, the CFMLServlet works, the JSP servlet doesn't, but I don't really
need that so I'm content to leave it.)


Thanks to everyone for all the help  suggestions. :)


Peter

On 9/2/07, Hassan Schroeder [EMAIL PROTECTED] wrote:

 On 9/2/07, Peter Boughton [EMAIL PROTECTED] wrote:

  I don't have a WEB-INF directory created yet - it does get auto-created,
  right?

 No.

  Anyway, here's /usr/local/jakarta/tomcat/conf/web.xml

 You shouldn't have to touch this at all, and I certainly wouldn't make
 any changes there until you've got your basic config working.

  ... I should probably say that I'm doing this via mod_jk from Apache,

 Yes, you probably should :-) and you absolutely should get your
 webapp working properly through direct access first.

 It will simplify your debugging immensely...

 --
 Hassan Schroeder  [EMAIL PROTECTED]

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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


full path of 404 file

2007-09-01 Thread Peter Boughton
Hello.

If I go to www.mydomain.com/index.jsp I get a 404 from Tomcat, despite there
definitely being an index.jsp in the webroot. I assume that means it is not
looking at the right directory.

How do I find the full filename Tomcat is looking for when producing the
404?

Thanks,

Peter


Re: full path of 404 file

2007-09-01 Thread Hassan Schroeder
On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:

 How do I find the full filename Tomcat is looking for when producing the
 404?

You could turn on access logging, or you could set up a custom
404 page to return whatever you think pertinent.

Of course, if the system doesn't find your custom 404, you're back
to access logging, so ... :-)

HTH,
-- 
Hassan Schroeder  [EMAIL PROTECTED]

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



Re: full path of 404 file

2007-09-01 Thread Peter Boughton
Thanks for the suggestion. I tried access logging, but it's only listing the
/index.jsp, not the full path.

Was using this page as reference:
http://tomcat.apache.org/tomcat-5.5-doc/config/valve.html#Access%20Log%20Valve

And put this in the appropriate Host section of server.xml
Valve className=org.apache.catalina.valves.AccessLogValve
 directory=logs  prefix=domain.com_access_log. suffix=.txt
 pattern=%t %m %a %A %h %H %p %q %s %U %v %D
resolveHosts=false/

Are there any other patterns that I'm missing?

I'll see if I can get a custom 404 working.

Thanks,

Peter

On 9/1/07, Hassan Schroeder [EMAIL PROTECTED] wrote:

 On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:

  How do I find the full filename Tomcat is looking for when producing the
  404?

 You could turn on access logging, or you could set up a custom
 404 page to return whatever you think pertinent.

 Of course, if the system doesn't find your custom 404, you're back
 to access logging, so ... :-)

 HTH,
 --
 Hassan Schroeder  [EMAIL PROTECTED]

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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-01 Thread Hassan Schroeder
On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
 Thanks for the suggestion. I tried access logging, but it's only listing the
 /index.jsp, not the full path.

Uh, then that *is* the full path; sounds like you need to double-check
your Tomcat appBase/docBase/etc. configuration...

-- 
Hassan Schroeder  [EMAIL PROTECTED]

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



Re: full path of 404 file

2007-09-01 Thread Peter Boughton
I mean full system path. (eg: /usr/local/jakarta/tomcat/webapps/index.jsp or
/home/user/domain/public_html/index.jsp or whatever)
As far as I can tell, the appBase and docBase are correctly pointing to the
webroot dir, but cPanel/WHM auto-configured server.xml/etc so it could be
doing anything.

I'm tempted to just try wiping the conf dir and manually build up from a
mimimal configuration...


On 9/1/07, Hassan Schroeder [EMAIL PROTECTED] wrote:

 On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
  Thanks for the suggestion. I tried access logging, but it's only listing
 the
  /index.jsp, not the full path.

 Uh, then that *is* the full path; sounds like you need to double-check
 your Tomcat appBase/docBase/etc. configuration...

 --
 Hassan Schroeder  [EMAIL PROTECTED]

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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-01 Thread Hassan Schroeder
On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
 I mean full system path. (eg: /usr/local/jakarta/tomcat/webapps/index.jsp or
 /home/user/domain/public_html/index.jsp or whatever)
 As far as I can tell, the appBase and docBase are correctly pointing to the
 webroot dir, but cPanel/WHM auto-configured server.xml/etc so it could be
 doing anything.

If the appBase and docBase are set properly, you know where your
files are  :-)  but anything done by some third-party control panel --
I'd be suspicious, anyway.

Did you look in your catalina.out  for startup errors or warnings?

-- 
Hassan Schroeder  [EMAIL PROTECTED]

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



Re: full path of 404 file

2007-09-01 Thread Peter Boughton
Only error/warning I can see in catalina.out is this:
Java HotSpot(TM) Client VM warning: Can't detect initial thread stack
location - find_vma failed

Dunno what that means, but a quick google suggests it can be ignored.

On 9/1/07, Hassan Schroeder [EMAIL PROTECTED] wrote:

 On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
  I mean full system path. (eg:
 /usr/local/jakarta/tomcat/webapps/index.jsp or
  /home/user/domain/public_html/index.jsp or whatever)
  As far as I can tell, the appBase and docBase are correctly pointing to
 the
  webroot dir, but cPanel/WHM auto-configured server.xml/etc so it could
 be
  doing anything.

 If the appBase and docBase are set properly, you know where your
 files are  :-)  but anything done by some third-party control panel --
 I'd be suspicious, anyway.

 Did you look in your catalina.out  for startup errors or warnings?

 --
 Hassan Schroeder  [EMAIL PROTECTED]

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




-- 
\ \
Peter Boughton
blog.bpsite.net
/ /


Re: full path of 404 file

2007-09-01 Thread Bill Barker

Peter Boughton [EMAIL PROTECTED] wrote in message 
news:[EMAIL PROTECTED]
I mean full system path. (eg: /usr/local/jakarta/tomcat/webapps/index.jsp 
or
 /home/user/domain/public_html/index.jsp or whatever)
 As far as I can tell, the appBase and docBase are correctly pointing to 
 the
 webroot dir, but cPanel/WHM auto-configured server.xml/etc so it could be
 doing anything.


This looks like you are attempting the common, but unsupported configuration 
of trying to make webapps the root of your webapp.  The file should be 
something like /usr/local/jakarta/tomcat/webapps/ROOT/index.jsp.

 I'm tempted to just try wiping the conf dir and manually build up from a
 mimimal configuration...


 On 9/1/07, Hassan Schroeder [EMAIL PROTECTED] wrote:

 On 9/1/07, Peter Boughton [EMAIL PROTECTED] wrote:
  Thanks for the suggestion. I tried access logging, but it's only 
  listing
 the
  /index.jsp, not the full path.

 Uh, then that *is* the full path; sounds like you need to double-check
 your Tomcat appBase/docBase/etc. configuration...

 --
 Hassan Schroeder  [EMAIL PROTECTED]

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




 -- 
 \ \
 Peter Boughton
 blog.bpsite.net
 / /
 




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



Re: full path of 404 file

2007-09-01 Thread Mark Thomas
Peter Boughton wrote:
 As far as I can tell, the appBase and docBase are correctly pointing to the
 webroot dir,

and there is the problem. appBase == docBase will result in all sorts
of pain and grief. The appBase should never point to the root of any
web application.

Mark


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