Install Elasticsearchedit

Elasticsearch is a real-time, distributed storage, search, and analytics engine. It can be used for many purposes, but one context where it excels is indexing streams of semi-structured data, such as logs or decoded network packets.

The binary packages of Elasticsearch have only one dependency: Java. The minimum supported version is Java 8. To download and install Elasticsearch, use the commands that work with your system (deb for Debian/Ubuntu, rpm for Redhat/Centos/Fedora, mac for OS X, and win for Windows):

deb:

sudo apt-get install openjdk-8-jre
curl -L -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.0.1.deb
sudo dpkg -i elasticsearch-6.0.1.deb
sudo /etc/init.d/elasticsearch start

rpm:

sudo yum install java-1.8.0-openjdk
curl -L -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.0.1.rpm
sudo rpm -i elasticsearch-6.0.1.rpm
sudo service elasticsearch start

mac:

# install Java, e.g. from: https://www.java.com/en/download/manual.jsp
curl -L -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.0.1.zip
unzip elasticsearch-6.0.1.zip
cd elasticsearch-6.0.1
./bin/elasticsearch

win:

  1. If necessary, download and install the latest version of the Java from www.java.com.
  2. Download the Elasticsearch 6.0.1 Windows zip file from the downloads page.
  3. Extract the contents of the zip file to a directory on your computer, for example, C:\Program Files.
  4. Open a command prompt as an Administrator and navigate to the directory that contains the extracted files, for example:

    cd C:\Program Files\elasticsearch-6.0.1
  5. Run the following command to start Elasticsearch:

    bin\elasticsearch.bat

You can learn more about installing, configuring, and running Elasticsearch in the Elasticsearch Reference.

Make sure Elasticsearch is up and runningedit

To test that the Elasticsearch daemon is up and running, try sending an HTTP GET request on port 9200.

curl http://127.0.0.1:9200

On Windows, if you don’t have cURL installed, simply point your browser to the URL.

You should see a response similar to this:

{
  "name" : "ofgAtrJ",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "3h9xSrVlRJmDHgQ8FLnByA",
  "version" : {
    "number" : "6.0.1",
    "build_hash" : "db0d481",
    "build_date" : "2017-02-09T22:05:32.386Z",
    "build_snapshot" : false,
    "lucene_version" : "6.4.1"
  },
  "tagline" : "You Know, for Search"
}