概述
/usr/local/node-v9.9.0/bin/npm install 执行该命令
npm WARN deprecated coffee-script@1.10.0: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning ECONNREFUSED: request to https://registry.npmjs.org/grunt-contrib-copy failed, reason: connect ECONNREFUSED 151.101.228.162:443npm WARN registry Using stale package data from https://registry.npmjs.org/ due to a request error during revalidation.
以上是安装head插件的报错。 node 版本
v9.9.0
采用网上的解决办法
/usr/local/node-v9.9.0/bin/npm install -g cnpm --registry=https://registry.npm.taobao.org
/usr/local/node-v9.9.0/bin/npm start 还是报错
> elasticsearch-head@0.0.0 start /usr/local/elasticsearch-head-master
> grunt server
sh: grunt: 未找到命令
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! elasticsearch-head@0.0.0 start: `grunt server`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the elasticsearch-head@0.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-04-21T08_42_24_584Z-debug.log
/usr/local/node-v9.9.0/bin/npm install -g grunt-cli
执行安装
npm run start 还是报错
/usr/local/node-v9.9.0/bin/npm config set registry https://registry.npm.taobao.org 设置淘宝的 pacakge mirror/usr/local/node-v9.9.0/bin/npm install
此时再执行/usr/local/node-v9.9.0/bin/npm run start
一切ok
参考地址:https://www.cnblogs.com/kidsitcn/p/4557548.html
最后
以上就是鲜艳发带为你收集整理的es 安装head插件的问题的全部内容,希望文章能够帮你解决es 安装head插件的问题所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复