【问题标题】:Solr 3.6.1 replication master not found未找到 Solr 3.6.1 复制主机
【发布时间】:2013-07-02 15:04:28
【问题描述】:

使用 Solr 3.6.1,在 10.0.0.73 的从站上执行 'fetchindex' 命令时出现以下错误:

严重:http://10.0.0.249:8983/solr/my_core/replication 的大师不可用。索引提取失败。例外:对 url org.apache.commons.httpclient.methods.PostMethod@388a2006 的请求失败

在 10.0.0.249 的 master 上的 my_core 核心在 solrconfig.xml 中有以下配置

<requestHandler name="/replication" class="solr.ReplicationHandler" >                    
    <lst name="master">                                                                  
        <str name="replicateAfter">commit</str>                                          
        <str name="replicateAfter">startup</str>                                         
        <str name="confFiles">schema.xml,stopwords.txt</str>                            
    </lst>                                                                               
</requestHandler> 

在 10.0.0.73 的从属服务器上,my_core 在其 solrconfig.xml 中配置了复制

<requestHandler name="/replication" class="solr.ReplicationHandler">                   
  <lst name="slave">                                                                   
    <str name="masterUrl">http://10.0.0.249:8983/solr/my_core/replication</str>     
    <str name="pollInterval">00:00:60</str> 
  </lst>                                                                               
</requestHandler>

我想我在做一些明显的错误,但是在阅读和重新阅读有关复制的 Solr 文档以及这里和其他方面的大量帖子后,找不到它。有人有想法吗?请注意,发送到主服务器的其他请求会成功,例如

GET http://10.0.0.249:8983/solr/my_core/select

返回

<?xml version="1.0" encoding="UTF-8"?>                                                   
<response>                                                                               
  <lst name="responseHeader">
     <int name="status">0</int>
     <int name="QTime">0</int>
     <lst name="params"/>
  </lst>
  <result name="response" numFound="0" start="0"/>                         

【问题讨论】:

标签: solr replication


【解决方案1】:

您在从属配置上的主 URL 指定为,

<str name="masterUrl">http://10.0.0.249:8983/solr/my_core/replication</str>

正确的网址是

<str name="masterUrl">http://10.0.0.249:8983/solr/my_core</str>

您只需要在核心名称之前指定 URL。

【讨论】:

    猜你喜欢
    • 2011-10-19
    • 2014-07-31
    • 2013-04-05
    • 2021-05-15
    • 2013-07-22
    • 1970-01-01
    • 2012-05-16
    • 2016-01-23
    • 1970-01-01
    相关资源
    最近更新 更多