【问题标题】:OSX 10.11 El Capitan - setting boot device property not workingOSX 10.11 El Capitan - 设置引导设备属性不起作用
【发布时间】:2016-01-01 04:28:29
【问题描述】:

我正在使用双启动系统并使用以下applescript来设置启动音量:

    tell application "Finder" to if not (disk "SoundHD" exists) then do shell script "diskutil mount " & last word of (do shell script "diskutil list | grep 'Apple_HFS SoundHD'")

do shell script "bless -mount \"/Volumes/SoundHD\" -setBoot --nextonly" with administrator privileges

display notification "Next Boot: SoundHD" with title "Neustart"

由于 El Capitan 脚本不再起作用,我在脚本编辑器中收到以下错误消息:

tell application "Finder"
   exists disk "SoundHD"
            --> true
    end tell
    tell current application
        do shell script "bless -mount \"/Volumes/SoundHD\" -setBoot --nextonly" with administrator privileges
            --> error "Could not set boot device property: 0xe00002bc" number 3
    Ergebnis:
    error "Could not set boot device property: 0xe00002bc" number 3

bless 命令有什么新变化吗?

感谢您的帮助。

【问题讨论】:

  • 我会责怪系统完整性保护,但我不确定

标签: macos terminal applescript bless


【解决方案1】:

您必须首先禁用系统完整性保护。

  1. 重新启动计算机,然后在启动时按住 Command-R 启动进入 恢复模式。
  2. 启动后,导航至顶部菜单栏中的“实用程序 > 终端”。
  3. 在终端窗口中输入csrutil disable,然后按回车键。
  4. 重新启动机器,系统完整性保护现在将被禁用。

来源:http://mattjanik.ca/blog/2015/10/01/refind-on-el-capitan/

【讨论】:

  • 我们能否了解一下为什么必须这样做以及它是否是永久解决方案以及关闭 SIP 有什么问题?
  • 不要为此禁用 SIP。 SIP 有一个重要原因:它可以防止恶意软件和流氓进程修改核心操作系统。
  • @Karew:我不相信有其他解决方案。如果您知道其他情况,请不要退缩。
  • 遗憾的是,这无论如何都不起作用。即使禁用 SIP bless --verbose 打印 NVRAM variable "boot-args" not set. 并且它只是重新启动到 OSX。
  • 显然,macOS 现在会在更新后重新激活 CSR。伟大的。我对这家公司的厌恶与日俱增。
猜你喜欢
  • 2016-03-03
  • 1970-01-01
  • 2017-01-12
  • 2016-08-08
  • 2016-02-02
  • 2015-08-26
  • 1970-01-01
  • 2016-06-24
  • 2015-09-22
相关资源
最近更新 更多