Node.js- “npm install express” error:0906D06C :PEM

2019-07-07 19:23发布

问题:

I have installed node.js and it has npm installed along with it. In my windows command prompt,when i write "npm install express", it gives me the following error.How to resolve this?

C:\Users>npm -v

2.11.2

C:\Users>npm install express

npm ERR! Windows_NT 6.1.7601

npm ERR! argv "C:\Program Files\nodejs\\node.exe" "C:\Program Files\nodejs \node_modules\npm\bin\npm-cli.js" "install" "express"

npm ERR! node v0.12.5

npm ERR! npm v2.11.2

npm ERR! error:0906D06C:PEM routines:PEM_read_bio:no start line

npm ERR!

npm ERR! If you need help, you may report this error at: npm ERR!
https://github.com/npm/npm/issues

npm ERR! Please include the following file with any support request: npm ERR! C:\Users\npm-debug.log

回答1:

I also got same problem after setting registry problem got resolved.

cmd>> npm set registry registry.npmjs.org 
cmd>> npm install 

it worked for me.