【问题标题】:SOLR '0' Status: Communication ErrorSOLR '0' 状态:通信错误
【发布时间】:2013-01-08 21:52:12
【问题描述】:

我正在使用 SOLR 索引文档。我从 mysql 数据库创建索引。我从在 wamp 服务器上运行的 PHP 创建索引。我正在使用 SOLR PHP 客户端创建索引。当我从部署 SOLR 的服务器创建索引时,一切正常。但是当我尝试从另一台机器创建索引时,我收到以下错误:

“0”状态:通信错误

我尝试更改 php 套接字超时、solr commitlocktimeout 和 solr writelocktimeout。但我仍然得到同样的错误。当我从 solr server itslef 创建索引时,没有错误。

PHP 版本:5.2.2 SOLR 版本:1.4.1

知道为什么会这样吗?

谢谢

以下是我的堆栈跟踪:

'0' Status: Communication Error#0 C:\wamp\www\nist\application\library\SolrPhpClient\Apache\Solr\Service.php(672): Apache_Solr_Service->_sendRawPost('http://129.107....', '<add allowDups=...')
#1 C:\wamp\www\nist\application\library\SolrPhpClient\Apache\Solr\Service.php(736): Apache_Solr_Service->add('<add allowDups=...')
#2 C:\wamp\www\nist\application\library\Nist\Console\NistSolrIndex.php(106): Apache_Solr_Service->addDocuments(Array)
#3 C:\wamp\www\nist\application\library\Nist\Console\CrawlUNT.php(346): Nist_Console_NistSolrIndex->createIndex()
#4 C:\wamp\www\nist\application\library\Nist\Console\CrawlUNT.php(89): Nist_Console_CrawlUNT->CrawlParseAndIndexProfiles()
#5 C:\wamp\www\nist\application\Bootstrap.php(107): Nist_Console_CrawlUNT->run(Object(Zend_Console_Getopt))
#6 C:\wamp\www\nist\application\Bootstrap.php(78): Bootstrap->_runConsoleApp()
#7 C:\wamp\www\dkumar\mentis-libs\Zend\Application.php(366): Bootstrap->run()
#8 C:\wamp\www\nist\index.php(37): Zend_Application->run()

【问题讨论】:

  • 你检查过你的防火墙设置了吗?
  • @user1959447 请与我们分享您完整的 Solr 堆栈跟踪。
  • 我忘了说。我在SOLR中添加文档的时候,是分批添加的,50条。因为我的表有很多记录,所以由于内存的限制,我必须分批添加。 “通讯错误”仅发生在某些批次中。对于其他批次,文档会正确添加。
  • 您找到可以分享的解决方案了吗?

标签: solr


【解决方案1】:

我们在更改密码时遇到了同样的问题。它是由新密码中的特殊字符引起的。删除 '@', '/' '()' 解决了这个问题。

Solr:4.9,PHP:5.6

【讨论】:

    猜你喜欢
    • 2015-04-01
    • 2015-05-21
    • 2014-03-22
    • 2013-11-20
    • 2022-11-11
    • 1970-01-01
    • 2014-02-20
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多