Skip to main content

How to use VirtualBox to create a virtual machine

 VirtualBox is an operating system virtualization software, a powerful tool that allows you to create operating systems within your own. It is tremendously useful if you do not want to generate a dual boot on the PC itself, as it can sometimes be somewhat cumbersome. VitualBox allows you to change from your operating system to another simply by going from one window to another on the computer, it has no major complications, but there are a lot of options that have to be known before using VirtualBox in Windows 10 , which is the OS on top of it. that we are going to install and use it.


This virtualization software helps us both to have a virtual machine with another OS that we want to use without modifying the main operating system, as well as to have an independent machine as a safe environment or sandbox.


VirtualBox is free in its Oracle VM license for personal or trial use, so anyone can mess around with it at home simply by downloading it from its official website. During the installation, it should be noted that all the following options must be checked if you want to enjoy it fully and without problems, since it includes the necessary software and drivers in most cases.


How to use VirtualBox to create a virtual machine

Once installed we have the following interface, where it is possible to start preparing the virtual operating system that we want. We will have to press "New" to begin the installation.


Once installed we have the following interface, where it is possible to start preparing the virtual operating system that we want. We will have to press "New" to begin the installation.


Now it's time to tell it where to store the virtual machine container , as standard it appears in the image path but it can be any other without problem, as long as we remember where it is, because it will be important later. We can select from numerous operating systems, from Windows (versions 95 to 10) to Linux, Solaris or Mac OS X, among others.


In this case we will install two virtual operating systems, one that runs Windows 10 64-bit and the other with Ubuntu 64-bit. We will select a name for our OS and we will be able to assign RAM memory to the virtual machine . It is important to know the capabilities of our PC, because once we run the virtual OS, the RAM assigned to it will be instantly removed from our main OS. We will also have to create a virtual hard disk for VirtualBox, or use an existing one.


Now, the next step is important, since we select the capacity of said virtual storage unit , which will happen the same as with RAM, it will no longer be available for your main OS. If we select it as a fixed size, that unit will act like a normal disk and cannot be expanded or reduced later, but if we select dynamically it will be managed automatically as it needs more or less space on the main disk (that of our PC).


Virtual hard disk file types

It is necessary to clarify the types of hard disk files, since they are various and are not very enlightening at first glance.


  • VDI (VirtualBox Disk Image) is the default selection, it is the system used by Oracle VM VirtualBox, so if we don't look for anything extravagant it will be the option to choose.
  • VMDK (VirtualBox Machine Disk) is the typical format of VMWare (other virtualization software, similar to VirtualBox). This option will be chosen to have full compatibility between VMWare and VirtualBox and to be able to pass virtual operating systems between both software without major problem.
  • VHD (Virtual Hard Disk) is the option to choose if what we want is to create a versatile virtual disk, so that we can easily recover any file inside. It can be used as a regular storage unit and supports partitions of all kinds, like any other hard drive, as well as several users for each virtual OS installed on it. It is mostly used for Microsoft Virtual PC.
  • HDD (Parallels Hard Disk) is a proprietary format from Parallels company. We will select it if we want to use software from that company on a Mac computer.
  • QCOW (QEMU Copy-On-Write) and QED (QEMU enhanced disk) are formats designed to be compatible with QEMU software, other virtualization software such as VMWare or VirtualBox.

Once selected, the virtual machine will be prepared and will appear visible in a few minutes, giving a summary of its specifications when clicking on it. In this case we have taken advantage and created the two mentioned above.

Now giving "Start" we can enjoy our OS, or almost...


We are missing the virtual OS image that we have run. The images of the operating systems can be found on the pages of the respective companies, in our case we have downloaded both the Ubuntu 64-bit and the Windows 10 64-bit, both free from the Ubuntu and Microsoft websites, respectively. We will have to download the iso, in order to now select the corresponding unit. Here you can see how to download Windows 10 for free step by step. The first time we run the virtual machine it asks us to select an iso file, but if we do not have it at that moment and we decide to restart it, we will have to do the following steps. At the moment we restart the machine and repeatedly press F12 to select the boot device.

Now we click on “Optical Drives” and we click “Select disk image…”, we look for where we downloaded it previously and then we press the “c” key to start from the CD-ROM drive simulated by the iso image.

The virtual OS will begin to install itself in the assigned virtual space and it only remains to wait for it to finish, it is like an installation of a common operating system, exactly the same.

The system informs us whether the mouse integration is available or not, so that if it is, there will be no problems of use and the mouse icon can be used without complications between the virtual OS and the main one.

During this guide on how to use VirtualBox to create a virtual machine , we have taken the opportunity to also install Windows 10 Home 64-bit. Now we will see that in each virtual operating system there are the default specifications for it, the assigned RAM, the available storage space and the processors they have.

It is advisable, most of the time, to use a higher screen resolution than the default one. To do this, in Ubuntu we can go to Settings, Monitors and select a higher resolution to work more comfortably.

Returning to the issue of the resources used by VirtualBox , which assigns different specifications to each OS, they can be easily managed with the virtual machine turned off. To do this, we just have to select the machine we want and click "Configuration".

From allocating amount of RAM to the virtual machine and BIOS options to the number of processors that each of them can use. For example, if we select 1 CPU, we are giving a thread (not a core) to said virtual machine, and can also establish a limit on its use.

The acceleration options should always be activated, and they are essential to run virtual machines with ease, although they will not always be available, since this depends on the physical processor you have installed on your PC. Virtualization options for virtual machines are built into many Intel and AMD processors, especially the newer ones.


In the same way, in the rest of the sections you can choose the video memory that you give to the virtual machine and numerous options for network, audio and USB controllers.

Now, to share files in VirtualBox , specifically between the virtual machine (guest) and our PC (host), we will go to the "General" tab and activate clipboard sharing and drag and drop. With this we have a fast flow of files and text between our PC and the virtual OS.

Let's now try to share entire folders. For this we have to click on "Devices" and on "Insert CD image of Guest Aditions ". A drop-down will appear that informs us that we must install them to use them, but having done the previous step we have them available to run from "This Computer" and double-clicking on the simulated CD drive in the virtual machine.

It will ask us to restart at the end of the installation, but we are ready to share folders and files between virtual machines.


Migrate a virtual operating system

One of the great advantages of using VirtualBox is its manageability, it is very versatile and you can take it wherever you want, as long as you have VirtualBox installed on the other PC you go to. For this we just have to go to the folder where we initially selected the installation of the selected virtual machine. We will see a file with the extension “.vbox”, in it is our complete virtual machine, with all the configuration and the operating system that we have used with the documents and programs that we may have in it. We do not lose anything and we can easily carry it on a pendrive from computer to computer.

Create a virtual hard disk and advantages in server environment

At the beginning of the guide we discussed the different types of virtual hard disk files . The VHD (Virtual Hard Disk) file type allows us to have more flexibility in the event of failures, in addition to several users at the same time within the same virtual OS, as well as several virtual OS installed in it by partitions.

This supposes several things, all positive. To begin with, the biggest advantage of using this format is that we will have direct access to the files of our virtual machine, which means that, in server environments, if something goes wrong and we have problems starting the virtual OS, we can easily recover the files that in it we could have. It is like when a computer does not start and there is no way to make it work if it is not by formatting, in this case having access to the files that are in it and we can rescue the information we want to, then install the virtual OS again.

For this we write on our PC "Disk Administrator" and select the option that appears recommended.


Now we click on "Action" and then on "Expose VHD", we select the path where our VHD created by VirtualBox is located and we accept. Then two additional storage units will appear in "This Computer", one is the system (created by the virtual OS) and the other is the virtual OS itself, with all its files and settings. It is important to note that this will not work if we are running said virtual machine, so we will have to stop it to do it.

With this we can rescue files from a computer that does not start , as long as that computer is virtualized and we have it in VirtualBox VHD format. The limitations of using VHD are, basically, not being able to assign more than 2 TB per VHD disk created, in addition to not being able to resize the storage that we assigned to it at first if the virtual machine is running (although it can be if it is turned off).

So far the guide on how to use VirtualBox , and as a small summary it is worth highlighting the part in which we talk about the compatibility of virtual machines between the different operating system virtualization software. These options are very interesting to migrate virtual machine containers from one PC to another, even from one program to another, without headaches.

Virtualization software comparison

Although we have seen how VirtualBox works , we can now establish some comparisons with other systems to virtualize, such as VMWare or Parallels. While VirtualBox is free and open source software , VMWare offers a trial period and then you will have to pay for one of the existing versions, just like Parallels. VirtualBox can be installed on Linux, Windows, Mac OS, and Solaris, while VMWare only on the first three and Parallels on Windows and Mac OS.

Other differences come when it comes to running 3D programs in the virtual machine , since VirtualBox offers only 128 MB of graphics memory, while the other two reach up to 2 GB, thus making it possible to use it for 3D development and games. In addition, these two also have support for DirectX 10 while VirtualBox stays at DirectX 9.

The types of virtual hard disk that we can create with VirtualBox, as we saw at the beginning, are varied (VDI, VMDK, CHD and HDD), while with VMWare and Parallels we restrict ourselves to VMDK. All three offer virtual machine encryption , although an additional software pack must be installed in VirtualBox for this.

Basically, if we want to give our virtual machine a regular home use, better choose VirtualBox since it is free and will cover all the demands of home users, while for business use we have VMWare (in its Workstation version) with great 3D support and tools advanced virtualization for business. To play in the virtual machine we can use both Parallels and VMWare, their use being restricted in VirtualBox due to the limited graphic capacity.

Comments