Node.js 应用程序中出现“EACCES”错误

Muj*_*hid 4 powershell node.js npm npm-install

今天我通过卸载旧版本来更新节点版本。我最近安装的版本是 4.5.0 LTS。安装后,当我尝试安装新的 npm 时,它不起作用并给出以下错误

\n
C:\\Users\\myuser\n\xce\xbb npm install -g yo\nnpm ERR! Windows_NT 10.0.10240\nnpm ERR! argv "C:\\\\Program Files\\\\nodejs\\\\\\\\node.exe" "C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\bin\\\\npm-cli.js" "install" "-g" "yo"\nnpm ERR! node v0.12.15\nnpm ERR! npm  v2.15.1\nnpm ERR! code EACCES\nnpm ERR! errno EACCES\nnpm ERR! syscall connect\n\nnpm ERR! Error: connect EACCES\nnpm ERR!     at exports._errnoException (util.js:746:11)\nnpm ERR!     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1012:19)\nnpm ERR!  { [Error: connect EACCES] code: 'EACCES', errno: 'EACCES', syscall: 'connect' }\nnpm ERR!\nnpm ERR! Please try running this command again as root/Administrator.\n\nnpm ERR! Please include the following file with any support request:\nnpm ERR!     C:\\Users\\myuser\\npm-debug.log\n
Run Code Online (Sandbox Code Playgroud)\n

我已经在 Powershell 中使用具有管理员权限的命令行进行了尝试。还尝试安装其他几个插件。什么都不起作用。还关闭了防火墙并尝试过,没有运气。安装了旧版本的 NodeJS,问题仍然存在。

\n

我使用的是 Windows 10。我检查了我是否在代理后面,但没有。

\n

Muj*_*hid 5

我找到了我的问题的解决方案。

问题是我的病毒防护程序 Kespersky Endpoint Security 10 阻止了我机器中的节点。

当我将其添加到白名单时,它运行得很好。

谢谢