Last active
January 15, 2016 03:41
-
-
Save jonathanbardo/94dc66d83735640fc792 to your computer and use it in GitHub Desktop.
Install Elasticsearch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install on ubuntu trusty tahr 14.04 | |
# I do this with root user, but if you sudo access with your user it will work too! | |
sudo su | |
# Update apt-get | |
apt-get update | |
# Install java jdk 7 or java jdk 8 or oracle jdk | |
apt-get install openjdk-7-jre-headless | |
# Make sure java is installed | |
java -version | |
# This should output: java version "1.7.XX" | |
# Navigate to the installation folder you want (for me /opt/) | |
cd /opt/ | |
# Download elasticsearch and untar | |
wget -qO- https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-1.4.2.tar.gz | tar xvz | |
# In /opt/elasticsearch-1.4.2.tar.gz/config/elasticsearch.yml | |
# Uncomment and change those lines to the following: | |
# network.host: localhost | |
# cluster.name: YOUR-CLUSTER-NAME | |
# Start elasticsearch in the background (reference here for those who wants a service http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/setup-service.html) | |
/opt/elasticsearch-1.4.2/bin/elasticsearch -d | |
# Check if the server is running | |
curl -XGET http://localhost:9200 | |
# Sample output: | |
#{ | |
# "status" : 200, | |
# "name" : "Nicholas Scratch", | |
# "cluster_name" : "elasticsearch", | |
# "version" : { | |
# "number" : "1.4.2", | |
# "build_hash" : "927caff6f05403e936c20bf4529f144f0c89fd8c", | |
# "build_timestamp" : "2014-12-16T14:11:12Z", | |
# "build_snapshot" : false, | |
# "lucene_version" : "4.10.2" | |
# }, | |
# "tagline" : "You Know, for Search" | |
#} | |
# DONE! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment