测试环境:
Ubuntu x86_64
3.13.0-35-generic
安装jre:
$ sudo apt-get install software-properties-common $ sudo add-apt-repository ppa:webupd8team/java $ sudo apt-get update $ sudo apt-get install oracle-java7-installer
加入 Elasticsearch 官方源并安装 elasticsearch
$ wget --no-check-certificate -O - http://packages.elasticsearch.org/GPG-KEY-elasticsearch | sudo apt-key add - $ sudo echo "deb http://packages.elasticsearch.org/elasticsearch/1.1/debian stable main" >> /etc/apt/sources.list $ sudo apt-get update $ sudo apt-get install elasticsearch
随系统启停
$ sudo update-rc.d elasticsearch defaults 95 1
启动 elasticsearch 服务
$ sudo /etc/init.d/elasticsearch start $ curl -X GET 'http://localhost:9200'