我们正在使用带有Zookeeper 3.4.6的Solr 4.7.1,2带有3个Zookeeper实例的Solr服务器,并且想要创建我们集合的一些别名。但是,对CREATEALIAS的调用失败,如下所示:
<response>
<lst name="responseHeader">
<int name="status">500</int>
<int name="QTime">180045</int>
</lst>
<lst name="error">
<str name="msg">createalias the collection time out:180s</str>
<str name="trace">
org.apache.solr.common.SolrException: createalias the collection time out:180s
at org.apache.solr.handler.admin.CollectionsHandler.handleResponse(CollectionsHandler.java:252)
at org.apache.solr.handler.admin.CollectionsHandler.handleResponse(CollectionsHandler.java:233)
at org.apache.solr.handler.admin.CollectionsHandler.handleCreateAliasAction(CollectionsHandler.java:311) at org.apache.solr.handler.admin.CollectionsHandler.handleRequestBody(CollectionsHandler.java:157)
at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135)
at org.apache.solr.servlet.SolrDispatchFilter.handleAdminRequest(SolrDispatchFilter.java:720)
at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:265)
at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:205)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1852)
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)
</str>
<int name="code">500</int>
</lst>
</response>
我通过调用以下URL来创建别名:
http://<MYSERVER:PORT>/solr/admin/collections?action=CREATEALIAS&name=<ALIAS_NAME>&collections=<COLLECTION_NAME>
SolrCloud中我的一个Solr服务器的主机名和端口在哪里。为什么会超时,我该如何让它工作?