前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >ElasticSearch 6.x 学习笔记:2.head与Kibana安装

ElasticSearch 6.x 学习笔记:2.head与Kibana安装

作者头像
程裕强
发布2018-01-02 16:56:35
1.6K0
发布2018-01-02 16:56:35
举报

2.1 Head插件简介

ElasticSearch-head是一个H5编写的ElasticSearch集群操作和管理工具,可以对集群进行傻瓜式操作。

  • 显示集群的拓扑,并且能够执行索引和节点级别操作
  • 搜索接口能够查询集群中原始json或表格格式的检索数据
  • 能够快速访问并显示集群的状态
  • 有一个输入窗口,允许任意调用RESTful API。这个接口包含几个选项,可以组合在一起以产生有趣的结果;
  • 5.0版本之前可以通过plugin名安装,5.0之后可以独立运行。

2.2 Head插件安装

(1)安装NodeJS

代码语言:javascript
复制
[root@node1 ~]# yum install -y nodejs

(2)按钮npm

代码语言:javascript
复制
[root@node1 ~]#  npm install -g cnpm --registry=https://registry.npm.taobao.org

(3)使用npm安装grunt

代码语言:javascript
复制
[root@node1 ~]# npm install -g grunt-cli --registry=https://registry.npm.taobao.org --no-proxy
/usr/bin/grunt -> /usr/lib/node_modules/grunt-cli/bin/grunt
/usr/lib
└─┬ grunt-cli@1.2.0 
  ├─┬ findup-sync@0.3.0 
  │ └─┬ glob@5.0.15 
  │   ├─┬ inflight@1.0.6 
  │   │ └── wrappy@1.0.2 
  │   ├── inherits@2.0.3 
  │   ├─┬ minimatch@3.0.4 
  │   │ └─┬ brace-expansion@1.1.8 
  │   │   ├── balanced-match@1.0.0 
  │   │   └── concat-map@0.0.1 
  │   ├── once@1.4.0 
  │   └── path-is-absolute@1.0.1 
  ├── grunt-known-options@1.1.0 
  ├─┬ nopt@3.0.6 
  │ └── abbrev@1.1.1 
  └── resolve@1.1.7 

[root@node1 ~]# 

(4)下载head插件源码

代码语言:javascript
复制
[es@node1 ~]$ wget https://github.com/mobz/elasticsearch-head/archive/master.zip
--2017-12-18 09:58:08--  https://github.com/mobz/elasticsearch-head/archive/master.zip
Resolving github.com (github.com)... 192.30.255.113, 192.30.255.112
Connecting to github.com (github.com)|192.30.255.113|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://codeload.github.com/mobz/elasticsearch-head/zip/master [following]
--2017-12-18 09:58:09--  https://codeload.github.com/mobz/elasticsearch-head/zip/master
Resolving codeload.github.com (codeload.github.com)... 192.30.255.120, 192.30.255.121
Connecting to codeload.github.com (codeload.github.com)|192.30.255.120|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 921421 (900K) [application/zip]
Saving to: ‘master.zip’

100%[===============================================================>] 921,421     9.64KB/s   in 67s    

2017-12-18 09:59:18 (13.4 KB/s) - ‘master.zip’ saved [921421/921421]

[es@node1 ~]$ ls
master.zip
[es@node1 ~]$ unzip master.zip 

(5)下载依赖

代码语言:javascript
复制
[es@node1 elasticsearch-head-master]$ su root 
Password: 
[root@node1 elasticsearch-head-master]# npm install -g cnpm --registry=https://registry.npm.taobao.org
/usr/bin/cnpm -> /usr/lib/node_modules/cnpm/bin/cnpm
/usr/lib
└── cnpm@5.1.1 

[root@node1 elasticsearch-head-master]# 

(6)配置 ElasticSearch,使得HTTP对外提供服务

代码语言:javascript
复制
[es@node1 elasticsearch-6.1.0]$ vi config/elasticsearch.yml

添加如下内容

代码语言:javascript
复制
# 增加新的参数,这样head插件可以访问es。设置参数的时候:后面要有空格
http.cors.enabled: true
http.cors.allow-origin: "*"

(7)运行 grunt server

(8)访问9100端口

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2017-12-18 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • 2.1 Head插件简介
  • 2.2 Head插件安装
相关产品与服务
Elasticsearch Service
腾讯云 Elasticsearch Service(ES)是云端全托管海量数据检索分析服务,拥有高性能自研内核,集成X-Pack。ES 支持通过自治索引、存算分离、集群巡检等特性轻松管理集群,也支持免运维、自动弹性、按需使用的 Serverless 模式。使用 ES 您可以高效构建信息检索、日志分析、运维监控等服务,它独特的向量检索还可助您构建基于语义、图像的AI深度应用。
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档