zookeeper SolrCloud 集群配置 Error: Could not find or load main class org.apache.solr.cloud.ZkCLI

人盡茶涼 提交于 2019-12-05 03:55:08

搭建SolrCloud集群 

把solrhome中的配置文件上传到zookeeper集群。使用zookeeper的客户端上传。

客户端命令位置:/root/solr-4.10.3/example/scripts/cloud-scripts

执行命令 

./zkcli.sh -zkhost 192.168.40.138:2181,192.168.40.138:2182,192.168.40.138:2183 -cmd upconfig -confdir /usr/local/solrcloud/solrhome1/collection1/conf -confname myconf

时报错。


 解决办法:

 Easy fix: cd solr-4.8.0/example, java -jar start.jar, (let it start up), Control-C. You'll now have files under solr-4.8.0-bin/example/solr-webapp/webapp including the missing jars in solr-4.8.0-bin/example/solr-webapp/webapp/WEB-INF/lib – Mark Bennett

上述解决办法来自http://stackoverflow.com/questions/15830090/reloading-zookeeper-solr-conf-schema-xml

即:在/root/solr-4.10.3/example目录下执行 java -jar start.jar 命令。

然后ctrl c 结束。或者是打开另一个窗口。

/root/solr-4.10.3/example/scripts/cloud-scripts

执行命令 

./zkcli.sh -zkhost 192.168.40.138:2181,192.168.40.138:2182,192.168.40.138:2183 -cmd upconfig -confdir /usr/local/solrcloud/solrhome1/collection1/conf -confname myconf

即可完成配置文件上传。

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!