Thanks for the reply Bruce, but I had that idea already, which is why I checked the permissions.

The file is owned by tomcat (I do a recursive chown of the entire data directory after every run of the indexer).

I can read and list the file as the tomcat user:

-sh-3.2$ pwd
/data/opengrok/data/xref/solar/tm_lib/coapi/bridges/php
-sh-3.2$ ls -la
total 76
drwxr-xr-x 2 tomcat tomcat  4096 Jun 14 10:31 .
drwxr-xr-x 4 tomcat tomcat  4096 Jun 14 10:31 ..
-rw-r--r-- 1 tomcat tomcat  1473 Jun 14 10:31 dbvartest.php.gz
-rw-r--r-- 1 tomcat tomcat  1125 Jun 14 10:31 loop.php.gz
-rw-r--r-- 1 tomcat tomcat  5171 Jun 14 10:31 Makefile.gz
-rw-r--r-- 1 tomcat tomcat 36387 Jun 14 10:31 php_mcp.cpp.gz
-rw-r--r-- 1 tomcat tomcat  2350 Jun 14 10:31 php_mcp.hpp.gz
-rw-r--r-- 1 tomcat tomcat  3218 Jun 14 10:31 simple_test.php.gz
-rw-r--r-- 1 tomcat tomcat  6204 Jun 14 10:31 validationtest.php.gz
-sh-3.2$ pwd
/data/opengrok/data/xref/solar/tm_lib/coapi/bridges/php
-sh-3.2$ zcat loop.php.gz > /dev/null
-sh-3.2$ echo $?
0
-sh-3.2$ id
uid=91(tomcat) gid=91(tomcat) groups=91(tomcat)
-sh-3.2$

Several of the other files in that same exact directory do not produce the error from the webapp.

What other file(s) would need a change in permissions?

-Zach


On 06/22/2012 09:39 AM, Bruce Furber wrote:
The user that was used to run the Indexer has read access to the file
but tomcat does not.
--
Bruce

Zach Carter <z.car...@f5.com> wrote:

    Hi folks,

    This problem has been stumping me for a couple of weeks now, and I'm
    hoping someone can help me.

    When trying to access certain files through the source.war webapp, the
    server returns a message like this:

       Not Found

    The requested URL /source/xref/solar/tm_lib/coapi/bridges/php/loop.php
    was not found on this server.

    Now, I know for a fact that the file is there:

    [zcarter@piglet opengrok]$ ls -la
    source/solar/tm_lib/coapi/bridges/php/loop.php
    data/xref/solar/tm_lib/coapi/bridges/php/loop.php.gz
    -rw-r--r-- 1 tomcat tomcat 1125 Jun 14 10:31
    data/xref/solar/tm_lib/coapi/bridges/php/loop.php.gz
    -r-xr-xr-x 1 root   root    918 Oct 10  2008
    source/solar/tm_lib/coapi/bridges/php/loop.php

    The webapp indexed it.  If I search for something present in the file,
    it will
    show in the results, but when I click a link to access the full
    contents of the file, I get the above error.

    This is only for a certain small subset of our source files, all other
    files can be accessed with no problems.   I am not sure what is special
    about the problematic files.

    Questions:
    - Does anyone know the cause?
    - Does anyone know how I can get some more verbose error logging from
    the source.war webapp to see what is generating the Not Found error?
    - Any other troubleshooting tips?

    I am running opengrok 0.9 on a CentOS 5.5 machine.  I did a test upgrade
    to 0.11.1 and still got the problem.

    Any help would be much appreciated,

    thanks!

    -Zach
    ------------------------------------------------------------------------

    opengrok-discuss mailing list
    opengrok-discuss@opensolaris.org
    http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss



_______________________________________________
opengrok-discuss mailing list
opengrok-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/opengrok-discuss

Reply via email to