美文网首页
环境搭建Kibana&ElasticSearch

环境搭建Kibana&ElasticSearch

作者: perfect_coding | 来源:发表于2019-07-23 13:40 被阅读0次

Kibana 可以对 Elasticsearch 索引中的数据进行搜索、查看、交互操作。可以很方便的利用图表、表格及地图对数据进行多元化的分析和呈现。安装Kibana之前,我们必须先安装好ElasticSearch

1、安装并运行ElasticSearch

1.1 安装 Elasticsearch 之前,你需要先安装一个较新的版本的 Java,传送门www.java.com
1.2 从 elastic 的官网获取最新版本的 Elasticsearch,传送门 elastic.co/downloads/elasticsearch

我这里下载的是6.4.0版本,直接解压即可,解压后的目录像下面这个样子


QQ20190723-135003@2x.png

1.3 启动Elasticsearch,命令如下:

cd ~/Kibana/elasticsearch-6.4.0
./bin/elasticsearch

1.4 测试是否启动成功,我们直接在浏览器里访问网址:http://localhost:9200,得到如下结果,那么启动成功

QQ20190723-135615@2x.png

其中包含了我们ES簇的名称,版本等信息,这些信息随后在配置文件中修改会讲到。
那么到目前为止,我们的ES环境已经安装完成。

2、安装并运行Kibana

  1. 利用同样的方式,我们安装并解压Kibana到如图1所示的位置,我这里将ES和Kibana放在同一个目录下,Kibana下载地址 传送门

  2. 此时,如果我们进入Kibana目录,然后直接启动Kibana的话,启动会成功,但是会得到一个错误页面,启动命令如下:

./bin/kibana

访问网址:http://localhost:5601,得到的结果如下:

QQ20190723-141554@2x.png
这是因为我们没有配置Kibana与ES的连接
  1. 配置Kibana

    3.1 进入Kibana的config目录,找到kibana.yml文件,我们所有的配置都在这个文件找那个进行
    3.2 配置*.yml文件

cd config
vim kibana.yml

主要配置以下几项,其他配置先不用管,配置内容如下:

# Kibana is served by a back end server. This setting specifies the port to use.
server.port: 5601

# Specifies the address to which the Kibana server will bind. IP addresses and host names are both valid values.
# The default is 'localhost', which usually means remote machines will not be able to connect.
# To allow connections from remote users, set this parameter to a non-loopback address.
server.host: "localhost"

# Enables you to specify a path to mount Kibana at if you are running behind a proxy.
# Use the `server.rewriteBasePath` setting to tell Kibana if it should remove the basePath
# from requests it receives, and to prevent a deprecation warning at startup.
# This setting cannot end in a slash.
#server.basePath: ""

# Specifies whether Kibana should rewrite requests that are prefixed with
# `server.basePath` or require that they are rewritten by your reverse proxy.
# This setting was effectively always `false` before Kibana 6.3 and will
# default to `true` starting in Kibana 7.0.
#server.rewriteBasePath: false

# The maximum payload size in bytes for incoming server requests.
#server.maxPayloadBytes: 1048576

# The Kibana server's name.  This is used for display purposes.
server.name: "your-hostname"

# The URL of the Elasticsearch instance to use for all your queries.
elasticsearch.url: "http://localhost:9200"

以上四项包括了设置Kibana的

  • 主机
  • 端口号
  • 服务名称(可选)
  • ES的地址,

配置完毕后,我们重启Kibana,再次进行访问,得到以下结果,那么恭喜你,环境已经搭建成功!


QQ20190723-143049@2x.png

接下来,我会

  • 对一个简单的数据案例进行分析
  • 对自己的数据(json、csv)进行处理,存入ES,然后进行分析

相关文章

  • 环境搭建Kibana&ElasticSearch

    Kibana 可以对 Elasticsearch 索引中的数据进行搜索、查看、交互操作。可以很方便的利用图表、表格...

  • React Native学习总结篇

    一、环境搭建 1.1 React Native环境搭建 1.1.1 IOS环境搭建 环境:MacOS 注意:不要使...

  • linux 第四天

    Lamp环境搭建 /*******************Lamp环境搭建:*******************...

  • codePush说明

    codePush环境搭建 环境搭建文章:环境搭建 git地址:codePush git地址2.0.3,And...

  • angular学习--02英雄指南

    环境搭建 angular官网--搭建本地开发环境和工作空间windows 10 搭建angular开发环境免搭建环...

  • Gradle开发-Groovy环境搭建

    ##Groovy环境搭建 在使用 Groovy 之前首先要搭建几个环境: Groovy 的环境搭建 JDK 环境搭...

  • 搭建 LNMP + CodeIgniter 开发环境

    搭建 LNMP + CodeIgniter 开发环境搭建 LNMP 环境首先搭建 LNMP 的服务器环境安装 Ng...

  • iOS中RN与Flutter混合开发

    一 搭建环境 1. 搭建flutter环境 1.1 搭建系统开发环境 参考链接:https://flutter....

  • 第一个MyBatis程序

    思路:搭建环境---导入MyBatis--编写代码---测试! 一、搭建环境 1、搭建数据库环境: engine=...

  • Robot Framework用法总结

    一,环境的搭建 关于robotframework环境搭建请参考博文:Robot Framework的环境搭建[ht...

网友评论

      本文标题:环境搭建Kibana&ElasticSearch

      本文链接:https://www.haomeiwen.com/subject/jrjolctx.html