Instructions for installing and setting up VirtualBox with Ubuntu. A VirtualBox installation of Ubuntu is different from a standard bare metal and this guides explains how to handle those discrepencies. Instructions include methods to handle internet proxy if you are trying to connect your virtual machine to internet access.
-
Download the latest Ubuntu LTS ISO.
-
Download & Install VirtualBox.
Note: When asked about system resources set your virtual machine to use 50% of the host's RAM and CPU.
-
With VirtualBox you are not automatically added to the sudoer's group by default. To add yourself perform the following:
sudo su - # upgrade to root first sudo usermod -aG sudo <username> # add yourself to sudoers
-
Logout/login in order for the effects to register.
-
Open Settings -> Network in Ubuntu Apps and configure the proxy addresses
Set the Network Proxy to manual and enter in your proxy if you are using one. Otherwise ignore. -
Verify proxy settings work by opening a webpage.
- Add the following to
/etc/apt/apt.conf
:Acquire::http::Proxy "<proxy_address>";
- Verify that proxy settings work:
sudo apt update # can reach host if proxy works
-
Add the following to
/etc/wgetrc
:use_proxy=yes http_proxy=<proxy_address> https_proxy=<proxy_address>
-
Verify wget via:
wget github.com # will complain if it needs a proxy
Select Top Menu -> Devices -> Upgrade Guest Additions
- Guest Additions will greatly enhance your experience with Virtual Box because it provides user improvements that are not normally provided by the ISO image.
Select Top Menu -> Devices -> Shared Clipboard -> Bidirectional
-
Create a folder on your virtual machine in /mnt/shared:
mkdir /mnt/shared # this will be your mount point
-
Turn off virtual machine.
-
VirtualBox -> Settings -> Shared Folders
Set the Network Proxy to manual and enter in your proxy if you are using one. Otherwise ignore. Set a path on the host machine to a mount point inside the virtual machine.
Select VirtualBox -> Settings -> Display:
- For visualization tasks, enabling 3D acceleration can sometimes provide a performance boost.
- Maximizing the Video Memory can also provide improved performance.