# Marvel installation nodejs error?

**URL:** <https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001>\
**Category:** Kibana\
**Tags:** elastic-stack-monitoring\
**Created:** [December 11, 2015, 4:18pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001 "2015-12-11T16:18:00Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![stpruitt](https://avatars.discourse-cdn.com/v4/letter/s/df705f/32.png) [@stpruitt](https://discuss.elastic.co/u/stpruitt)\
**Post date:** [December 11, 2015, 4:18pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/1 "2015-12-11T16:18:00Z")

</div>

Newbie question.

I have ES 2.1.0 installed. I installed kibana 4.3.0. The marvel 2.1.0 plugin is installed in ES.

The marvel installation instructions next said to install in kibana via: bin/kibana plugin --install elasticsearch/marvel/latest

when i try that i get this error: \nodejs\node.exe was unexpected at this time

I am not sure what this is telling me. I see nothing about nodejs in the installation instructions.

Thanks in advance for any help.

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [December 11, 2015, 5:21pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/2 "2015-12-11T17:21:54Z")

</div>

This looks like it might be a problem with Kibana's ability to install plugins on your system, rather than a problem with Marvel itself.

To confirm, can you try installing Sense, which an interactive ES query builder/editor, into Kibana like this:

bin/kibana plugin --install elastic/sense

Please let us know if that is successful. Also, what OS and Java versions are you running?

---

<div class="post-metadata">

**Author:** ![stpruitt](https://avatars.discourse-cdn.com/v4/letter/s/df705f/32.png) [@stpruitt](https://discuss.elastic.co/u/stpruitt)\
**Post date:** [December 11, 2015, 7:29pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/3 "2015-12-11T19:29:44Z")

</div>

Yep, you are right. Same problem. I am running Windows 7 with jre 8.

Looking at the kibana bat file… NODE is set to ./kibana-4.3.0/node/node.exe. Which exists. So I am not sure why - If Not Exist "%NODE%" – is failing.

Thanks.

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [December 11, 2015, 7:58pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/4 "2015-12-11T19:58:04Z")

</div>

I'm not a Kibana plugin ninja, but Is there anything strange going on with file permissions in this directory?

Are you running this in a console with cygwin, powershell, or cmd.exe?

I just tried this on my windows 10 machine from the cmd.exe console, with Java version "1.8.0\_66" and it worked fine, though I had to use the backslash between bin and kibana:

`bin\kibana plugin --install elastic/sense`

---

<div class="post-metadata">

**Author:** ![stpruitt](https://avatars.discourse-cdn.com/v4/letter/s/df705f/32.png) [@stpruitt](https://discuss.elastic.co/u/stpruitt)\
**Post date:** [December 11, 2015, 8:43pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/5 "2015-12-11T20:43:33Z")

</div>

i am truly confused. i found a post for a windows batch file issue that looked similar to the logic in the kibana.bat file indicating the error message was unexpected at this time means there was an issue parsing the open and closing parens in the IF statement. So I rewrote kibana.bat to be:

If Exist "%NODE%" goto :run  
IF Exist "%SYS\_NODE%" goto :usesys  
Echo unable to find usable node.js executable.  
Exit /B 1  
:usesys  
set NODE=%SYS\_NODE%  
:run  
TITLE Kibana Server  
"%NODE%" "%DIR%\src\cli" %\*

I think I got further, not sure. but i do have a different error:  
c:\Executables\kibana-4.3.0\>bin\kibana plugin --install elasticsearch/marvel/latest  
c:\Executables\kibana-4.3.0\src\utils\packageJson.js:20  
throw new Error('unable to find package.json');  
^  
Error: unable to find package.json  
at Object. (c:\Executables\kibana-4.3.0\src\utils\packageJson.js:20:11)  
at Module.\_compile (module.js:460:26)  
at Module.\_extensions..js (module.js:478:10)  
at Object.require.extensions.(anonymous function) [as .js]  
(c:\Executables\kibana-4.3.0\node\_modules\babel-core\lib\api\register\node.js:214:7)  
at Module.load (module.js:355:32)  
at Function.Module.\_load (module.js:310:12)  
at Module.require (module.js:365:17)  
at require (module.js:384:17)  
at requireModule (c:\Executables\kibana-4.3.0\node\_modules\requirefrom\index.js:24:10)  
at Object. (c:\Executables\kibana-4.3.0\src\cli\cli.js:6:11)

I looked at packageJson.js. It looks like that error comes from not being able to run from the right directory level. I feel like I am doing something fundamentally wrong, but its escaping me. Why does it work for you and not me?  
I open a command shell at the top level kibana folder (where I unzipped) and run bin/kibana...

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [December 11, 2015, 10:34pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/6 "2015-12-11T22:34:14Z")

</div>

In nearly all cases, editing the kibana.bat is a bad idea 🙂

If it works for me but not you, it's likely to be something environmental on your side.  
What command shell are you using? cmd.exe, cygwin, powershell? I'm using cmd.exe.  
Which Kibana file did you download - the `zip` or the `tar.gz`? (possible that if it was tar.gz, there are line-ending mismatches?)  
Did you check folder/flle permissions? Do you have anything Node.js related on your path?

---

<div class="post-metadata">

**Author:** ![stpruitt](https://avatars.discourse-cdn.com/v4/letter/s/df705f/32.png) [@stpruitt](https://discuss.elastic.co/u/stpruitt)\
**Post date:** [December 14, 2015, 4:54pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/7 "2015-12-14T16:54:03Z")

</div>

It was one time experiment to just see what would happen if I got past the bat file IF. It must be environmental.

So when things are environmental, the tough get going. :\>)

I restarted the entire process by downloading a new zip file. (I did have zip previously)

When I ran from the new download, it worked!

When will I learn? When errors make no sense, start over completely.

Thanks.

---

<div class="post-metadata">

**Author:** ![skearns](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/skearns/32/125945_2.png) [@skearns](https://discuss.elastic.co/u/skearns)\
**Post date:** [December 14, 2015, 6:10pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/8 "2015-12-14T18:10:28Z")

</div>

I'm glad to hear you're up and running! 😃

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 1:46pm UTC](https://discuss.elastic.co/t/marvel-installation-nodejs-error/37001/9 "2017-07-06T13:46:06Z")

</div>


