tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 44215] - jkunmount causes apache to throw permission denied error
Date Mon, 14 Jan 2008 20:45:17 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=44215>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=44215


rainer.jung@kippdata.de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |NEEDINFO




------- Additional Comments From rainer.jung@kippdata.de  2008-01-14 12:45 -------
I tested your setup. I have two different types of answers.

Part I: Questioning your setup

There are two things, which are in conflict in your setup:

- you set a JkAutoAlias. This says: if there is a JkMount in a vhost, but a 
request does not match, then look for the file below the directory given in the 
JkAutoAlias.

- you say, that the file does *not* exist in the appropriate sub directory of 
the directory given in JkAutoAlias, and instead it exists below the 
DocumentRoot.

So it looks like you want to serve the static content from the DocumentRoot. In 
this case simply remove the JkAutoAlias.


Part II: Testing your setup

1) JK version 1.2.21 as indicated in your first post: when requesting

http://www.examples.com/selfservice/images/welcome.gif

the config resolves this to

- do not forward to Tomcat
- use the JkAutoAlias
- return with file /usr/share/tomcat5/webapps/selfservice/images/welcome.gif

As you can see from Part I, this works as desinged. It actually works with or 
without JkMountCopy. No rewrite rule needed. The Jk log shows debug log lines

... [16927:0006] [debug] jk_translate::mod_jk.c (2878): check 
alias_dir: /usr/share/tomcat5/webapps
... [16927:0006] [debug] jk_translate::mod_jk.c (2904): AutoAlias child_dir: 
test.html
... [16927:0006] [debug] jk_translate::mod_jk.c (2939): AutoAlias OK for 
file: /usr/share/tomcat5/webapps/selfservice/test.html

The fact, that it works without JkMountCopy is a bug in 1.2.21.

2) Version 1.2.26: does *not* work either with or without JkMountCopy. Should 
work with JkMountCopy, but does not, because when cleaning up the mount 
handling in vhosts, we treated JkAutoAlias wrong :(

So: which version are you actually testing against? Is it still really 1.2.21, 
like you posted in your first message?

Concerning 1.2.26, the following patch against 1.2.26 should do the trick:

--- mod_jk.c.orig       2007-12-14 19:50:44.000000000 +0100
+++ mod_jk.c    2008-01-14 21:28:01.000000000 +0100
@@ -2551,6 +2551,8 @@
         }
         if (!overrides->mount_file)
             overrides->mount_file = base->mount_file;
+    }
+    if (overrides->mountcopy == JK_TRUE) {
         if (!overrides->alias_dir)
             overrides->alias_dir = base->alias_dir;
     }

Questions:

- which jk version?
- do you want to serve the files from the DocumentRoot or from the JkAutoAlias 
directory?
- does the file exist there?
- if you only request one of those static files, what's the jk debog log output?


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message