我正在尝试确定elasticsearch实例是否在运行,但似乎没有:
ubuntu@ubuntu:~$ sudo service elasticsearch status
* elasticsearch is not running
ubuntu@ubuntu:~$ sudo service elasticsearch start
* Starting Elasticsearch Server [ OK ]
ubuntu@ubuntu:~$ sudo service elasticsearch status
* elasticsearch is not running
and
ubuntu@ubuntu:~$ sudo /etc/init.d/elasticsearch status
* elasticsearch is not running
ubuntu@ubuntu:~$ sudo /etc/init.d/elasticsearch start
* Starting Elasticsearch Server [ OK ]
ubuntu@ubuntu:~$ sudo /etc/init.d/elasticsearch status
* elasticsearch is not running
ubuntu@ubuntu:/etc/elasticsearch# sudo service elasticsearch restart
* Stopping Elasticsearch Server [ OK ]
* Starting Elasticsearch Server [ OK ]
ubuntu@ubuntu:/etc/elasticsearch# sudo service elasticsearch status
* elasticsearch is not running
以及
ubuntu@ubuntu:~$ curl -XGET localhost:9200/_nodes/_all/process?pretty
curl: (7) Failed to connect to localhost port 9200: Connection refused
和
ubuntu@ubuntu:/etc/elasticsearch$ sudo netstat -nlp
tcp6 0 0 :::9300 :::* LISTEN 4413/java
更新
我的elasticsearch.log:
[2014-12-03 00:00:02,161][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] creating index, cause [auto(bulk api)], shards [5]/[1], mappings [_default_]
[2014-12-03 00:00:02,617][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] update_mapping [logs] (dynamic)
[2014-12-03 00:00:12,737][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] update_mapping [logs] (dynamic)
[2014-12-03 00:00:17,587][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] update_mapping [logs] (dynamic)
[2014-12-03 00:00:18,842][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] update_mapping [logs] (dynamic)
[2014-12-03 01:00:01,430][INFO ][cluster.metadata ] [Zero] [logstash-2014.11.25] deleting index
[2014-12-03 09:46:57,461][INFO ][cluster.metadata ] [Zero] [logstash-2014.12.03] update_mapping [logs] (dynamic)