On April 22, 1998 Peter Dykes wrote:
> I am trying to set up SWISH-E on an Apache server and index the site =
> using AutoSwish. The scripts seem to be working ok except that no index =
> files are created. paths and directory permissions are ok. Any ideas?
I had a similar-sounding problem -- the error when searching was:
"err: the index file(s) is empty"
It was caused by putting a line break in the VALUE part of the ReplaceRules
INPUT tag of the AutoSwish home page. The line break creates a line in the
.conf file which swish-e, called by swish_create.pl via AutoSwish, cannot
understand because it doesn't start with a "ReplaceRules" keyword; this
causes swish-e to fail.
This failure is, however, not reported in AutoSwish, nor does it cause
swish_create to fail.
If you suspect something like this is causing your problem you can make the
error more visible two ways:
1. Run the indexing operation from the command line:
a. Where foo is the directory name you supplied to AutoSwish, delete
any existing foo.swish from your SwishIndexes directory.
From your ConfigFiles directory:
% swish-e -c foo.conf
In my case, things perked along for a while, but then:
Segmentation Fault (core dumped)
b. Comment-out lines of foo.conf and repeat (a.) until swish-e
finishes properly.
2. If you want AutoSwish to report failure, you can add something like the
following to swish_create.pl in "sub index" where original indexing
starts (about line 263):
...
}else{
# Start an HTML page
&html_header("Indexing with SWISH-E: Step 2a, Indexing");
print "Begin indexing: <BR>\n";
# This creates the index (foo.swish) and stores the report from swish-e
# for later display by swish_create.
# This line is already in swish_create.pl.
$return = `$SWISHDIR/swish-e -c $CONFIGDIR/$userid/$FORM{'ConfigFile'}`;
# If swish-e finished properly $return will not be empty.
if ( $return eq "" )
{
# Display the error
&return_error (500, "CGI Error",
"Indexing appears to have failed.");
}
# Report
print "Indexing finished.<BR>\n";
# Finish the page.
print "</BODY></HTML>";
...
Eric Lee
ericlee@oise.utoronto.ca
Received on Fri Apr 24 10:34:05 1998