首页 > 运维 > 苹果系统 > 正文

MacOS安装VirtualBox的问题小结

藏色散人
发布: 2021-12-31 15:07:56
转载
3500 人浏览过

本文由macos教程栏目为大家介绍MacOS brew cask安装VirtualBox遇到的问题,希望能够帮助到有需要的小伙伴。

MacOS brew cask安装VirtualBox遇到的问题

问题一:Cask ‘virtualbox’ is already installed.

如果不是通过Homebrew安装的virtualbox,在使用brew cask install virtualbox安装virtualbox的的时候,会提示:

Warning: Cask 'virtualbox' is already installed.
登录后复制

那么就需要重新安装virtualbox,命令:

brew cask reinstall virtualbox
登录后复制
登录后复制

如果还不巧,你的virtualbox刚好在运行中,又会提示:

Failed to unload org.virtualbox.kext.VBoxDrv - (libkern/kext) kext is in use or retained (cannot unload).
登录后复制

那么,就需要网上拉日志,找到:

Warning! Found the following active VirtualBox processes:
登录后复制

这些是运行中的虚拟主机列表,其中第一列是它们的 ID,用kill命令关闭服务,如:

kill 234
登录后复制

然后再重新安装:

brew cask reinstall virtualbox
登录后复制
登录后复制

问题二:Error: Failure while executing;

安装virtualbox的最后一步会要求输入电脑的登陆密码,不过在你输入密码后,可能还是会提示错误,这是因为权限的问题,主要信息如下:

~ brew cask reinstall virtualbox
 ==> Caveats
 To install and/or use virtualbox you may need to enable its kernel extension in:
   System Preferences → Security & Privacy → General
...
 ==> Running installer for virtualbox; your password may be necessary.
 ==> Package installers may write to any location; options such as --appdir are ignored.
 installer: Package name is Oracle VM VirtualBox
 installer: Installing at base path /
 installer: The install failed (The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.)
 ==> Purging files for version 6.0.10,132072 of Cask virtualbox
 Error: Failure while executing; `/usr/bin/sudo -E -- env LOGNAME=gary USER=gary USERNAME=gary /usr/sbin/installer -pkg /usr/local/Caskroom/virtualbox/6.0.10,132072/VirtualBox.pkg -target /` exited with 1. Here's the output:
 installer: Package name is Oracle VM VirtualBox
 installer: Installing at base path /
 installer: The install failed (The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.)
 Follow the instructions here:
   https://github.com/Homebrew/homebrew-cask#reporting-bugs
 /usr/local/Homebrew/Library/Homebrew/system_command.rb:111:in `assert_success'
...
登录后复制

以上是MacOS安装VirtualBox的问题小结的详细内容。更多信息请关注PHP中文网其他相关文章!

相关标签:
来源:awaimai.com
本站声明
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责声明 Sitemap
PHP中文网:公益在线PHP培训,帮助PHP学习者快速成长!