我 5 天前重新启动了我的 elasticsearch 实例,从那以后我就无法启动它了。
在使用 运行时,日志文件中没有输出任何输出,二进制文件/var/log/elasticsearch/
也没有打印任何信息。elasticsearch
elasticsearch -f
我曾经设法获得这个输出。
[2012-11-15 22:51:18,427][INFO ][node ] [Piper] {0.19.11}[29584]: initializing ...
[2012-11-15 22:51:18,433][INFO ][plugins ] [Piper] loaded [], sites []
运行curl http://localhost:9200
结果为curl: (7) couldn't connect to host
。
我尝试将内存从 3GB 增加到 10GB,但没有任何变化。
运行/etc/init.d/elasticsearch start
需要 30 秒。ps aux | grep elasticsearch
结果如下。
/usr/local/share/elasticsearch/bin/service/exec/elasticsearch-linux-x86-64 /usr/local/share/elasticsearch/bin/service/elasticsearch.conf wrapper.syslog.ident=elasticsearch wrapper.pidfile=/usr/local/share/elasticsearch/bin/service/./elasticsearch.pid wrapper.name=elasticsearch wrapper.displayname=ElasticSearch wrapper.daemonize=TRUE wrapper.statusfile=/usr/local/share/elasticsearch/bin/service/./elasticsearch.status wrapper.java.statusfile=/usr/local/share/elasticsearch/bin/service/./elasticsearch.java.status wrapper.script.version=3.5.14
/usr/lib/jvm/java-7-openjdk-amd64/jre/bin/java -Delasticsearch-service -Des.path.home=/usr/local/share/elasticsearch -Xss256k -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:CMSInitiatingOccupancyFraction=75 -XX:+UseCMSInitiatingOccupancyOnly -XX:+HeapDumpOnOutOfMemoryError -Djava.awt.headless=true -Xms1024m -Xmx1024m -Djava.library.path=/usr/local/share/elasticsearch/bin/service/lib -classpath /usr/local/share/elasticsearch/bin/service/lib/wrapper.jar:/usr/local/share/elasticsearch/lib/elasticsearch-0.19.11.jar:/usr/local/share/elasticsearch/lib/elasticsearch-0.19.11.jar:/usr/local/share/elasticsearch/lib/jna-3.3.0.jar:/usr/local/share/elasticsearch/lib/log4j-1.2.17.jar:/usr/local/share/elasticsearch/lib/lucene-analyzers-3.6.1.jar:/usr/local/share/elasticsearch/lib/lucene-core-3.6.1.jar:/usr/local/share/elasticsearch/lib/lucene-highlighter-3.6.1.jar:/usr/local/share/elasticsearch/lib/lucene-memory-3.6.1.jar:/usr/local/share/elasticsearch/lib/lucene-queries-3.6.1.jar:/usr/local/share/elasticsearch/lib/snappy-java-1.0.4.1.jar:/usr/local/share/elasticsearch/lib/sigar/sigar-1.6.4.jar -Dwrapper.key=k7r81VpK3_Bb3N_5 -Dwrapper.port=32000 -Dwrapper.jvm.port.min=31000 -Dwrapper.jvm.port.max=31999 -Dwrapper.disable_console_input=TRUE -Dwrapper.pid=23888 -Dwrapper.version=3.5.14 -Dwrapper.native_library=wrapper -Dwrapper.service=TRUE -Dwrapper.cpu.timeout=10 -Dwrapper.jvmid=1 org.tanukisoftware.wrapper.WrapperSimpleApp org.elasticsearch.bootstrap.ElasticSearchF
我当前的系统:
- ElasticSearch 版本:0.19.11,JVM:23.2-b09
- Ubuntu 12.04 LTS
- OpenJDK 64 位服务器 VM - 1.7.0_09
我尝试重新安装 elasticsearch、删除旧目录、重新安装 java 并重新启动服务器。
为何我无法启动它?
答案1
您能尝试在不使用的情况下启动它-Dwrapper.disable_console_input=TRUE
吗?
例如,我曾见过 Java 问题,其中的损坏 JAR 影响了日志系统,而且很容易通过类似的方式捕获。
答案2
解决方案是将 VPS 上的核心数量从一个增加到两个。