栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 前沿技术 > 大数据 > 大数据系统

ES和Kibana的安装

ES和Kibana的安装

Elasticsearch 安装和启动:

手动下载地址:https://www.elastic.co/cn/downloads/elasticsearch
linux下命令行下载和启动:

wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.16.0-linux-x86_64.tar.gz
tar -xzvf elasticsearch-7.16.0-linux-x86_64.tar.gz
cd elasticsearch-7.16.0
./bin/elasticsearch
#验证服务启动成功
curl http://localhost:9200/

服务启动成功,返回信息如下:

{
  "name" : "node-1",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "fglq3Guo566T86ZdEhs-Z2k7w",
  "version" : {
    "number" : "7.16.0",
    "build_flavor" : "default",
    "build_type" : "tar",
    "build_hash" : "6fc81662312141fe7583691d7c1c91b8658ac17aa0d",
    "build_date" : "2021-12-02T15:46:35.697268109Z",
    "build_snapshot" : false,
    "lucene_version" : "8.10.1",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  },
  "tagline" : "You Know, for Search"
}

Kibana 安装和启动:

手动下载地址:https://www.elastic.co/cn/downloads/kibana
linux下命令行下载和启动:

wget https://artifacts.elastic.co/downloads/kibana/kibana-7.16.0-linux-x86_64.tar.gz
tar -xzvf kibana-7.16.0-linux-x86_64.tar.gz
cd kibana-7.16.0
./bin/kibana
#验证服务启动成功
http://localhost:5601/

如果服务启动成功,访问http://localhost:5601/,会出现如下界面:

常见报错和解决办法 Elasticsearch 报错1
ERROR: [2] bootstrap checks failed. You must address the points described in the following [2] lines before starting Elasticsearch.
bootstrap check failure [1] of [2]: max file descriptors [4096] for elasticsearch process is too low, increase to at least [65535]
bootstrap check failure [2] of [2]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]

解决办法:
root权限下,在/etc/security/limits.conf 文件中追加两行

elk hard nofile 65536
elk soft nofile 65536  

root权限下,在/etc/sysctl.conf 文件中追加一行

vm.max_map_count=655360

执行 sysctl -p

报错2

如果只能本地访问http://localhost:9200/,但是远程服务器不能访问这台机器的ES
解决办法:
修改config/elasticsearch.yml的配置,具体如下:

network.host: 0.0.0.0
node.name: node-1
cluster.initial_master_nodes: ["node-1"]
Kibana 报错1

如果只能本地访问http://localhost:5601/,但是远程服务器不能访问这台机器的Kibana
解决办法:
修改config/kibana.yml的配置,具体如下:

server.host: "0.0.0.0"
报错2

访问http://localhost:5601/,界面出现Kibana Server not ready yet,启动页面报错为:

Waiting until all Elasticsearch nodes are compatible with Kibana before start......

解决办法:
修改config/elasticsearch.yml的配置,具体如下:

network.host: 0.0.0.0
node.name: node-1
discovery.seed_hosts: ["127.0.0.1"]
cluster.initial_master_nodes: ["node-1"]
转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/663684.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号