Question

I'm having a problem performing searches if the search query contains more than 1 word.

For example I search for "learn", which does return all topics with "learn" in them successfully, however if I search for "learn more" or any other search term of more than 1 word I get a page full of error messages consisting of: -

"Could not perform search, error was: Insecure dependancy in eval while running with a -T switch at D:/Twiki/Website/lib/TWiki/Store/SearchAlgorithms/PurePerl.pm line 51" and "TWiki::Store::SearchAlgoriths::PurePerl::search('learn', 'ARRAY(0x2233e90)', 'HASH(0x243910c)', 'D:/TWiki/Website/Data/Main/', 'TWiki::Sandbox=HASH(0x19c36b0)') called at D:/TWiki/Website/lib/TWiki/Store/RcsFile.pm line 329 TWiki::Store::RcsFile::searchInWebContent"

If I use Forking instead of PurePerl then I get no results at all though! Looking at the FAQ suggests this may be caused by EGrep and FGrep not being installed properly?

Thanks in advance,

James

Environment

TWiki version: TWikiRelease04x02x00
Server OS: Windows Server 2003
Web server: Apache/2.2.9 (Win32)
Perl version: 5.008008 (MSWin32)
Client OS: Windows XP SP3
Web Browser: Internet Explorer 7.0
Categories: Search

-- JamesRJMorris - 04 Jul 2008

Answer

ALERT! If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.

James, I have a similar configuration like yours (and some time ago a similar problem) and the following worked for me:

  1. Download the setup file for Grep for Windows and install it on your sever. I left the proposed path - something like c:\program files\GnuWin32.
  2. Then update your Windows PATH variable, so that it includes the path to the bin folder of grep, e.g. c:\progra~1\GnuWin32\bin
  3. After that update your TWiki configuration file to the following values in the Store section:
    • {RCS}{SearchAlgorithm} > ...::Forking
    • {RCS}{EgrepCmd} > c:\progra~1\GnuWin32\bin\grep.exe -E %CS{|-i}% %DET{|-l}% -H -- %TOKEN|U% %FILES|F%
    • {RCS}{FgrepCmd} > c:\progra~1\GnuWin32\bin\grep.exe -F %CS{|-i}% %DET{|-l}% -H -- %TOKEN|U% %FILES|F%

Have also a look at IndigoPerlCookbook - this is where I got the idea from. Hope it works for you, too.

-- SebastianKlus - 08 Jul 2008

That works brilliantly Sebastian, thanks a lot.

James

-- JamesRJMorris - 09 Jul 2008

Change status to:
Edit | Attach | (削除) Watch (削除ここまで) | Print version | History : r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r3 - 2008年07月09日 - JamesRJMorris
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.

AltStyle によって変換されたページ (->オリジナル) /