我有一臺運行Ubuntu 12.04的虛擬機,並試圖安裝ElasticSearch。我已經按照這個gist在最好的'學習X的硬道路'的精神,一切都安裝好 - 包下載,untarred,複製到正確的地方等在Ubuntu 12.04上安裝ElasticSearch
當我運行它的問題來了 - 要麼通過調用:
$ /usr/local/share/elasticsearch/bin/elasticsearch
或通過使用
輸出被記錄到wrapper.log
和下方被包括在服務包裝器($ rselasticsearch console
)。我認爲我可能會遇到JAVA home/classpath問題,但我不確定。
任何幫助最感激地收到!
Running ElasticSearch...
wrapper | Unable to write to the configured log directory: /usr/local/share/elasticsearch/logs (No such file or directory)
wrapper | The directory does not exist.
wrapper | Unable to write to the configured log file: /usr/local/share/elasticsearch/logs/service.log (No such file or directory)
wrapper | Falling back to the default file in the current working directory: wrapper.log
wrapper | --> Wrapper Started as Console
wrapper | Java Service Wrapper Community Edition 32-bit 3.5.14
wrapper | Copyright (C) 1999-2011 Tanuki Software, Ltd. All Rights Reserved.
wrapper | http://wrapper.tanukisoftware.com
wrapper |
wrapper | Launching a JVM...
jvm 1 | WrapperManager: Initializing...
jvm 1 | WrapperSimpleApp Error: Unable to locate the class org.elasticsearch.bootstrap.ElasticSearchF : java.lang.ClassNotFoundException: org.elasticsearch.bootstrap.ElasticSearchF
jvm 1 |
jvm 1 | WrapperSimpleApp Usage:
jvm 1 | java org.tanukisoftware.wrapper.WrapperSimpleApp {app_class{/app_method}} [app_arguments]
jvm 1 |
jvm 1 | Where:
jvm 1 | app_class: The fully qualified class name of the application to run.
jvm 1 | app_arguments: The arguments that would normally be passed to the
jvm 1 | application.
wrapper | JVM exited while loading the application.
...
wrapper | There were 5 failed launches in a row, each lasting less than 300 seconds. Giving up.
wrapper | There may be a configuration problem: please check the logs.
wrapper | <-- Wrapper Stopped
更新
鑑於我們現在是在2016年,在Ubuntu上運行ES最簡單的方法是使用多克。 docker run elasticsearch
將下載最新的並在前臺運行它,顯然你可以運行它作爲一個守護進程,或運行特定版本(例如elasticsearch:1.7.2
),並設置端口等
確保您獲取包裝的正確版本太多,請參閱自述[這裏](https://開頭的github .com/elasticsearch/elasticsearch-servicewrapper「here」)。 – reim