Hi, I'm trying to set up the dev env in kibana to be able to write plugins later.
I'm having trouble with the "npm run elasticsearch" command. It generates this error : sana@sana:~/kibana$ sudo npm run elasticsearch [sudo] password for sana:
kibana@6.0.0-alpha2 elasticsearch /home/sana/kibana
grunt esvm:dev:keepalive
Loading "ui_framework.js" tasks...ERROR
Error: Missing binding /home/sana/kibana/node_modules/node-sass/vendor/linux-x64-48/binding.node
Node Sass could not find a binding for your current environment: Linux 64-bit with Node.js 6.xFound bindings for the following environments:
- Linux 64-bit with Node.js 4.x
This usually happens because your environment has changed since running
npm install
.
Runnpm rebuild node-sass
to build the binding for your current environment.
Running "esvm:dev:keepalive" (esvm) task
starting up "dev" cluster
Keeping elasticsearch alive, to shutdown press command/control+c
INFO - - cluster - Downloading & installing from "master" branch.
INFO - - cluster - Installing plugins
INFO - - cluster - Starting 1 nodes
INFO - ? - ? - [2017-05-31T14:46:27,329][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] uncaught exception in thread [main]
INFO - ? - ? - org.elasticsearch.bootstrap.StartupException: java.lang.RuntimeException: can not run elasticsearch as root
INFO - ? - ? - at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:127) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:114) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:67) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - Caused by: java.lang.RuntimeException: can not run elasticsearch as root
INFO - ? - ? - at org.elasticsearch.bootstrap.Bootstrap.initializeNatives(Bootstrap.java:105) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:171) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:330) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:123) ~[elasticsearch-6.0.0-alpha2-SNAPSHOT.jar:6.0.0-alpha2-SNAPSHOT]
INFO - ? - ? - ... 6 more
Fatal error: Server exitted with the non-zero exit code 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! kibana@6.0.0-alpha2 elasticsearch: grunt esvm:dev:keepalive
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the kibana@6.0.0-alpha2 elasticsearch script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/sana/.npm/_logs/2017-05-31T12_46_27_629Z-debug.log
sana@sana:~/kibana$ cat /home/sana/.npm/_logs/2017-05-31T12_46_27_629Z-debug.log0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/nodejs',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'run',
1 verbose cli 'elasticsearch' ]
2 info using npm@4.6.1
3 info using node@v6.10.3
4 verbose run-script [ 'preelasticsearch', 'elasticsearch', 'postelasticsearch' ]
5 info lifecycle kibana@6.0.0-alpha2~preelasticsearch: kibana@6.0.0-alpha2
6 silly lifecycle kibana@6.0.0-alpha2~preelasticsearch: no script for preelasticsearch, continuing
7 info lifecycle kibana@6.0.0-alpha2~elasticsearch: kibana@6.0.0-alpha2
8 verbose lifecycle kibana@6.0.0-alpha2~elasticsearch: unsafe-perm in lifecycle true
9 verbose lifecycle kibana@6.0.0-alpha2~elasticsearch: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/home/sana/kibana/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
10 verbose lifecycle kibana@6.0.0-alpha2~elasticsearch: CWD: /home/sana/kibana
11 silly lifecycle kibana@6.0.0-alpha2~elasticsearch: Args: [ '-c', 'grunt esvm:dev:keepalive' ]
12 silly lifecycle kibana@6.0.0-alpha2~elasticsearch: Returned: code: 1 signal: null
13 info lifecycle kibana@6.0.0-alpha2~elasticsearch: Failed to exec elasticsearch script
14 verbose stack Error: kibana@6.0.0-alpha2 elasticsearch: grunt esvm:dev:keepalive
14 verbose stack Exit status 1
14 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:279:16)
14 verbose stack at emitTwo (events.js:106:13)
14 verbose stack at EventEmitter.emit (events.js:191:7)
14 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)
14 verbose stack at emitTwo (events.js:106:13)
14 verbose stack at ChildProcess.emit (events.js:191:7)
14 verbose stack at maybeClose (internal/child_process.js:886:16)
14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
15 verbose pkgid kibana@6.0.0-alpha2
16 verbose cwd /home/sana/kibana
17 verbose Linux 4.11.2-041102-generic
18 verbose argv "/usr/bin/nodejs" "/usr/local/bin/npm" "run" "elasticsearch"
19 verbose node v6.10.3
20 verbose npm v4.6.1
21 error code ELIFECYCLE
22 error errno 1
23 error kibana@6.0.0-alpha2 elasticsearch: grunt esvm:dev:keepalive
23 error Exit status 1
24 error Failed at the kibana@6.0.0-alpha2 elasticsearch script.
24 error This is probably not a problem with npm. There is likely additional logging output above.
25 verbose exit [ 1, true ]
Can anyone helm me please?