Cannot find module 'babel-register'


I'm trying to install Kibana 6.3.0 on a Windows Server 2012 R2 VM. I've successfully had it working on my Windows 7 laptop but the same (easy) steps get the following error when I run kibana.bat:

PS D:\elk\kibana-6.3.0-windows-x86_64\bin> .\kibana.bat
    throw err;

Error: Cannot find module 'babel-register'
    at Function.Module._resolveFilename (module.js:547:15)
    at Function.Module._load (module.js:474:25)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (D:\elk\kibana-6.3.0-windows-x86_64\src\babel-register\register.js:39:1)
    at Module._compile (module.js:652:30)
    at Object.Module._extensions..js (module.js:663:10)
    at Module.load (module.js:565:32)
    at tryModuleLoad (module.js:505:12)
    at Function.Module._load (module.js:497:3)

This is within a Powershell window, with admin privileges.

Any ideas gratefully received, thanks.


Hi @goochjs,

What version of node do you have installed? You can double check by running:

node -v

Hi Chris,

Thanks for the reply. I don't have any version of node specifically installed, unless it came inside the Kibana zip file. The same goes for my laptop's instance of Kibana.

Running "node -v" just tells me that Windows doesn't know what node is.


Hi there,

Is there an optimize directory next to the bin folder? If there is, you could try and delete it and see if Kibana will start then.
If that doesn't work we can check and see if there may be some corrupt files/downloads or some permissions issue. Let's try the first one and come back to this if it doesn't work.

Hi Marius,

There's no optimize directory, I'm afraid.

I've also looked for node, and it is there within the kibana directory. Here's the output from running node -v.

PS D:\elk\kibana-6.3.0-windows-x86_64\node> .\node.exe -v

I've also looked inside the node_modules folder and there are several babel modules but not babel-register. There is, however, a folder called babel-register under the src folder. This contains:-

  • index.js
  • polyfill.js
  • register.js


Ok, this is weird. To me it sounds like a corrupted download/unzip. Can you check the size of your Kibana folder?
For me it's 438MB with the default Kibana package.
The babel-register folder is in the node-modules for me and I also have one under src(that one is fine how you have it).

Aha - it's much smaller (sorry, should have checked) - only 165MB, whereas it's 455MB on my laptop. I've deleted the server install and am re-extracting. Once done, I'll make sure it's of comparable size to my laptop version. It'll take a little while, though. I'll provide an update once done.

Hi Marius,

Thanks - you nailed it. It was a corrupt unzip or similar. All replaced and all good now.


1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.