How to use VirtualBox

Preliminary information

How to use VirtualBox

Before taking action and seeing the concrete how VirtualBox works, I believe it is right to make clear some concepts that may be useful to you in the course of this guide.

First of all, as already mentioned, one virtual machine it is nothing more than a computer "virtualized" through a specific program (as for the VirtualBox) inside a physical device: this system allows you to use multiple operating systems at the same time and to limit the changes applied only in the virtual machine. In other words, any changes made to the virtual machine cannot affect the physical machine in any way.



The components of the virtual machine (hard disk, CPU, RAM memory and so on) are actually simple files, created and destroyed as needed by the program that manages it. It is possible to configure each virtual machine according to your needs, configuring in detail both the hardware and the software aspect: in other words, it is possible to configure a virtual machine to use a given number of virtual CPUs, a specific amount of virtual RAM ( generally less than half of that available on the physical computer), a virtual disk of a specific size and, in general, you can make it use the input / output devices present on the physical (for example the CD player, the USB ports and so on).

As I mentioned earlier, you can choose the operating system to install on a virtual machine and run it inside the one you already have: the operating system installed on the physical computer, in this case, is called host operating system, while the one installed on the virtual machine is called guest operating system.

How to install VirtualBox

How to use VirtualBox


Now that you know what virtual machines are, it's finally time to get down to business and start with the actual installation and VirtualBox. As I mentioned earlier, VirtualBox is a free and open source program available for Windows, macOS and Linux, freely downloadable from the Internet.


So, to get started, go to the Virtualbox website and click on the link that best suits your operating system (eg. Windows hosts), placed immediately under the heading VirtualBox xyz platform packages. Once this is done, start the file you just downloaded: if you are on Windows, presses the button four times NEXT, then on the buttons Yes Install.

At this point, click on the button Yes placed in the Windows warning window, wait a few minutes for the procedure to be completed and press the button end to start the program immediately.

How to use VirtualBox

If you have the operating system instead MacOS, after starting the downloaded setup file, double click on the icon VirtualBox.pkg (shaped like a full box open), then press the button twice Continue, by pressing the button Install, enter the administrative password when prompted, press the key Submit on the keyboard, then presses the buttons OK, Close Don't move.

At this point, open the System settings clicking on the gear icon located in the Dock, click on the icon Security and Privacy, by pressing the button Allow in correspondence with the wording System software was blocked from loading by developer "Oracle America, Inc.": once this is done, you can start the program directly from the folder Applications of the Mac, from Launchpad or from Spotlight.


How to use VirtualBox

Once the program installation operation is finalized, I recommend that you install the VirtualBox Extension Pack to add interesting features to the manager, such as support for USB 2.0 and USB 3.0 devices and disk encryption: to do this, go once again to the program download page, click on the link All supported platform placed immediately under the heading VirtualBox xyz Oracle VM VirtualBox Extension Pack, start the file you just downloaded, then press the button Install and follow the on-screen instructions to complete the procedure.


How to use VirtualBox

Now that you have installed the program on your computer, it is finally time to create a virtual machine to start your experiments right away: from now on, I will refer to VirtualBox running on a Windows operating system, however the steps shown are virtually identical on macOS and Linux as well.

Create a virtual machine

How to use VirtualBox

The first step is to "build" a virtual computer that can host the guest operating system you want: to start the creation process, press the button New located at the top left, type the Your name that you want to assign to your virtual machine (e.g. Ubuntu 17.10) in the appropriate box, then select the Type (With art. Linux) and the Version (With art. Ubuntu 64 bit) of the operating system you intend to install from the appropriate drop-down menus and click on the button Following.

The next screen allows you to choose the amount of memory RAM to assign to the virtual machine: always keeping in mind the minimum requirements of the operating system you intend to install, move theindicator to the right or to the left, until the desired amount of RAM is reached (if you wish, you can type the exact size in the text box attached to the window).


How to use VirtualBox

I advise you not to allocate too much RAM to your virtual machine, as this could result in a complete freeze of the real computer: in general, you should not allocate more than 60% of the physical RAM at your disposal, as indicated in the colored bar displayed on the screen (the green part is the one that can be assigned without risk of repercussions). Once the desired amount of RAM has been defined, press the button Following.


The next screen allows you to add a new virtual hard disk to your machine: put the check mark next to the item Create a new virtual hard drive now e pulsing sul pulsating Crea to immediately access the creation screen.

How to use VirtualBox

Put the check mark next to the item VDI, pigia sul pulsating Following, check the box next to the item Dynamically allocated and click to lock your button Following, define the size of your virtual disk using the dedicated cursor (or type its size in the box next to it), press the button Crea to add the disk and immediately create the virtual machine and that's it: you are finally ready to proceed with the installation of a new guest operating system!

Install an operating system

How to use VirtualBox

After creating a new virtual machine, it's finally time to animate it with an operating system. The installation of a guest operating system is not difficult, on the contrary: the procedure is practically identical to the one you would use with a real computer!

The only difference, in this sense, concerns the installation media: as regards the virtual machine, in fact, you do not need to create DVDs or USB sticks containing the material to be installed, but you can simply use the most appropriate ISO file.

So, before you even proceed, the first thing you need to do is to get theISO image related to the operating system you have chosen to install: if you intend to download the file related to Windows 10, for example, you can take advantage of the official Microsoft tool I told you about in my specific tutorial, always remembering to have a valid Product Key at hand to enter when requested.

If you intend to install Ubuntu instead, I urge you to consult the section instead How to download Linux present in my operating system installation guide; if you don't intend to install Ubuntu, and are instead looking for a Linux distribution to try, I invite you to check out my guide to the best Linux distributions.

Once you have downloaded the most suitable ISO for the operating system you intend to install on your computer, access the main VirtualBox screen, select the previously created virtual machine with a click of the mouse and press the button starts (the green arrow pointing to the right) located at the top: after a few seconds, you will be shown the window that allows you to load the installation ISO of the guest operating system into the virtual machine.

How to use VirtualBox

Once in the aforementioned screen, click on the icon in the shape of gialla poster next to the drop-down menu and, using the appropriate panel, select the ISO image of the operating system downloaded previously, press the button apri and then on the button starts: after a few seconds, the virtual machine will start the installation process of the chosen operating system.

As I have already explained to you previously, all you have to do is proceed by following the instructions shown on the screen, which are absolutely identical to those you would see during a "real" installation of the operating system: if you need more specific help on Windows or Ubuntu installations, you can refer to my guides on how to install Windows 7, how to install Windows 10 and how to install Ubuntu.

During the installation of the guest operating system, and for the entire session of use of the virtual machine, the mouse may be "trapped" in the VirtualBox screen, preventing you from using the host operating system installed on your computer: to exit this situation and release the mouse, simply press the Host key of VirtualBox, which by default is the button Right CTRL of the keyboard.

How to use VirtualBox

Once the setup procedure is complete, you can use your virtual operating system exactly as you would on a "physical" computer: each virtual machine can be started by pressing the button starts in the main VirtualBox screen, and must be turned off using the procedure provided by the operating system (eg. Start> Stop button> Shut down system for Windows). If you wish, you can expand your virtual machine to full screen by pressing the key combination Host + F.

Install the Guest Additions

How to use VirtualBox

The next step after installing the guest operating system on a new virtual machine involves the Guest Additions: in short, these are some add-ons provided by VirtualBox capable of implementing additional features in the active virtual machine, such as 3D acceleration (essential for the correct graphical rendering of some interfaces), bidirectional sharing of notes and folders on the host system.

Installing the Guest Additions is really simple: first, start the virtual machine on which you intend to install them and wait for the operating system to be completely loaded (in other words, wait for the desktop to appear), then press the menu devices and select the item Insert the Guest Additions CD image ... give the menu visualizzato.

After a few seconds, the guest operating system will detect the insertion of a new CD ROM: if necessary, confirm that you want to run its contents and follow the instructions on the virtual machine screen to complete the installation. Once the setup is complete, I recommend that you restart the guest OS for the changes to take effect.

If you have activated the full screen view, you can call up the VirtualBox menu bar by positioning the mouse in the lower central border of the displayed screen.

Note: virtualization of operating systems macOS / OS X it is not officially supported by VirtualBox, as these OSs are designed to run only on Apple-branded hardware. For this reason, Guest Additions are not available for such guest systems.

Manage virtual machine settings

How to use VirtualBox

Did you realize that you have not allocated enough RAM to your virtual machine, do you want to give it a new name, or have you installed the Guest Additions and want to activate graphics acceleration? You can do all of this using VirtualBox's handy settings manager.

First of all, if necessary, turn off the virtual machine on which you intend to intervene, then select it with a mouse click from the left panel of the main program screen and press the button Settings located at the top: the next screen is divided into sections, each of which allows you to intervene on a different aspect of the virtual machine, as I am going to explain below.

  • General - allows you to change the name and type of the virtual machine, the version of the operating system to be hosted and additional aspects such as its description and the snapshot saving folder.
  • System - allows you to intervene on the virtual hardware of the machine, setting the amount of RAM to be used, the order of the boot devices, the chipset, details about the BIOS, the number of virtual processors and other details on virtualization.
  • Screen - from here it is possible to define the number of virtual screens to use, the amount of video memory and 2D / 3D acceleration.
  • Archiving - this section allows you to add new controllers and virtual storage devices (hard disks and CD / DVD players) and modify the existing ones.
  • Audio - in this screen it is possible to define the parameters relating to the audio of the virtual machine.
  • Network - from here it is possible to add new virtual network cards, modify existing ones, activate interfaces with NAT or Bridge or completely deactivate the network.
  • Serial ports - this screen allows you to create virtual serial (COM) ports and add them to the relevant machine.
  • USB - from here you can enable or disable support for USB controllers, define their type and filter them by device.
  • Shared Folders - from here you can add, remove or modify shared folders between the host system and the guest system.
  • User Interface - allows you to change the manager screen of the current virtual machine.

How to use VirtualBox

While the settings are relatively simple to understand, I advise you not to make any changes you are unsure of, as this could render the virtual machine in question unusable.

To overcome this problem, I recommend that you export the virtual application before making changes that you consider "risky", so that you can restore it in case something goes wrong: I explained how to do it later in this guide.

Share devices, folders and notes

How to use VirtualBox

Although the virtual machine is a separate entity from the operating system installed on the computer and from the physical devices it has, it is possible, upon request, to share devices, folders and notes to simplify the work: for example, it is possible to connect a USB device physical to the computer and use it via the virtual machine, or use copy / paste between the guest and host operating systems as one.

Before proceeding, however, I want to make you an important clarification: the changes made through the virtual machine to external devices are in effect, and cannot be undone. To give you an example, starting the formatting of a USB stick via the virtual machine will seriously erase all the data on it, without the possibility of undoing the operation.

Having made this necessary clarification, it's time to understand how to proceed: first, start the virtual machine completely until you see the operating system desktop and click on the menu devices placed at the top. If you intend to connect physical devices connected to the computer to the virtual machine, move the mouse over one of the items Optical Readers (for CD / DVD), USB (for USB devices) or Webcam, and click on the device you want to connect.

How to use VirtualBox

As for the sharing of files and folders, always from the menu devices, select the items Shared Folders> Shared Folders Settings ..., click on the icon folder with the symbol + located on the right, click the down arrow next to the box Path to the folder, presses on the voice Other and select the folder on your computer that you want to share.

If you wish, you can share it in mode Read onlymount it automatically at startup or make it permanent in the guest system by checking the appropriate boxes: after completing the necessary settings, press twice on OK and, for safety, restart the virtual operating system.

How to use VirtualBox

Finally, you can activate the sharing of notes by going, again through the menu devices, on the item Shared notes. You have four different options: the option disabled prevents clipboard sharing, from Guest to Host allows you to copy from the virtual machine and paste to the host operating system, from Host to Guest allows you to do the reverse, and Bidirectional it allows you to do both.

Export and import virtual applications

How to use VirtualBox

If you have made it this far, it means that you have all the knowledge necessary to create and manage a virtual machine in the best possible way. Before leaving, however, I would like to address a particularly important issue with you: that of backup.

VirtualBox, in fact, allows you to import and export virtual applications (i.e. virtual machines complete with settings and related devices) to facilitate the transfer of virtual machines from one computer to another or, why not, to periodically create backup copies to restore if something goes wrong.

Exporting a virtual application is really simple: in the main VirtualBox screen, the one containing the list of virtual machines, select the menu Fillet and then the voice Export virtual application ....

How to use VirtualBox

In the new screen that appears, click on the name of the virtual machine to export from the proposed list, press the button Following, select the path to save the application by clicking on the icon in the shape of folder with arrow placed next to the box Fillet (be sure to specify the .ova extension next to the file name), choose the option Open format of virtualization 1.0 give menu to tendin Size, click the button again Following and finally on the button Export- After a few minutes, the virtual application file is created in the specified location.

Importing a virtual application is just as simple: select the menu File> Import Virtual Application ..., presses the button in the shape of yellow folder with arrow placed in the next window, select the virtual application file to restore, press the button twice Following and finally on the button Import: The procedure could take up to ten minutes, depending on the complexity of the imported virtual machine.

How to use VirtualBox

add a comment of How to use VirtualBox
Comment sent successfully! We will review it in the next few hours.