solr集群部署问题
@曾杰 你好,想跟你请教个问题:
您好,我这个部署之前是可以的,在重启之后就不行了,错误日志如下
2014-11-13 11:01:05,297 ERROR [coreLoadExecutor-4-thread-1] org.apache.solr.cloud.ZkController (ZkController.java:1226) - Could not find configName for collection programSerial
2014-11-13 11:01:05,299 ERROR [coreLoadExecutor-4-thread-1] org.apache.solr.core.CoreContainer (CoreContainer.java:988) - Unable to create core: programSerial
org.apache.solr.common.cloud.ZooKeeperException: Could not find configName for collection programSerial found:null
at org.apache.solr.cloud.ZkController.getConfName(ZkController.java:1227)
at org.apache.solr.cloud.ZkController.createCollectionZkNode(ZkController.java:1158)
at org.apache.solr.core.ZkContainer.createFromZk(ZkContainer.java:230)
at org.apache.solr.core.CoreContainer.create(CoreContainer.java:595)
at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:258)
at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:250)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
2014-11-13 11:01:05,301 ERROR [coreLoadExecutor-4-thread-1] org.apache.solr.common.SolrException (SolrException.java:120) - null:org.apache.solr.common.SolrException: Unable to create core: programSerial
at org.apache.solr.core.CoreContainer.recordAndThrow(CoreContainer.java:989)
at org.apache.solr.core.CoreContainer.create(CoreContainer.java:606)
at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:258)
at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:250)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.solr.common.cloud.ZooKeeperException: Could not find configName for collection programSerial found:null
at org.apache.solr.cloud.ZkController.getConfName(ZkController.java:1227)
at org.apache.solr.cloud.ZkController.createCollectionZkNode(ZkController.java:1158)
at org.apache.solr.core.ZkContainer.createFromZk(ZkContainer.java:230)
at org.apache.solr.core.CoreContainer.create(CoreContainer.java:595)
... 8 more
配置文件信息
<solr>
<cores adminPath="/admin/cores" host="${host:}" hostPort="${hostport:1080}" hostContext="${hostContext:solr}" zkHost="${zkHost:203.195.197.15:2181}" zkClientTimeout="${zkClientTimeout:15000}" genericCoreNodeNames="${genericCoreNodeNames:true}">
<shardHandlerFactory name="shardHandlerFactory"
class="HttpShardHandlerFactory">
<int name="socketTimeout">${socketTimeout:0}</int>
<int name="connTimeout">${connTimeout:0}</int>
<str name="urlScheme">${urlScheme:}</str>
</shardHandlerFactory>
<core name="programSerial" instanceDir="programSerial" />
<core name="aspectprogramSerial" instanceDir="aspectprogramSerial" />
</cores>
</solr>
catalina.sh
JAVA_OPTS="$JAVA_OPTS -DzkHost=localhost:2181 -DnumShards=2"
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
回复
Zookeeper本身就是集中管理了,配置文件只要初始化一次就ok了,就把zk当成本地文件系统就行了
zookeeper里面没有这个collection的配置文件,可以先去zookeeper的/config 节点下看有没有指定collection的配置目录,如果没有可以哟个ZkCLI把配置文件初始化进去