[Xapian-discuss] Exception: Permission denied using template query
Steve Nesbitt
sjnesbitt at yahoo.com
Fri Apr 6 00:02:58 BST 2007
Thanks Richard
ls -ld /var - drwxr-xr-x 24 root root 4096 Mar 27 05:30 .
ls -ld /var/lib - drwxr-xr-x 25 root root 4096 Apr 3 17:05 /var/lib
ls -ld /var/lib/omega - drwxr-xr-x 6 root root 4096 Apr 3 17:13 /var/lib/omega
Richard Boulton <richard at lemurconsulting.com> wrote:
Steve Nesbitt wrote:
>> What are the permissions of the parent directories - try:
>
> permissions: drwxrwxrwx - I also changed the directory group to user apache (still doesn't work)
>
>> ls -ld /var /var/lib /var/lib/omega
What is the actual output of the command Olly asked you to run? Have
you really changed /var to permissions drwxrwxrwx (not that you should,
but accurate information from you is all we have to go on)?
Content-Type: text/html
<html>
<head>
<title>Omega Search: omindex</title>
<script type='text/javascript' language='javascript'><!--
function C(c) {var i, o;
o = " "+document.P.P.value+" ";
i = o.lastIndexOf(" "+c.value+" ");
if (i!=-1) {
document.P.P.value =
o.substring(1,i)+o.substring(i+c.value.length+1,o.length-1);
} else {
document.P.P.value = document.P.P.value+" "+c.value;
}}
// -->
</script>
</head>
<body bgcolor="#ffffff">
<FORM NAME=P METHOD=GET
ACTION="omega" TARGET="_top">
<center>
<INPUT NAME=P VALUE="omindex" SIZE=65>
<INPUT TYPE=SUBMIT VALUE="Search" BORDER=0>
<hr>
<INPUT TYPE=radio NAME=DEFAULTOP VALUE=or CHECKED> Matching any words
<INPUT TYPE=radio NAME=DEFAULTOP VALUE=and > Matching all words
<hr>
<table><tr><td bgcolor="#ccffcc">
<span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="index" onClick="C(this)">index</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="file" onClick="C(this)">file</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="You" onClick="C(this)">You</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="line." onClick="C(this)">line.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="configur." onClick="C(this)">configur.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="where" onClick="C(this)">where</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="larg." onClick="C(this)">larg.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="limit" onClick="C(this)">limit</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="scriptindex." onClick="C(this)">scriptindex.</span> <span
style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="should." onClick="C(this)">should.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="basic" onClick="C(this)">basic</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="scheme." onClick="C(this)">scheme.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="expect." onClick="C(this)">expect.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="cgiparam." onClick="C(this)">cgiparam.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="hash." onClick="C(this)">hash.</span> <span style="white-space:nowrap"><INPUT TYPE=checkbox NAME=X VALUE="applic." onClick="C(this)">applic.</span>
<BR><NOSCRIPT><INPUT TYPE=hidden NAME=ADD VALUE=1></NOSCRIPT>
</td></tr></table>
<hr>
All 4 matches
<hr>
</center>
Term frequencies: <b>omindex</b>: 4
<br><small>Search took 0.000318 seconds</small>
<table>
<TR><TD VALIGN=top><IMG
SRC="/icons/omega/score-10.png"
ALT="100%" HEIGHT=16 WIDTH=32></TD>
<TD VALIGN=top><TABLE BORDER=0 CELLPADDING=1><TR><TD BGCOLOR="#ccffcc">
<INPUT TYPE=checkbox NAME=R VALUE=9>
</TD></TR></TABLE></TD>
<TD><B><A HREF="/overview.txt">/overview.txt</A></B>
<small>(2007-03-05 23:36)<br>
Omega overview ============== Omega operates on a set of databases. Each database is created and updated separately using either <b style="color:black;background-color:#ffff66">omindex</b> or scriptindex. You can search these databases (or any other Xapian database with suitable contents) via a web front-end provided by omega, a CGI application ......</small><br>
<A HREF="/overview.txt">/overview.txt</A><br>
<small>
Size: <b>16K</b>
<br>
100% relevant, matching:
<i>omindex</i></small><P></TD></TR><TR><TD VALIGN=top><IMG
SRC="/icons/omega/score-7.png"
ALT="76%" HEIGHT=16 WIDTH=32></TD>
<TD VALIGN=top><TABLE BORDER=0 CELLPADDING=1><TR><TD BGCOLOR="#ccffcc">
<INPUT TYPE=checkbox NAME=R VALUE=10>
</TD></TR></TABLE></TD>
<TD><B><A HREF="/quickstart.txt">/quickstart.txt</A></B>
<small>(2007-03-05 23:36)<br>
Basic instructions: =================== 1. Use <b style="color:black;background-color:#ffff66">omindex</b> to build an index of your website: $ <b style="color:black;background-color:#ffff66">omindex</b> --db DBPATH --url / WEBPATH Where DBPATH is where you want the database, such as /var/lib/omega/data/default and WEBPATH is the directory containing all your web documents - e.g. /var/www ......</small><br>
<A HREF="/quickstart.txt">/quickstart.txt</A><br>
<small>
Size: <b>1K</b>
<br>
76% relevant, matching:
<i>omindex</i></small><P></TD></TR><TR><TD VALIGN=top><IMG
SRC="/icons/omega/score-7.png"
ALT="76%" HEIGHT=16 WIDTH=32></TD>
<TD VALIGN=top><TABLE BORDER=0 CELLPADDING=1><TR><TD BGCOLOR="#ccffcc">
<INPUT TYPE=checkbox NAME=R VALUE=8>
</TD></TR></TABLE></TD>
<TD><B><A HREF="/scriptindex.txt">/scriptindex.txt</A></B>
<small>(2007-03-05 23:36)<br>
Index scripts: ============== The basic format is one or more field names followed by a colon, followed by one or more actions. Some actions take an optional or required parameter. The actions are applied in the specified order to each field listed, and fields can be listed in several lines ......</small><br>
<A HREF="/scriptindex.txt">/scriptindex.txt</A><br>
<small>
Size: <b>3K</b>
<br>
76% relevant, matching:
<i>omindex</i></small><P></TD></TR><TR><TD VALIGN=top><IMG
SRC="/icons/omega/score-5.png"
ALT="56%" HEIGHT=16 WIDTH=32></TD>
<TD VALIGN=top><TABLE BORDER=0 CELLPADDING=1><TR><TD BGCOLOR="#ccffcc">
<INPUT TYPE=checkbox NAME=R VALUE=11>
</TD></TR></TABLE></TD>
<TD><B><A HREF="/termprefixes.txt">/termprefixes.txt</A></B>
<small>(2007-03-05 23:36)<br>
Xapian itself doesn't put any restrictions on the contents of a term, other than that terms can't be empty, and there's an upper limit on the length (which is backend dependent - quartz allows just over 240 characters, except that zero bytes count double in this length). However, Omega an ......</small><br>
<A HREF="/termprefixes.txt">/termprefixes.txt</A><br>
<small>
Size: <b>5K</b>
<br>
56% relevant, matching:
<i>omindex</i></small><P></TD></TR>
</table>
<br><center>
</center><br>
<INPUT TYPE=hidden NAME=DB VALUE="default">
<INPUT TYPE=hidden NAME=FMT VALUE="query">
<INPUT TYPE=hidden NAME=xP VALUE="omindex">
<INPUT TYPE=hidden NAME=xDB VALUE="default">
<INPUT TYPE=hidden NAME=xFILTERS VALUE="--O">
</FORM>
<hr><div align=right><i><small><a href="http://www.xapian.org/">Xapian - omega 0.9.10</a></small></i></div>
</body>
</html>
If one of the directories above /var/lib/omega doesn't have permission
set to allow apache to read the directory, you'll get a permission
denied error. So we need to know the permissions and ownership of all
the directories above it, not just /var/lib/omega, to diagnose the problem.
Also, if any of the parent directores of /var/lib/omega are symbolic
links, or /var/lib/omega is itself, you might have different problems
(ie, the permission of the symlink isn't what matters - the permission
of the directory linked to is what matters).
The output of Olly's command would have diagnosed both the problems, or
clearly shown that neither potential problem is the cause, without
needing further communication. As a general plea to everyone, if asked
to run a specific command to get information, please cut and paste the
literal output of that command into your reply if at all possible.
--
Richard
_______________________________________________
Xapian-discuss mailing list
Xapian-discuss at lists.xapian.org
http://lists.xapian.org/mailman/listinfo/xapian-discuss
I know this is a httpd issue - I moved templates to /var/www/cgi-bin/ directory and reconfigured the omega.conf (located in cgi-bin directory) to point to the /var/www/cgi-bin directory. It now displays the query search screen but now states that it cannot open default db.
I tried putting .htaccess files in the directories /var/lib/ omega data and default. My omega.conf file is the standard omega.conf file and I made directories to match. I went into the httpd.conf file and set AllowOveride ALL and the .htaccess overide the same. Still cannot open default database.
Steve
---------------------------------
---------------------------------
8:00? 8:25? 8:40? Find a flick in no time
with theYahoo! Search movie showtime shortcut.
More information about the Xapian-discuss
mailing list