请稍等 ...
×

采纳答案成功!

向帮助你的同学说点啥吧!感谢那些助人为乐的人

镜像下载错误

老师我安装问答区的新镜像报错如下:
C:\Users\32614>npm install -g cnpm --registry=https://registry.npmmirror.com
npm WARN notsup Unsupported engine for cnpm@9.4.0: wanted: {“node”:">= 14.18.0"} (current: {“node”:“12.18.3”,“npm”:“6.14.6”})
npm WARN notsup Not compatible with your version of node/npm: cnpm@9.4.0

npm ERR! code EPERM
npm ERR! syscall rename
npm ERR! path C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules.make-fetch-happen.DELETE\node_modules@npmcli
npm ERR! dest C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules@npmcli
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, rename ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules.make-fetch-happen.DELETE\node_modules@npmcli’ -> 'C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules@npmcli’
npm ERR! [OperationalError: EPERM: operation not permitted, rename ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules.make-fetch-happen.DELETE\node_modules@npmcli’ -> ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules@npmcli’] {
npm ERR! cause: [Error: EPERM: operation not permitted, rename ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules.make-fetch-happen.DELETE\node_modules@npmcli’ -> ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules@npmcli’] {
npm ERR! errno: -4048,
npm ERR! code: ‘EPERM’,
npm ERR! syscall: ‘rename’,
npm ERR! path: ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\.make-fetch-happen.DELETE\node_modules\@npmcli’,
npm ERR! dest: 'C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules\@npmcli’
npm ERR! },
npm ERR! errno: -4048,
npm ERR! code: ‘EPERM’,
npm ERR! syscall: ‘rename’,
npm ERR! path: ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\.make-fetch-happen.DELETE\node_modules\@npmcli’,
npm ERR! dest: ‘C:\Users\32614\AppData\Roaming\npm\node_modules\cnpm\node_modules\make-fetch-happen\node_modules\@npmcli’,
npm ERR! parent: 'cnpm’
npm ERR! }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It’s possible that the file was already in use (by a text editor or antivirus),
npm ERR! or that you lack permissions to access it.
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\32614\AppData\Roaming\npm-cache_logs\2025-04-10T08_11_11_375Z-debug.log

正在回答 回答被采纳积分+3

1回答

神思者 2025-04-11 10:12:47

可能是你的NodeJS版本太老了吧?

0 回复 有任何疑惑可以回复我~
  • 提问者 王得否9176967 #1
    我用的是老师给的版本,请问需要怎么更新呢
    回复 有任何疑惑可以回复我~ 2025-04-11 10:15:08
  • 提问者 王得否9176967 #2
    请问老师需要装最新版本的Nodejs吗
    回复 有任何疑惑可以回复我~ 2025-04-11 10:22:27
  • 神思者 回复 提问者 王得否9176967 #3
    卸载NodeJS,然后重启电脑,下载最新版本安装试一下
    回复 有任何疑惑可以回复我~ 2025-04-11 11:38:14
问题已解决,确定采纳
还有疑问,暂不采纳
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号