elasticsearch-6.2.2 installed

Elasticsearch installation:

1) First we create a user: useradd es

Change the user password: passwd es

2) modifications root es owner is a group: chown -R es: es elasticsearch- 6.2.2

在root下:curl -H "Content-Type: application/json" -XGET 'http://127.0.0.1:9200'

The following operations appear above

3) modify the file: vi /etc/security/limits.conf

Add at the end: * - nofile 65536

Modify the file: vi /etc/sysctl.conf

Append: vm.max_map_count = 262144

Modify the network address: vi /opt/es/config/elasticsearch.yml

Modify the contents of 56 lines: network.host: Address

4) modify the config file inside under elasticsearch.yml additional plug-ins allow cross-domain access at es:

http.cors.enabled: true

http.cors.allow-origin: "*"

5) restart the virtual machine: reboot

Es the start switch for the average user: elasticsearch -d

Visit website: http://192.168.56.103:9200/

That's it ha!

 

Guess you like

Origin www.cnblogs.com/tudousiya/p/11241580.html