Difference between revisions of "VirtualBox/en"

Updating to match new version of source page
(Updating to match new version of source page)
 
(Updating to match new version of source page)
Line 1: Line 1:
<languages/>
<languages/>
__TOC__
__TOC__
==Overview==
==Overview==  
 
[[file:vbox.png|left]]
[[file:vbox.png|left]]
Developed by Sun Microsystems, now Oracle Corporation, '''[https://www.virtualbox.org/ VirtualBox]''' is a popular application that allows for other operating systems (known as ''Guests'') to be installed and run within an existing operating system (known as the ''Host''). This is undertaken through the process of ''virtualisation'', whereby virtual versions of your computer (also referred to as ''virtual machines'' or ''VMs'') are created within and draw resources directly from the host system. As such, how fast or powerful a virtual machine may be will depend entirely on the resources available - and allocated - for it to use. The benefits of virtualisation include:
Developed by Sun Microsystems, now Oracle Corporation, '''[https://www.virtualbox.org/ VirtualBox]''' is a popular application that allows for other operating systems (known as ''Guests'') to be installed and run within an existing operating system (known as the ''Host''). This is undertaken through the process of ''virtualisation'', whereby virtual versions of your computer (also referred to as ''virtual machines'' or ''VMs'') are created within and draw resources directly from the host system. As such, how fast or powerful a virtual machine may be will depend entirely on the resources available - and allocated - for it to use. The benefits of virtualisation include:
Line 14: Line 15:


===Install VirtualBox===
===Install VirtualBox===
'''Make sure your system is using a supported kernel'''
{{UserCmd|command=mhwd-kernel -l}}
To install VirtualBox, you need to install the packages {{ic|virtualbox}} and {{ic|linux*-virtualbox-host-modules}}.  The latter must match the version of the kernel you are running. To list what kernels is installed use mhwd (example)
To install VirtualBox, you need to install the packages {{ic|virtualbox}} and {{ic|linux*-virtualbox-host-modules}}.  The latter must match the version of the kernel you are running. To list what kernels is installed use mhwd (example)
$ mhwd-kernel -li
{{UserCmdOutput|command=mhwd-kernel -li|result=
Currently running: 5.4.0-1-MANJARO (linux54)
<pre>
The following kernels are installed in your system:
Currently running: 6.6.17-1-MANJARO (linux66)
    * linux54
The following kernels are installed in your system:
  * linux66
</pre>}}


To install VirtualBox and the kernel modules for your installed kernel enter the following command in the terminal:
To install VirtualBox and the kernel modules for your installed kernel enter the following command in the terminal - continuing the above example:
$ sudo pacman -Syu virtualbox linux54-virtualbox-host-modules
{{UserCmd|command=sudo pacman -Syu virtualbox linux66-virtualbox-host-modules}}


Once the installation has completed, it will then be necessary to add the ''VirtualBox Module'' to your kernel. '''The easy way is to simply reboot your system'''. Otherwise, to start using VirtualBox immediately, enter the following command:
Once the installation has completed, it will then be necessary to add the ''VirtualBox Module'' to your kernel. '''The easy way is to simply reboot your system'''. Otherwise, to start using VirtualBox immediately, enter the following command:
$ sudo vboxreload
{{UserCmd|command=sudo vbox-reload}}


===Install the Extension Pack(Optional)===
===Install the Extension Pack(Optional)===
The extension pack is a proprietary set of extensions providing extra functionality to VirtualBox like USB2 and USB3 passthrough. You only need this if you are going to use the functionality provided and it is '''not required''' for VirtualBox to function.
The extension pack is a proprietary set of extensions providing extra functionality to VirtualBox like USB2 and USB3 passthrough. You only need this if you are going to use the functionality provided and it is '''not required''' for VirtualBox to function.
* Oracle Cloud Infrastructure integration
* Oracle Cloud Infrastructure integration
Line 39: Line 46:
'''Please install the same version extension pack as your installed version of VirtualBox.''' – [https://www.virtualbox.org/wiki/Downloads VirtualBox Download page]}}
'''Please install the same version extension pack as your installed version of VirtualBox.''' – [https://www.virtualbox.org/wiki/Downloads VirtualBox Download page]}}
Check your VirtualBox version (example)
Check your VirtualBox version (example)
$ vboxmanage --version
{{UserCmdOutput|command=vboxmanage --version|result=<pre>7.0.14r161095</pre>}}
6.1.14r140239


====Install extensionpack using AUR====
====Install extensionpack using AUR====
Locate the correct AUR PKGBUILD using pamac (or the AUR helper of choice) - example is using '''pamac'''
Locate the correct AUR PKGBUILD using pamac (or the AUR helper of choice) - example is using '''pamac'''
{{Important|AUR PKGBUILDs labelled manjaro is '''not''' maintained by Manjaro!}}
{{Important|AUR PKGBUILDs labelled manjaro is '''not''' maintained by Manjaro!}}
$ pamac search virtualbox-ext-oracle
{{UserCmdOutput|command=pamac search --aur virtualbox-ext-oracle|result=
virtualbox-ext-oracle-manjaro        6.1.12-2        AUR  
<pre>
    Oracle VM VirtualBox Extension
virtualbox6-ext-oracle 6.1.x-5                              AUR
    Pack
    Oracle VM VirtualBox Extension Pack 6.1.48 (stable)
virtualbox-ext-oracle-beta            6.1.0_RC1-1      AUR
virtualbox6.1-ext-oracle 6.1.50-1                           AUR
    Oracle VM VirtualBox Extension
    Oracle VM VirtualBox Extension Pack (version 6.1)
    Pack (Beta)
virtualbox-ext-oracle-dev  7.0.97.161344-1                   AUR
virtualbox-ext-oracle-5-test-build    5.2.35_135314-1 AUR  
    Oracle VM VirtualBox Extension Pack for virtualbox dev
    Oracle VM VirtualBox Extension
    version
    Pack Test Build 5.2.35_135314
virtualbox-ext-oracle 7.0.14-1                               AUR
virtualbox-ext-oracle-5.0             5.0.40-1         AUR  
    Oracle VM VirtualBox Extension Pack
    Oracle VM VirtualBox Extension
</pre>}}
    Pack
virtualbox-ext-oracle-5              5.2.x-1          AUR
    Oracle VM VirtualBox Extension
    Pack 5.2.x (stable)
virtualbox-ext-oracle                 6.1.14-1         AUR  
    Oracle VM VirtualBox Extension
    Pack


When you have found the match you can install using the helper - example is using pamac
When you have found the match you can install using the helper - example is using pamac
$ pamac build virtualbox-ext-<your-decision>
{{UserCmd|command=pamac build virtualbox-ext-<nowiki><your-decision></nowiki>}}


====Get extensionpack from VirtualBox====
====Get extensionpack from VirtualBox====
Line 79: Line 79:
The extension '''.vbox-extpack''' is a registered mime extension so just open the file and VirtualBox will install the extension pack. Provide your password when asked.
The extension '''.vbox-extpack''' is a registered mime extension so just open the file and VirtualBox will install the extension pack. Provide your password when asked.


==Configuring the host==
== Configuring the host ==
=== Adding Your Account to the '''vboxusers''' User Group ===
=== Adding Your Account to the '''vboxusers''' User Group ===
The final step is to now add your personal user account to the {{ic|vboxusers}} group. This is necessary in order to fully access the features provided by VirtualBox. The '''$USER''' variable translates to the currently logged in user and you must logout or restart for the change to take effect.
The final step is to now add your personal user account to the {{ic|vboxusers}} group. This is necessary in order to fully access the features provided by VirtualBox. The '''$USER''' variable translates to the currently logged in user and you must logout or restart for the change to take effect.
$ sudo gpasswd -a $USER vboxusers
{{UserCmd|command=sudo gpasswd -a $USER vboxusers}}


==Manjaro VBox guest==
==Manjaro VBox guest==
Line 90: Line 90:
Before installation of Manjaro ensure the correct display settings for VM. The Manjaro recommendation - to ensure the best experience - is contradicting the recommendations from VirtualBox developers. To have the VM screensize adapting to the window size - you need enable VBoxSVGA but doing so you cannot enable 3D. To use 3D you need to use VMSVGA which will force you to set the VM screen size inside the VM. If you use the VMSVGA adapter - mhwd will keep telling you to switch - you can do it but you will not be able to utilize 3D graphics.
Before installation of Manjaro ensure the correct display settings for VM. The Manjaro recommendation - to ensure the best experience - is contradicting the recommendations from VirtualBox developers. To have the VM screensize adapting to the window size - you need enable VBoxSVGA but doing so you cannot enable 3D. To use 3D you need to use VMSVGA which will force you to set the VM screen size inside the VM. If you use the VMSVGA adapter - mhwd will keep telling you to switch - you can do it but you will not be able to utilize 3D graphics.


===Troubleshooting guest===
===Troubleshooting Manjaro guest===
If you deem it necessary to ensure the packages are installed please follow this recipe
If you deem it necessary to ensure the packages are installed please follow this recipe
$ mhwd-kernel -li                                                          
{{UserCmdOutput|command=mhwd-kernel -li|result=
  Currently running: 5.4.0-1-MANJARO (linux54)
<pre>
  Currently running: 6.6.17-1-MANJARO (linux66)
  The following kernels are installed in your system:
  The following kernels are installed in your system:
     * linux54
     * linux66
  $ sudo pacman -Syu virtualbox-guest-utils linux54-virtualbox-guest-modules
  </pre>}}
{{UserCmd|command=sudo pacman -Syu virtualbox-guest-utils}}


===Guest Configuration===
===Guest Configuration===
You will need to load the modules if you don't want to reboot:
You will need to load the modules if you don't want to reboot:
$ sudo modprobe vboxguest vboxvideo vboxsf
{{UserCmd|command=sudo modprobe vboxguest vboxvideo vboxsf}}


The guest utils than need to be started and enabled:
The guest utils than need to be started and enabled:
$ sudo systemctl enable --now vboxservice.service
{{UserCmd|command=sudo systemctl enable --now vboxservice.service}}


Add you VM user to the vboxsf group (this requires you to logout to apply the new group)
Add you VM user to the vboxsf group (this requires you to logout to apply the new group)
$ sudo usermod -aG vboxsf ${USER}
{{UserCmd|command=sudo usermod -aG vboxsf <nowiki>${USER}</nowiki>}}


Create media folder in root directory if it does not already exist
Create media folder in root directory if it does not already exist
$ sudo mkdir /media
{{UserCmd|command=sudo mkdir /media}}


Assign the correct permissions to the media folder to be able to access shared folders
Assign the correct permissions to the media folder to be able to access shared folders
$ sudo chmod 755 /media
{{UserCmd|command=sudo chmod 755 /media}}


==Advise, Tips, and Tricks==
==Advise, Tips, and Tricks==
8,560

edits