"npm ERR! Error: EPERM: operation not permitted"问题解决
npm ERR! Error: EPERM: operation not permitted
其实就是权限问题,猜测使用管理员权限应该OK,试了一下,确实如此;
解决办法:
1.最简单的方法如下:
windows + X 组合键就可以打开下图
选择要管理员运行的请选框起来的第二个也可以按windows+x+a
2.或者,使用搜索cmd,打开之后,选择"使用管理员权限运行CMD";
但问题是,这种方式需要每次都这样打开,我希望默认能够就是管理员方式运行。其实也有一劳永逸的方法,如下;
3.修改注册表(自测没有找到layers);
Win+R --输入 regedit,打开注册表,找到以下位置:
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers
,新建一个字符串值,命名为"c:\windows\system32\cmd.exe",一般情况下,cmd.exe都安装在C盘
然后右键--修改 -- 数值数据写入“RUNASADMIN”,确定 !
或者,也可以采用注册表导入的方式操作,如下:
直接复制下面内容(系统安装在C盘32位为准):
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers] "c:\\windows\\system32\\cmd.exe"="RUNASADMIN"
打开记事本,复制粘贴入以上代码,另存为hao.reg,然后双击导入注册表即可。
OK,这下我们Win+R输入cmd,启动时就已经默认是管理员身份了。
4.修改文件目录所有者:
进入nodejs的安装目录 (默认是 C:\Program Files\nodejs),或者C:\Program Files;
在nodejs上右键打开属性;
选择安全-->高级,这时候会看到所有这是SYSTEM,选择"修改";
输入你目前的账户名称,并检查OK之后,OK保存;
再次打开验证;
阅读更多- "npm ERR! Error: EPERM: operation not permitted"问题解决
- npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法
- npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法
- npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法
- npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法
- npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法
- npm ERR! Error: EPERM: operation not permitted, scandir 'D:\
- ReactNative下载第三方库出错解决Error: EPERM: operation not permitted, rename
- 解决 mac安装或者更新第三方包安装不上的问题 mac OSX pip OSError: [Errno 1] Operation not permitted
- MAC下解决pip安装权限问题 OSError: [Errno 13] Permission denied OSError: [Errno 1] Operation not permitted:
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法
- 解决 mac OSX pip OSError: [Errno 1] Operation not permitted
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法
- redis安装后提示权限问题ERR operation not permitted
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法
- 解决linux下chrome NVIDIA: could not open the device file /dev/nvidia0 Operation not permitted 问题
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法
- ASM 实例 ORA-15063 ORA-15186 ASMLIB error function = [asm_open], error = [1], mesg = [Operation not permitted] 解决方法