Mac OS X 11中的/usr/bin 的“Operation not permitted”
来源:互联网 发布:超星尔雅网络课程挂机 编辑:程序博客网 时间:2024/05/16 18:15
更新了 Mac OS X 11后发现,MacVim
不再能够通过Terminal用命令打开了。
mvim hello.txt
于是尝试将 mvim 重新复制到/usr/bin/中去
sudo cp -f mvim /usr/bin/
然而出现了权限问题:
cp: /usr/bin/mvim: Operation not permitted
搜索之后发现,是El Capitan
加入了Rootless机制
,不再能够随心所欲的读写很多路径下了。设置 root 权限也不行。
Rootless机制将成为对抗恶意程序的最后防线
于是尝试关闭 Rootless。重启按住 Command+R,进入恢复模式,打开Terminal。
csrutil disable
重启即可。如果要恢复默认,那么
csrutil enable
附录:
csrutil命令参数格式:
csrutil enable [--without kext | fs | debug | dtrace | nvram][--no-internal]
禁用:csrutil disable
(等同于csrutil enable --without kext --without fs --without debug --without dtrace --without nvram)
其中各个开关,意义如下:
- B0: [kext] 允许加载不受信任的kext(与已被废除的kext-dev-mode=1等效)
- B1: [fs] 解锁文件系统限制
- B2: [debug] 允许task_for_pid()调用
- B3: [n/a] 允许内核调试 (官方的csrutil工具无法设置此位)
- B4: [internal] Apple内部保留位(csrutil默认会设置此位,实际不会起作用。设置与否均可)
- B5: [dtrace] 解锁dtrace限制
- B6: [nvram] 解锁NVRAM限制
- B7: [n/a] 允许设备配置(新增,具体作用暂时未确定
0 0
- Mac OS X 11中的/usr/bin 的“Operation not permitted”
- Mac OS X 11中的/usr/bin 的“Operation not permitted”
- Mac OS X 11中的/usr/bin 的“Operation not permitted”
- Mac OS X 11中的/usr/bin 的“Operation not permitted”
- Mac OS X 11中的/usr/ 的“Operation not permitted”
- MAC /usr/bin/目录下 Operation not permitted的解决
- 解决CocoaPods在OS X 10.11出现问题While executing gem ... (Errno::EPERM) Operation not permitted - /usr/bin/
- cocoapods 安装更新 Operation not permitted - /usr/bin/xcodeproj Operation not permitted - /usr/bin/upda
- Mac OS X运行程序出现bad interpreter: operation not permitted的解决方案
- Mac OS X运行程序出现bad interpreter: operation not permitted的解决方案
- Mac OS X 11 以后版本出现"Operation not permitted"错误
- Mac升级到 OSX 10.11 El Capitan 后 Operation not permitted - /usr/bin/sass
- mysql在mac安装有ln: /usr/bin/mysql: Operation not permitted问题
- 关于Mac OS下的pip:Operation not permitted问题
- pod安装失败,Operation not permitted - /usr/bin/pod
- pod 报错 Operation not permitted - /usr/bin/pod
- pod安装失败,Operation not permitted - /usr/bin/pod
- osx gem install Operation not permitted - /usr/bin/xxx
- 远程桌面可以远程,ping 不通
- IOS中SVN-CornerStone上传静态库(.a文件)
- 第三章 进程控制 3.1.4 fork、文件和数据
- HDU 2141 Can you find it?
- js之跑马灯
- Mac OS X 11中的/usr/bin 的“Operation not permitted”
- Vs2015+Qt5.8中uic,moc错误解决办法
- 33.启动流程,模块管理与 Loader
- weblogic fmw_12.2.1.0.0_wls下载及安装教程
- 静态类
- POJ 2828 Buy Tickets 线段树 倒序插入 节点空位预留(思路巧妙)
- maven 常用插件小结
- 优化MySql中explain的时候出现using filesort
- 多线程、设计模式_总结