JDKとかは入ってる前提で
tarを入手
今回は1.5.1
ここから
tarを展開
tar -xzf ~/Downloads/elasticsearch-1.5.1.tar.gz
確認
help
% ./elasticsearch-1.5.1/bin/elasticsearch --help ~
Usage: ./elasticsearch-1.5.1/bin/elasticsearch [-vdh] [-p pidfile] [-D prop] [-X prop]
Start elasticsearch.
-d daemonize (run in background)
-p pidfile write PID to <pidfile>
-h
--help print command line options
-v print elasticsearch version, then exit
-D prop set JAVA system property
-X prop set non-standard JAVA system property
--prop=val
--prop val set elasticsearch property (i.e. -Des.<prop>=<val>)
必要があれば$PATHを通せばよい
起動
% ./elasticsearch-1.5.1/bin/elasticsearch
確認
% curl "http://localhost:9200"
{
"status" : 200,
"name" : "Northstar",
"cluster_name" : "elasticsearch",
"version" : {
"number" : "1.5.1",
"build_hash" : "5e38401bc4e4388537a615569ac60925788e1cf4",
"build_timestamp" : "2015-04-09T13:41:35Z",
"build_snapshot" : false,
"lucene_version" : "4.10.4"
},
"tagline" : "You Know, for Search"
}
番外: Pluginのインストール
kuromoji入れる
% ./elasticsearch-1.5.1/bin/plugin --install elasticsearch/elasticsearch-analysis-kuromoji/2.5.0
1.5.1に2.5.0で大丈夫かと思いつつ。入れたら再起動。