• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Just Installed Elasticsearch, Unable to Rebuild Search index

XxUnkn0wnxX

Active member
#1
i get this error when i try to rebuild the index:

Code:
Error Info
XenForo_Exception: Elasticsearch indexing failed. See the server error log for more details. - library/XenES/Search/SourceHandler/ElasticSearch.php:1098
Generated By: XxAdminxX, 2 minutes ago
Stack Trace

#0 /home/Admin/public_html/forums/library/XenES/Search/SourceHandler/ElasticSearch.php(76): XenES_Search_SourceHandler_ElasticSearch->_triggerFailedIndexError(Object(stdClass), Array)
#1 /home/Admin/public_html/forums/library/XenForo/Search/Indexer.php(125): XenES_Search_SourceHandler_ElasticSearch->finalizeRebuildSet()
#2 /home/Admin/public_html/forums/library/XenForo/Deferred/SearchIndex.php(76): XenForo_Search_Indexer->finalizeRebuildSet()
#3 /home/Admin/public_html/forums/library/XenForo/Model/Deferred.php(295): XenForo_Deferred_SearchIndex->execute(Array, Array, 5.8576600551605, '')
#4 /home/Admin/public_html/forums/library/XenForo/Model/Deferred.php(429): XenForo_Model_Deferred->runDeferred(Array, 5.8576600551605, '', false)
#5 /home/Admin/public_html/forums/library/XenForo/Model/Deferred.php(374): XenForo_Model_Deferred->_runInternal(Array, 5.8576610088348, '', false)
#6 /home/Admin/public_html/forums/library/XenForo/ViewRenderer/Abstract.php(352): XenForo_Model_Deferred->run(true, 5.8576610088348)
#7 /home/Admin/public_html/forums/library/XenForo/ViewRenderer/HtmlAdmin.php(131): XenForo_ViewRenderer_Abstract::hasManualDeferredToRun(true)
#8 /home/Admin/public_html/forums/library/XenForo/FrontController.php(639): XenForo_ViewRenderer_HtmlAdmin->renderContainer(Object(XenForo_Template_Admin), Array)
#9 /home/Admin/public_html/forums/library/XenForo/FrontController.php(158): XenForo_FrontController->renderView(Object(XenForo_ControllerResponse_Error), Object(XenForo_ViewRenderer_HtmlAdmin), Array)
#10 /home/Admin/public_html/forums/admin.php(13): XenForo_FrontController->run()
#11 {main}

Request State

array(3) {
  ["url"] => string(61) "https://portalcentric.net/forums/admin.php?tools/run-deferred"
  ["_GET"] => array(1) {
    ["tools/run-deferred"] => string(0) ""
  }
  ["_POST"] => array(3) {
    ["redirect"] => string(66) "https://portalcentric.net/forums/admin.php?tools/rebuild&success=1"
    ["execute"] => string(1) "1"
    ["_xfToken"] => string(8) "********"
  }
}
Code:
An exception occurred: Elasticsearch indexing failed. See the server error log for more details. in /home/Admin/public_html/forums/library/XenES/Search/SourceHandler/ElasticSearch.php on line 1098

    XenES_Search_SourceHandler_ElasticSearch->_triggerFailedIndexError() in XenES/Search/SourceHandler/ElasticSearch.php at line 76
    XenES_Search_SourceHandler_ElasticSearch->finalizeRebuildSet() in XenForo/Search/Indexer.php at line 125
    XenForo_Search_Indexer->finalizeRebuildSet() in XenForo/Deferred/SearchIndex.php at line 76
    XenForo_Deferred_SearchIndex->execute() in XenForo/Model/Deferred.php at line 295
    XenForo_Model_Deferred->runDeferred() in XenForo/Model/Deferred.php at line 429
    XenForo_Model_Deferred->_runInternal() in XenForo/Model/Deferred.php at line 374
    XenForo_Model_Deferred->run() in XenForo/ViewRenderer/Abstract.php at line 352
    XenForo_ViewRenderer_Abstract::hasManualDeferredToRun() in XenForo/ViewRenderer/HtmlAdmin.php at line 131
    XenForo_ViewRenderer_HtmlAdmin->renderContainer() in XenForo/FrontController.php at line 639
    XenForo_FrontController->renderView() in XenForo/FrontController.php at line 158
    XenForo_FrontController->run() in /home/unkn0wn/public_html/forums/admin.php at line 13
Here is My Config Info: my Elasticsearch server configured properly?

And Yes its Enabled & service is running

Code:
curl -XGET 'localhost:9200'
{
  "name" : "Sundragon",
  "cluster_name" : "Xenportal",
  "cluster_uuid" : "IYRff-0tTgKHtPYjmYgUTA",
  "version" : {
    "number" : "2.4.1",
    "build_hash" : "c67dc32e24162035d18d6fe1e952c4cbcbe79d16",
    "build_timestamp" : "2016-09-27T18:57:55Z",
    "build_snapshot" : false,
    "lucene_version" : "5.5.2"
  },
  "tagline" : "You Know, for Search"
}
 

XxUnkn0wnxX

Active member
#3
What is in the server error log?
you mean the error_log file found in the root of the forums folder or an error log in the actual server /var/log?

the error_log file in root forum folder doesnt contain anything

I already posted the error logs I got from Xenforo
 
Last edited:

XxUnkn0wnxX

Active member
#4
this is from the /var/log/elasticsearch/Xenportal.log

https://gist.github.com/XxUnkn0wnxX/f07faa5eead0dc84174e46987310a416

had to post in there because Xenforo say to many characters.

reading over long I think it permission / ownership issues and I'm not sure how to fix I already set the /var/elasticsearch folder to chown -R elasticsearch:elasticsearch /var/elasticsearch

and chmod 755 the folder

Any Clues on how to fix?

Edit: Fixed it

had to do

sudo chmod 755 -R /var/elasticsearch
sudo chown elasticsearch:elasticsearch -R /var/elasticsearch

also I changed the index name to lowercase

either it was the sudo before commands or the changing to lowercase that fixed it.
 
Last edited: