OK, I downloaded the lucene-search Java source, added some debug output, and recompiled it. Here is more data.
- On our system, MediaWiki runs on one server (wikihost) and Lucene on another (km105).
- The problem is that GlobalConfiguration.isSearcher() is returning false.
- In GlobalConfiguration, the hostAddr and hostName variables are set correctly to 127.0.0.1 and the true hostname (km105). However, in the isSearcher function body, both search.get(hostAddr) and search.get(hostName) are null.
- On a different working Lucene system in my company, search.get(hostName) is non-null.
- I see only one line where the "search" hashtable gets set, in function processSearchRoles (search.put(host,hostroles)). I added some debugging, and this is getting called only for the MediaWiki host (wikihost) and not for the search host (km105).
Here is the debug output of lsearchd:
Trying config file at path /home/danb/.lsearch.conf
Trying config file at path /home/danb/src/lsearch.conf
setHost hostAddr = 127.0.0.1
setHost hostName = km105
0 [main] INFO org.wikimedia.lsearch.util.Localization - Reading localization for En
755 [main] INFO org.wikimedia.lsearch.interoperability.RMIServer - RMIMessenger bound
isIndexer hostAddr = 127.0.0.1
isIndexer hostName = km105
isIndexer index.get hostAddr = null
isIndexer index.get hostName = [*]
isSearcher hostAddr = 127.0.0.1
isSearcher hostName = km105
isSearcher search.get hostAddr = null
isSearcher search.get hostName = null (NOTE: This seems to be the problem.)
758 [Thread-1] INFO org.wikimedia.lsearch.frontend.HTTPIndexServer - Indexer started on port 8321
Here is lsearch-global.conf, which is unchanged since before the problem started:
################################################
# Global search cluster layout configuration
################################################
[Database]
wikidb : (single) (spell,4,2) (language,en)
[Search-Group]
wikihost : *
[Index]
km105 : *
[Index-Path]
<default> : /search
[OAI]
<default> : http://wikihost/w/index.php
[Namespace-Boost]
<default> : (0,2) (1,0.5)
[Namespace-Prefix]
all : <all>
[0] : 0
[1] : 1
[2] : 2
[3] : 3
[4] : 4
[5] : 5
[6] : 6
[7] : 7
[8] : 8
[9] : 9
[10] : 10
[11] : 11
[12] : 12
[13] : 13
[14] : 14
[15] : 15
And here is lsearch.conf:
MWConfig.global=file:///usr/local/lucene-search.2.1.3/lsearch-global.conf
Indexes.path=/usr/local/lucene-search-2.1.3/indexes
Rsync.path=/usr/bin/rsync
...
(the rest of the file is unchanged from the default)
Can you suggest any other debug output I can add to Lucene so it helps find the problem?