安装elasticsearch5.0
2016-11-03 19:55
447 查看
0.需求
java8
1. 下载
elasticsearch官网
下载地址
2. 解压
unzip elasticsearch-.zip -d elasticsearch | tar -zxvf elasticsearch-.tar.gz
3. 运行
./elasticsearch/bin/elasticsearch
4. 报错分析
Q1:initial heap size [33554432] not equal to maximum heap size [522190848]; this can cause resize pauses and prevents mlockall from locking the entire heap
A1:cp /etc/elasticsearch/jvm.options /usr/share/elasticsearch/config/jvm.options,并将-Xmx2g 改成 -Xmx256m ,也就是heap size [268435456] /1024/1024的值
Q2:max file descriptors [4096] for elasticsearch process likely too low, increase to at least [65536]
A2:
Q3:please set [discovery.zen.minimum_master_nodes] to a majority of the number of master eligible nodes in your cluster
A3:配置文件elasticsearch.yml里设置:discovery.zen.minimum_master_nodes: 1
Q4:max virtual memory areas vm.max_map_count [65530] likely too low, increase to at least [262144]
A4:
Q5:ElasticSearch5监听外网端口
A5:
- ik官网最新git
解压到~/elasticsearch/plugins/ik中即可
参考鸣谢:
1.http://git.malu.me/%E6%9E%84%E5%BB%BAELK+Redis%E6%97%A5%E5%BF%97%E5%88%86%E6%9E%90%E7%B3%BB%E7%BB%9F/
2.https://www.elastic.co/downloads/elasticsearch
java8
1. 下载
elasticsearch官网
下载地址
2. 解压
unzip elasticsearch-.zip -d elasticsearch | tar -zxvf elasticsearch-.tar.gz
3. 运行
./elasticsearch/bin/elasticsearch
4. 报错分析
Q1:initial heap size [33554432] not equal to maximum heap size [522190848]; this can cause resize pauses and prevents mlockall from locking the entire heap
A1:cp /etc/elasticsearch/jvm.options /usr/share/elasticsearch/config/jvm.options,并将-Xmx2g 改成 -Xmx256m ,也就是heap size [268435456] /1024/1024的值
Q2:max file descriptors [4096] for elasticsearch process likely too low, increase to at least [65536]
A2:
cp /etc/security/limits.conf /etc/security/limits.conf.bak vim /etc/security/limits.conf malu hard nofile 65536 malu soft nofile 65536 其中malu是启动ElasticSearch的用户名 修改后重新登录malu用户,使用如下命令查看是否修改成功 [malu@localhost ~]$ ulimit -Hn 65536
Q3:please set [discovery.zen.minimum_master_nodes] to a majority of the number of master eligible nodes in your cluster
A3:配置文件elasticsearch.yml里设置:discovery.zen.minimum_master_nodes: 1
Q4:max virtual memory areas vm.max_map_count [65530] likely too low, increase to at least [262144]
A4:
最大线程数设置过小,需要root用户来设置: sysctl -w vm.max_map_count=262144 查看: [root@localhost ~]# sysctl -a|grep vm.max_map_count vm.max_map_count = 262144 下次启动这个设置会丢失,我们把它写入配置文件: vim /etc/sysctl.conf vm.max_map_count=262144 #添加这一行
Q5:ElasticSearch5监听外网端口
A5:
cp /etc/elasticsearch/elasticsearch.yml /usr/share/elasticsearch/config/elasticsearch.yml vim /usr/share/elasticsearch/config/elasticsearch.yml network.host: 192.168.1.222 http.port: 9200 discovery.zen.minimum_master_nodes: 1 #这里设为1, 设3的话会导致Kibana报错5. 插件plugins
- ik官网最新git
解压到~/elasticsearch/plugins/ik中即可
参考鸣谢:
1.http://git.malu.me/%E6%9E%84%E5%BB%BAELK+Redis%E6%97%A5%E5%BF%97%E5%88%86%E6%9E%90%E7%B3%BB%E7%BB%9F/
2.https://www.elastic.co/downloads/elasticsearch
相关文章推荐
- Mac 安装Elasticsearch 5.0
- Elasticsearch5.0 版本安装错误
- elasticsearch5.0集群+kibana5.0+head插件插件的安装
- 【转】Elasticsearch5.0 安装问题集锦
- Elasticsearch5.0 安装 以及 问题集锦
- Elasticsearch5.0 beta版本安装错误
- Elasticsearch 5.0版本 学习一、安装
- ElasticSearch学习26_【入门】安装Elasticsearch5.0 部署Head插件
- ElasticSearch学习25_ elasticsearch5.0 安装流程
- 安装Elasticsearch5.0 部署Head插件
- 编程实践6—Elasticsearch5.0 最新版本安装问题
- elasticsearch5.0 安装流程
- Elasticsearch5.0 安装问题集锦
- 31 原 Mac 安装Elasticsearch 5.0
- 在Windows上安装Elasticsearch 5.0
- elasticsearch 5.0 版本安装head插件
- Elasticsearch5.0 安装问题集锦
- Elasticsearch 5.0-安装使用
- Elasticsearch 入门:CentOS 5.6 安装 Elasticsearch 5.0
- ElasticSearch 5.0及head插件安装