How to Install Elasticsearch on RHEL7.6
- 00:22 cat /etc/os-release
- 00:33 wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.8.0-x86_64.rpm
- 01:06 rpm -Uvh elasticsearch-7.8.0-x86_64.rpm
- 01:19 systemctl daemon-reload
- 01:29 systemctl enable elasticsearch.service
- 01:46 systemctl start elasticsearch.service
- 02:02 vim /etc/elasticsearch/elasticsearch.yml
- 02:54 systemctl restart elasticsearch.service
- 03:10 systemctl status elasticsearch.service
How to Install Elasticsearch on RHEL7.6
Introduction:
Elasticsearch is a distributed, open source search and analytics engine. It supports all types of data including textual, numerical, geospatial, structured, and unstructured ones. This tutorial covers the method to install Elasticsearch on RHEL7.6
Installation Process:
To check the installed version of OS, run
[root@linuxhelp ~]# cat /etc/os-release
NAME="Red Hat Enterprise Linux Server"
VERSION="7.6 (Maipo)"
ID="rhel"
ID_LIKE="fedora"
VARIANT="Server"
VARIANT_ID="server"
VERSION_ID="7.6"
PRETTY_NAME="Red Hat Enterprise Linux Server 7.6 (Maipo)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:redhat:enterprise_linux:7.6:GA:server"
HOME_URL="https://www.redhat.com/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_BUGZILLA_PRODUCT="Red Hat Enterprise Linux 7"
REDHAT_BUGZILLA_PRODUCT_VERSION=7.6
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux"
REDHAT_SUPPORT_PRODUCT_VERSION="7.6"
We need to download the Elasticsearch rpm package to install
[root@linuxhelp ~]# wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.8.0-x86_64.rpm
--2020-08-25 16:58:01-- https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.8.0-x86_64.rpm
Resolving artifacts.elastic.co (artifacts.elastic.co)... 151.101.2.222, 151.101.66.222, 151.101.130.222, ...
Connecting to artifacts.elastic.co (artifacts.elastic.co)|151.101.2.222|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 319213800 (304M) [application/octet-stream]
Saving to: ‘elasticsearch-7.8.0-x86_64.rpm’
100%[==================================================================================>] 31,92,13,800 971KB/s in 4m 35s
2020-08-25 17:02:36 (1.11 MB/s) - ‘elasticsearch-7.8.0-x86_64.rpm’ saved [319213800/319213800]
Once, the download has been completed use the below command to install elasticsearch
[root@linuxhelp ~]# rpm -Uvh elasticsearch-7.8.0-x86_64.rpm
warning: elasticsearch-7.8.0-x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID d88e42b4: NOKEY
Preparing... ################################# [100%]
Creating elasticsearch group... OK
Creating elasticsearch user... OK
Updating / installing...
1:elasticsearch-0:7.8.0-1 ################################# [100%]
NOT starting on installation, please execute the following statements to configure elasticsearch service to start automatically using systemd
sudo systemctl daemon-reload
sudo systemctl enable elasticsearch.service
You can start elasticsearch service by executing
sudo systemctl start elasticsearch.service
Created elasticsearch keystore in /etc/elasticsearch/elasticsearch.keystore
After installation we have to reload the daemon service
[root@linuxhelp ~]# systemctl daemon-reload
Now, enable the service for permanent
[root@linuxhelp ~]# systemctl enable elasticsearch.service
Created symlink from /etc/systemd/system/multi-user.target.wants/elasticsearch.service to /usr/lib/systemd/system/elasticsearch.service.
Use the following command to start elasticsearch service
[root@linuxhelp ~]# systemctl start elasticsearch.service
We have to configure the Elasticsearch yml file
[root@linuxhelp ~]# vim /etc/elasticsearch/elasticsearch.yml
After the configuration restart the service to update the changes
[root@linuxhelp ~]# systemctl restart elasticsearch.service
Now check the service status of Elasticsearch
[root@linuxhelp ~]# systemctl status elasticsearch.service
● elasticsearch.service - Elasticsearch
Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled)
Active: active (running) since Tue 2020-08-25 17:09:55 IST; 21s ago
Docs: https://www.elastic.co
Main PID: 67525 (java)
Tasks: 46
CGroup: /system.slice/elasticsearch.service
├─67525 /usr/share/elasticsearch/jdk/bin/java -Xshare:auto -Des.networkaddress.cache.ttl=60 -Des.networkaddress...
└─67680 /usr/share/elasticsearch/modules/x-pack-ml/platform/linux-x86_64/bin/controller
Aug 25 17:09:10 linuxhelp systemd[1]: Starting Elasticsearch...
Aug 25 17:09:55 linuxhelp systemd[1]: Started Elasticsearch…
Open the browser to check elastic search
In new tab provide ip address of your system with the port number of elasticsearch
With this, the method to install Elasticsearch on RHEL7.6 comes to end.
Comments ( 0 )
No comments available