Elasticsearch 7.7.0容器化部署
一、Elasticsearch容器化部署
1.1 Pull Elasticsearch镜像
[root@10-27-0-224 ~]# docker pull docker.elastic.co/elasticsearch/elasticsearch:7.7.0
1.2 运行Elasticsearch容器
[root@10-27-0-224 ~]# docker run --name=elastic770 -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" -v /var/docker/elastic/data:/data docker.elastic.co/elasticsearch/elasticsearch:7.7.0
【注】测试环境加上-e "discovery.type=single-node"
1.3 修改Elasticsearch配置
[root@10-27-0-224 ~]# vim elasticsearch.yml cluster.name: "elasticsearch7.7.0" network.host: 0.0.0.0 node.name: node0 http.host: 0.0.0.0 http.cors.enabled: true http.cors.allow-origin: "*"
# 拷贝到docker容器中,覆盖原有配置文件 [root@10-27-0-224 ~]# docker cp elasticsearch.yml elastic770:/usr/share/elasticsearch/config
二、组件安装
2.1 安装IK分词插件
[root@10-27-0-224 ~]# docker exec -it elastic770 bash [root@caec54c6b617 elasticsearch]# find / -name elasticsearch-plugin /usr/share/elasticsearch/bin/elasticsearch-plugin [root@caec54c6b617 elasticsearch]#/usr/share/elasticsearch/bin/elasticsearch-plugin install https://jeecgos.oss-cn-beijing.aliyuncs.com/eoafile/elasticsearch-analysis-ik-7.7.0.zip
2.2 安装可视化管理工具
[root@10-27-0-224 ~]# docker run -p 9800:9800 -d --link elastic770:hd containerize/elastichd
三、图形化展示
作者:UStarGao
链接:https://www.starcto.com/Cloud-BigData-AI/208.html
来源:STARCTO
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。
UCloud云平台推荐
随便看看
- 2021-09-14开源入侵检测系统OSSEC介绍
- 2021-07-20CI/CD Pipeline之Gitlab部署
- 2021-05-22MongoDB 集合与文档的相关操作
- 2022-03-31MongoDB分片集群安装部署教程
- 2021-01-23MySQL YUM安装教程