在Ubuntu中啟動VirtualBox的步驟如下:
sudo apt update
sudo apt install virtualbox
virtualbox
/etc/default/
目錄下新建 virtualbox
文件,并添加以下內容:# VBOXAUTOSTART_DB=/etc/vbox
# VBOXAUTOSTART_CONFIG=/etc/vbox/autostart.conf
vbox
目錄的權限,將當前用戶添加到 vboxusers
用戶組:sudo chgrp vboxusers /etc/vbox
sudo chmod 1775 /etc/vbox
sudo usermod -aG vboxusers $USER
autostart.conf
并添加以下內容:# Default policy is to deny starting a VM, the other option is "allow".
# default_policy deny
# user vbox is allowed to start virtual machines but starting them
# will be delayed for 10 seconds
# Example: Allow user vbox to start a VM named "XP" with a startup delay of 10 seconds.
# Example: Allow user vbox to start a VM named "XP" without a startup delay.
# Example: Deny starting any VMs.
# Example: Allow user vbox to start a VM named "XP" with a startup delay of 10 seconds.
allow
startup_delay 10
# Example: Allow user vbox to start a VM named "XP" without a startup delay.
# allow
# startup_delay 0
VBoxManage setproperty autostartdbpath /etc/vbox
VBoxManage modifyvm win2003 --autostart-enabled on
完成以上步驟后,您就可以在Ubuntu中啟動并使用VirtualBox了。如果遇到任何問題,可以參考VirtualBox的官方文檔或搜索相關教程。