码迷,mamicode.com
首页 > 其他好文 > 详细

elasticsearch-head插件安装及启动,关闭命令

时间:2021-01-19 12:26:21      阅读:0      评论:0      收藏:0      [点我收藏+]

标签:$path   not found   方法   ps aux   显示   down   download   es6   模式   

启动插件 /elasticsearch-head目录
npm run start
启动elasticsearch 不能使用root账号 切换账号:su es
./bin/elasticsearch 打印日志 前台运行,Ctrl + C 则程序终止
./bin/elasticsearch -d 后台运行模式

查看进程
ps aux | grep head
ps -ef | grep elastic
jps jps 命令查看运行状态
查看端口
lsof -i :9200
kill -9 1509 关闭进程


安装命令
nodejs: yum -y install nodejs
node -v
npm -v
git -version

-bash: lsof: command not found 解决方法
yum install lsof -y
yum install wget -y
npm install -g grunt-cli

Elasticsearch-head 启动 关闭
1.启动head:grunt server
2.后台启动head:nohup grunt server &
或:启动插件 /elasticsearch-head目录
npm run start

3.查看head 进程:lsof -i :9100
4.停止head:kill -9 进程id

1.通过浏览器添加插件
谷歌浏览器访问http://extb.cqttech.com/search/elasticsearch%2520head
根据提示下载安装谷歌双核浏览器
放大镜图标使用插件

2.1.安装node.js
1.1、通过官网下载二进制安装包
https://nodejs.org/en/download/
选择: Linux Binaries (x64) 安装包

cd /usr/local/
wget https://nodejs.org/dist/v10.16.3/node-v10.16.3-linux-x64.tar.xz

tar -xJf node-v10.16.3-linux-x64.tar.xz
命令对比:
安装es6.6.1
tar -zxvf elasticsearch-6.6.1.tar.gz

1.3、配置环境变量
vi /etc/profile
在文件最后面追加node.js环境变量

export NODE_HOME=/usr/local/node-v10.16.3-linux-x64
export PATH=$NODE_HOME/bin:$PATH

1.4、重新加载配置文件并验证是否安装成功
source /etc/profile
node -v
npm -v

2.1、安装git插件
yum install -y git
2.2、验证git插件是否安装成功
git --version


2.3、下载并安装head插件
git clone git://github.com/mobz/elasticsearch-head.git
cd elasticsearch-head/
npm install
2.4、配置elasticsearch,允许head插件远程访问
cd elasticsearch-6.5.1/config/
vi elasticearch.yml
在配置文件末尾添加如下内容,重新启动elasticsearch服务

http.cors.enabled: true
http.cors.allow-origin: "*"
2.5、启动elasticsearch-head服务
cd elasticsearch-head/
npm run start


通过head插件连接elasticsearch服务
输入elasticsearch服务地址,点击连接右边显示黄色信息说明连接成功,至此elasticsearch-head插件安装成功

链接:https://www.cnblogs.com/keystone/p/13266528.html

elasticsearch-head插件安装及启动,关闭命令

标签:$path   not found   方法   ps aux   显示   down   download   es6   模式   

原文地址:https://www.cnblogs.com/oktokeep/p/14296208.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!