我正在尝试设置多核 solr 安装,但似乎无法正确配置 solr 以加载所需的类。
运行的输出java -jar start.jar
包括:
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrResourceLoader replaceClassLoader
INFO: Adding 'file:/software/solr/solr/contrib/analysis-extras/lib/icu4j-4.8.1.1.jar' to classloader
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrResourceLoader replaceClassLoader
INFO: Adding 'file:/software/solr/solr/contrib/analysis-extras/lucene-libs/lucene-icu-3.6.1.jar' to classloader
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrResourceLoader replaceClassLoader
INFO: Adding 'file:/software/solr/solr/contrib/analysis-extras/lucene-libs/lucene-smartcn-3.6.1.jar' to classloader
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrResourceLoader replaceClassLoader
INFO: Adding 'file:/software/solr/solr/contrib/analysis-extras/lucene-libs/lucene-stempel-3.6.1.jar' to classloader
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrConfig <init>
WARNING: <indexDefaults> and <mainIndex> configuration sections are deprecated (but still work). Please use <indexConfig> instead.
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrConfig <init>
INFO: Using Lucene MatchVersion: LUCENE_36
Sep 11, 2012 4:23:16 PM org.apache.solr.core.SolrConfig <init>
INFO: Loaded SolrConfig: solrconfig.xml
Sep 11, 2012 4:23:16 PM org.apache.solr.schema.IndexSchema readSchema
INFO: Reading Solr Schema
... snip ...
Sep 11, 2012 4:23:16 PM org.apache.solr.common.SolrException log
SEVERE: java.lang.NoClassDefFoundError: org/apache/lucene/analysis/icu/ICUFoldingFilter
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.java:388)
at org.apache.solr.core.SolrResourceLoader.newInstance(SolrResourceLoader.java:409)
at org.apache.solr.util.plugin.AbstractPluginLoader.create(AbstractPluginLoader.java:83)
org/apache/lucene/analysis/icu/ICUFoldingFactory
存在于lucene-icu-3.6.1.jar
为什么后来找不到?
我的目录结构是:
|-solr
|---contrib
|-----analysis-extras
|-------lib
|-------lucene-libs
|-----velocity
|-------lib
|---cores
|-----core0
|-------conf
|-------data
|---------index
|-----core1
|-------conf
|-------data
|-----core2
|-------conf
|-------data
|---------index
|---lib
|-----solrj-lib
|-------optional