Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Construction of ElasticSearch Multi-Node Model

2025-04-02 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

Environmental preparation:

Environment CentOS7

JDK1.8 is installed

The elasticsearch6.2.2 used here as an example, you can also use version 5.6.1 or higher

Refer to the previous single-node mode

Https://blog.51cto.com/6989066/2334006

(1) first confirm whether the SSH is connected between the slave node and the master node, that is, confirm that password-free login has been configured between the nodes.

And then use the

Scp-r / opt/module/elasticsearch-5.2.2 root@hdp22:/opt/module/elasticsearch-5.2.2

Scp-r / opt/module/elasticsearch-5.2.2 root@hdp23:/opt/module/elasticsearch-5.2.2

.

Copy to multiple slave nodes

Where root is the user name of the target node, and hdp22 is the hostname of the target node. I have already configured this in / etc/hosts, or you can use the IP address instead. It is recommended to use hostname.

(2) modify the elasticsearch.yml under the / opt/module/elasticsearch-5.2.2/config directory

Be careful

1. Line 17 cluster name, this must be the same

2.23 line node.name. This different node must be different.

3. Modify line 44pm 45 in Memery.

-- Memory--

Bootstrap.memory_lock: false

Bootstrap.system_call_filter: false

4. Modify about 57, 61, and 70 lines. 57 lines of domain names, you can check the host name through the hostname command; 61 lines of port numbers, 70 lines of cluster nodes.

(3) modify the configuration file under the etc directory with the root account on the slave node

Sudo vi / etc/security/limits.conf

Sudo vi / etc/security/limits.d/20-nproc.conf (not necessarily at the beginning of 20)

Sudo vi / etc/sysctl.conf

And execute the command: sudo sysctl-p

Then, restart elasticsearch to start successfully.

To modify the configuration file, please refer to the previous elasticsearch single-node configuration.

Https://blog.51cto.com/6989066/2334006

(4) start elasticsearch on multiple nodes

Bin/elasticsearch

Background startup mode

[itstar@hadoop105 elasticsearch-5.6.1] $bin/elasticsearch-d

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report