Description: elasticsearch is currently the most popular search engine, powerful and very popular. This article introduces the installation of es and the visual interface kibana of es under the Cent OS 7 system, and the remote connection tool is WindTerm;
The first step: install es
Start docker, pull the es image, select the version number: 7.12.1
docker pull elasticsearch:7.12.1
I have already pulled it here, and it will take a little time to pull it for the first time;
Step 2: Install kibana
Pull another es visual interface kibana, version number selection: 7.12.1
docker pull kibana:7.12.1
Step Three: Create the Network
The es container and the kibana container need to be interconnected, and a network environment needs to be created
docker network create es-net
Step 4: Create a container and start it
Create an es container and start it
docker run -d \
--name es \
-e "ES_JAVA_OPTS=-Xms512m -Xmx512m" \
-e "discovery.type=single-node" \
-v es-data:/usr/share/elasticsearch/data \
-v es-plugins:/usr/share/elasticsearch/plugins \
--privileged \
--network es-net \
-p 9200:9200 \
-p 9300:9300 \
elasticsearch:7.12.1
Create a kibana container and start it
docker run -d \
--name kibana \
-e ELASTICSEARCH_HOSTS=http://es:9200 \
--network=es-net \
-p 5601:5601 \
kibana:7.12.1
Step Five: Use
Open the browser, first visit port 9200, es platform (http://IP address: 9200)
When accessing port 5601, it is the visual interface of kibana and es. The response may be a bit slow. If the access fails, you can wait and try again;
You can open Dev Tools, enter a sentence, and you can view the sentence segmentation on the right, because es is developed by foreigners, and it is not very compatible with Chinese, so you can install the IK tokenizer;