Kibana 简明教程

Kibana - Environment Setup

要开始使用 Kibana,我们需要安装 Logstash、Elasticsearch 和 Kibana。在本章节中,我们将尝试了解 ELK 堆栈的安装。

To start working with Kibana we need to install Logstash, Elasticsearch and Kibana. In this chapter, we will try to understand the installation of the ELK stack here.

我们将在此讨论以下安装:

We would discuss the following installations here −

  1. Elasticsearch Installation

  2. Logstash Installation

  3. Kibana Installation

Elasticsearch Installation

Elasticsearch 有详细的文档在我们的库中。您可以在此处查看 elasticsearch installation 。您将必须按照教程中提到的步骤安装 Elasticsearch。

A detailed documentation on Elasticsearch exists in our library. You can check here for elasticsearch installation. You will have to follow the steps mentioned in the tutorial to install Elasticsearch.

安装完成后,按如下方式启动 elasticsearch 服务器:

Once done with the installation, start the elasticsearch server as follows −

Step 1

For Windows

For Windows

> cd kibanaproject/elasticsearch-6.5.4/elasticsearch-6.5.4/bin
> elasticsearch

请注意,对于 windows 用户,需要将 JAVA_HOME 变量设置为 java jdk 路径。

Please note for windows user, the JAVA_HOME variable has to be set to the java jdk path.

For Linux

For Linux

$ cd kibanaproject/elasticsearch-6.5.4/elasticsearch-6.5.4/bin
$ elasticsearch
elasticsearch installation

elasticsearch 的默认端口是 9200。完成后,您可以在 localhost http://localhost:9200/as 上的端口 9200 处检查 elasticsearch,如下所示:

The default port for elasticsearch is 9200. Once done, you can check the elasticsearch at port 9200 on localhost http://localhost:9200/as shown below −

elasticsearch default port
elasticsearch localhost

Logstash Installation

要安装 Logstash,请遵循 elasticsearch installation ,该连接已存在于我们的库中。

For Logstash installation, follow this elasticsearch installation which is already existing in our library.

Kibana Installation

访问官方 Kibana 网站 − https://www.elastic.co/products/kibana

Go to the official Kibana site −https://www.elastic.co/products/kibana

kibana installation

单击右上角的下载链接,它将显示如下屏幕:

Click the downloads link on the top right corner and it will display screen as follows −

kibana downloads

点按下载 Kibana 按钮。请注意,为了使用 Kibana,我们需要 64 位机器,它不能在 32 位机器上运行。

Click the Download button for Kibana. Please note to work with Kibana we need 64 bit machine and it will not work with 32 bit.

kibana button

在本教程中,我们将使用 Kibana 6 版本。Windows、Mac 和 Linux 都提供下载选项。您可以根据自己的选择进行下载。

In this tutorial, we are going to use Kibana version 6. The download option is available for Windows, Mac and Linux. You can download as per your choice.

创建一个文件夹并解压缩 kibana 的 tar/zip 下载文件。我们将使用弹性搜索中上传的样本数据。所以,目前让我们看看如何启动弹性搜索和 kibana。为此,请转到 kibana 解压所在的文件夹。

Create a folder and unpack the tar/zip downloads for kibana. We are going to work with sample data uploaded in elasticsearch. Thus, for now let us see how to start elasticsearch and kibana. For this, go to the folder where Kibana is unpacked.

For Windows

For Windows

> cd kibanaproject/kibana-6.5.4/kibana-6.5.4/bin
> kibana

For Linux

For Linux

$ cd kibanaproject/kibana-6.5.4/kibana-6.5.4/bin
$ kibana

Kibana 启动后,用户可以看到以下屏幕 −

Once Kibana starts, the user can see the following screen −

kibana starts

一旦在控制台中看到准备信号,您就可以使用 http://localhost:5601/ 在浏览器中打开 Kibana。Kibana 可用的默认端口为 5601。

Once you see the ready signal in the console, you can open Kibana in browser using http://localhost:5601/.The default port on which kibana is available is 5601.

Kibana 的用户界面如下图所示 −

The user interface of Kibana is as shown here −

kibana interface

在下一章中,我们将学习如何使用 Kibana 的 UI。要了解 Kibana UI 上的 Kibana 版本,请转到左侧的“管理”选项卡,它将显示我们当前使用的 Kibana 版本。

In our next chapter, we will learn how to use the UI of Kibana. To know the Kibana version on Kibana UI, go to Management Tab on left side and it will display you the Kibana version we are using currently.

kibana ui