Elasticsearch seems to be a real-time decentralized full-text search as well as an analytics engine that is free software. And is used in projects involving Single Page Applications (SPAs). Elasticsearch is really an open source project written in Java which is used by many large organizations all over the world. It is released under the Apache License 2.0.
In this tutorial, you will learn the general features of Elasticsearch and how to install the elasticsearch step by step.
Become a Elasticsearch Certified professional by learning Elasticsearch online course from hkrtrainings!
The following are the curated features of elasticsearch. They are:
Now we will learn about the installation of elasticsearch step by step.
Step1: Explore the version of Java that is installed on your computer. Java 7 or higher is required. You can double-check by doing the following:
In the Windows Operating System (OS) (via the command prompt)
>java-version
In UNIX OS (Using Terminal) −
$ echo $JAVA_HOME
Step2: Download Elasticsearch from www.elastic.co, as indicated below, depending on your operating system.
Step3:
Elasticsearch installation is straightforward, as described below for various operating systems.Windows Operating System Elasticsearch is installed after unzipping the zip package.UNIX Operating System Elasticsearch is installed after extracting the tar file to any location.
$wget
https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch7.0.0-linux-x86_64.tar.gz
$tar -xzf elasticsearch-7.0.0-linux-x86_64.tar.gz
$ wget -qo - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo
apt-key add -
Save the repository definition as shown below −
$ echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" |
sudo tee -a /etc/apt/sources.list.d/elastic-7.x.list
$ sudo apt-get update
Get ahead in your career with our Elasticsearch Tutorial !
Now you need to install by using the following command −
$ sudo apt-get install elasticsearch
$wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch7.0.0-amd64.deb
$sudo dpkg -i elasticsearch-7.0.0-amd64.deb0
$ rpm --import https://artifacts.elastic.co/GPG-KEY-elasticsearch
elasticsearch-7.x]
name=Elasticsearch repository for 7.x packages
baseurl=https://artifacts.elastic.co/packages/7.x/yum
gpgcheck=1
gpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch
enabled=1
autorefresh=1
type=rpm-md
sudo yum install elasticsearch
Step4: Navigate to the bin folder in the Elasticsearch home directory. In the case of Windows, run the elasticsearch.bat file, or in the case of UNIX, use command prompt and terminal to run the Elasticsearch file.
In Windows
> cd elasticsearch-2.1.0/bin
> elasticsearch
In Linux
$ cd elasticsearch-2.1.0/bin
$ ./elasticsearch
Step5: The default port for the Elasticsearch web interface is 9200, but this can be changed by changing http.port in the elasticsearch.yml file located in the bin directory. To see if the server is up and running, go to http://localhost:9200. It will return a JSON object containing information about the installed Elasticsearch in the format shown below.
{
"name" : "Brain-Child",
"cluster_name" : "elasticsearch", "version" : {
"number" : "2.1.0",
"build_hash" : "72cd1f1a3eee09505e036106146dc1949dc5dc87",
"build_timestamp" : "2015-11-18T22:40:03Z",
"build_snapshot" : false,
"lucene_version" : "5.3.1"
},
"tagline" : "You Know, for Search"
}
Step6: Now we should install Kibana. Follow the respective code given below for installing on Linux and Windows −
For Installation on Linux −
wget https://artifacts.elastic.co/downloads/kibana/kibana-7.0.0-linuxx86_64.tar.gz
tar -xzf kibana-7.0.0-linux-x86_64.tar.gz
cd kibana-7.0.0-linux-x86_64/
./bin/kibana
For Windows Installation
Kibana for Windows can be downloaded from https://www.elastic.co/products/kibana. When you click the link, you will be taken to the home page, as shown below.
Unzip and go to the Kibana home directory in order to run it.
CD c:\kibana-7.0.0-windows-x86_64
.\bin\kibana.bat
In the above blog post we had explained about the installation steps of elasticsearch both for linux and windows operating system. Had any queries drop them in the comments section to get them resolved.
Related Articles:
Batch starts on 28th Sep 2023, Weekday batch
Batch starts on 2nd Oct 2023, Weekday batch
Batch starts on 6th Oct 2023, Fast Track batch