1. Download the head plugin source code
Https://github.com/mobz/elasticsearch-head
2. Download Nodejs
Nodejs official website https://nodejs.org/dist/
wget Https://nodejs.org/dist/v6.9.2/node-v6.9.2-linux-x64.tar.xz
3. Configure the node environment variable
Xz–d NODE-V6.9.2-LINUX-X64.TAR.XZTAR–XVF NODE-V6.9.2-LINUX-X64.TARMV Node-v6.9.2-linux-x64/data/prg/node vim/etc/p Rofileexport node_home=/data/prg/nodeexport path= $PATH: $NODE _home/binsource/etc/profile# node–vv6.9.2# npm–v3.10.9
4, Installation Grunt
CD ELASTICSEARCH-HEADNPM install-g Grunt--registry=https://registry.npm.taobao.org
修改head目录下的Gruntfile.js配置,head默认监听127.0.0.1
# Vim Gruntfile.js
Hostname: ' 0.0.0.0 ',
650) this.width=650; "Style=" background-image:none;padding-left:0px;padding-right:0px;border-top-width:0px; border-bottom-width:0px;border-left-width:0px;padding-top:0px, "title=" QQ picture 20161214113021 "border=" 0 "alt=" QQ picture 20161214113021 "src=" Http://s3.51cto.com/wyfs02/M02/8B/8B/wKiom1hQ1OqzVJsaAAAgHT7_DeY867.png "width=" 244 " height= "108"/>
5、elasticsearch配置允许跨域访问
修改elasticsearch配置文件elasticsearch.yml
Http.cors.enabled:true http.cors.allow-origin: "*"
6. Restart Elasticsearch and Start node
CD Elasticsearch-head Node_modules/grunt/bin/grunt Server
650) this.width=650; "Style=" background-image:none;margin:0px;padding-left:0px;padding-right:0px; border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px; "title=" image "border=" 0 "alt = "image" src= "Http://s3.51cto.com/wyfs02/M02/8B/88/wKioL1hQ1OvA4mOKAAAovKYYLcY389.png" width= "244" height= "55"/ >
Visit http://192.168.62.200:9100
650) this.width=650; "Style=" background-image:none;margin:0px;padding-left:0px;padding-right:0px; border-top-width:0px;border-bottom-width:0px;border-left-width:0px;padding-top:0px; "title=" image "border=" 0 "alt = "image" src= "Http://s3.51cto.com/wyfs02/M00/8B/88/wKioL1hQ1OyDmtADAABJ62j1ucQ332.png" width= "244" height= "84"/ >
ELASTICSEARCH5 version cluster management tool head installation