Detailed tutorial on installing ElasticSearch 6.x in docker

Detailed tutorial on installing ElasticSearch 6.x in docker

First, pull the image (or just create a container and it will be pulled naturally)

docker pull elasticSearch:6.5.4

Create a container

docker run --name elasticsearch --net host -e "discovery.type=single-node" -e "network.host=IP address" elasticsearch:6.5.4 

start up

docker start elasticsearch

View logs

docker logs elasticsearch

You can see that my server has only 2G memory, so it cannot start due to insufficient memory. Change the startup memory size.

Restart ES

docker run --name elasticsearch -d -e ES_JAVA_OPTS="-Xms512m -Xmx512m" --net host -e "discovery.type=single-node" -e "network.host=IP address" -p 9200:9200 -p 9300:9300 elasticsearch

test

IP:9200

Summarize

The above is a detailed tutorial on how to install ElasticSearch 6.x with Docker. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time!

You may also be interested in:
  • Docker installs Elasticsearch7.6 cluster and sets password
  • Sample code for installing ElasticSearch and Kibana under Docker
  • How to quickly deploy an Elasticsearch cluster using docker
  • How to deploy ElasticSearch in Docker
  • Detailed explanation of using Elasticsearch visualization Kibana under Docker
  • Insufficient memory problem and solution when docker starts elasticsearch

<<:  MySql common query command operation list

>>:  Usage of Node.js http module

Recommend

Tutorial on configuring and using i3 window manager in Linux

In this article, I will show you how to install a...

How to hide and forge version number in Nginx

1. Use curl command to access by default: # curl ...

Count the list tags in HTML

1. <dl> defines a list, <dt> defines ...

A simple method to implement scheduled backup of MySQL database in Linux

Here are the detailed steps: 1. Check the disk sp...

CSS and CSS3 flexible box model to achieve element width (height) adaptation

1. CSS realizes fixed width on the left and adapt...

Tomcat components illustrate the architectural evolution of a web server

1. Who is tomcat? 2. What can tomcat do? Tomcat i...

Mysql8.0 uses window functions to solve sorting problems

Introduction to MySQL Window Functions MySQL has ...

ftp remotely connect to Linux via SSH

First install ssh in Linux, taking centos as an e...

Analysis of a MySQL deadlock scenario example

Preface Recently I encountered a deadlock problem...

Tips for implementing list loop scrolling based on jQuery (super simple)

I saw a good idea and recorded it. I have used jQ...

CSS Paint API: A CSS-like Drawing Board

1. Use Canvas images as CSS background images The...

JavaScript Timer Details

Table of contents 1. Brief Introduction 2. setInt...