solr--4.3.0异常及处理
1-出现org.apache.solr.common.SolrException: Error loading class 'solr.VelocityResponseWriter' 异常找到$TOMCAT_HOME/solr/conf/solrconfig.xml,把<queryResponseWriter name="velocity" class="solr.VelocityResponseWriter" enable="${solr.velocity.enabled:true}"/>注释掉或者enable:false即可。
2、2081 ERROR org.apache.solr.core.SolrCore – org.apache.solr.common.SolrException: undefined field text
这个类似于3 的解答
3、1905 ERROR org.apache.solr.core.CoreContainer – Unable to create core: mysql
org.apache.solr.common.SolrException: QueryElevationComponent requires the schema to have a uniqueKeyField.
解决方案:一般这种情况就是solrconfig.xml、solr-data-config.xml、schema.xml里面写错了,
判断错误原因:1、xml各节点顺序,不要缺少一些节点:如<types><fieldtype/></types>,<fields><field /> </fields>
4、solr Caused by: org.apache.solr.handler.dataimport.DataImportHandler
原因要在solrconfig.xml引入lib,在创建core时会将配置的jar包添加到classpath下
<lib dir="${solr.install.dir:../../../..}/dist/" regex="solr-dataimporthandler-5.0.0.jar" />
<lib dir="${solr.install.dir:../../../..}/dist/" regex="solr-dataimporthandler-extras-5.0.0.jar" />
<lib dir="./" regex="mysql-connector-java-5.1.10.jar" />
页:
[1]