How to setup Elastic Stack on Windows

1. Setup Elasticsearch

Step 1: Download Elasticsearch

Download Elasticsearch from Elaticsearch download page. I have downloaded ZIP file: elasticsearch-5.6.3.zip and extract it to a desired location.

Step 2: Start Elasticsearch

In command prompt, navigate to the bin folder in the location where the zip file was extracted and run elasticsearch.bat
D:\Programs\elasticsearch-5.6.3\bin>elasticsearch.bat
Step 3: Check if Elasticsearch is up and running

By default, Elasticsearch uses port 9200 to provide access to its REST API. Run the following GET API using curl or any browser REST Client like Postman:
http://localhost:9200/


If everything is working fine, you will get a response similar to the following:
{
    "name": "BPvgCM7",
    "cluster_name": "elasticsearch",
    "cluster_uuid": "p9pora6VRUmf5M9HBrMbyw",
    "version": {
        "number": "5.6.3",
        "build_hash": "1a2f265",
        "build_date": "2017-10-06T20:33:39.012Z",
        "build_snapshot": false,
        "lucene_version": "6.6.1"
    },
    "tagline": "You Know, for Search"
}

2. Setup Logstash

Step 1: Download Logstash

Download Loagstash from Logstash download page. I have downloaded ZIP file: logstash-5.6.3.zip and extract it to a desired location.

Step 2: Create a config file

To configure Logstash, a config file needs to be created that specifies which plugins you want to use and settings for each plugin. A Logstash config file has a separate section for each type of plugin you want to add to the event processing pipeline. Here is an example of a basic config file to output to both Elasticsearch and stdout:
logstash-basic.conf:
input { stdin { } }
output {
  elasticsearch { hosts => ["localhost:9200"] }
  stdout { codec => rubydebug }
}
Step 3: Start Logstash

Place the file logstash-basic.conf in the bin folder in the location where the zip file was extracted. In command prompt, navigate to the bin folder and run the following command:
D:\Programs\logstash-5.6.3\bin>logstash -f logstash-basic.conf

3. Setup Kibana

Step 1: Download Kibana

Download Loagstash from Kibana download page. I have downloaded ZIP file: kibana-5.6.3-windows-x86.zip and extract it to a desired location.

Step 2: Configure Elasticsearch URL in kibana.yml

In the location where the zip file was extracted, open config/kibana.yml and set elasticsearch.url to point at your Elasticsearch instance
I have used:
elasticsearch.url: "http://localhost:9200"
Step 3: Start Kibana

In command prompt, navigate to the bin folder in the location where the zip file was extracted and run kibana.bat
D:\Programs\kibana-5.6.3-windows-x86\bin>kibana.bat









Comments

Popular Posts

Elasticsearch, Logstash, Kibana Tutorial: Load MySQL Data into Elasticsearch

Dropwizard MySQL Integration Tutorial

Send Email in Java