VirtualBox – Linux Hint https://linuxhint.com Exploring and Master Linux Ecosystem Mon, 01 Mar 2021 00:18:05 +0000 en-US hourly 1 https://wordpress.org/?v=5.6.2 How to Install VirtualBox on Linux Mint 20 https://linuxhint.com/install-virtualbox-linux-mint/ Wed, 24 Feb 2021 16:17:51 +0000 https://linuxhint.com/?p=91342

Developed and maintained by Oracle, VirtualBox is a multi-platform, open-source hypervisor that enables us to run multiple virtual machines as a guest operating system on a single host. VirtualBox is more often used for testing and development purposes.

VirtualBox can be installed on Linux Mint 20 from the standard repositories and Oracle’s official VirtualBox repository.

Installing VirtualBox on Linux Mint 20 from the standard repositories

As VirtualBox is a popular and open-source tool, it is included in the Linux Mint 20 standard repositories. Fire up the terminal and update the apt cache as it is recommended to do so before installing any new application:

$ sudo apt update

Next, install the VirtualBox and the extension pack with the command:

$ sudo apt install virtualbox virtualbox-ext-pack

Press ‘y’ to continue installing VirtualBox.

While installing VirtualBox, you will see the VirtualBox Personal Use and Evaluation License (PEUL). Read the license agreement carefully, choose ‘OK’ and press the enter key.

If you accept the VirtualBox PUEL license terms, select ‘Yes’ and press enter key.

The VirtualBox will be successfully installed on your Linux Mint 20 system.

To verify the installation, click on Application Menu and search for VirtualBox. You will find the VirtualBox application in Application Menu.

Installing VirtualBox on Linux Mint 20 from the Oracle repositories

As of writing this post, the newest version of VirtualBox is 6.1.

Complete the below-given steps to install VirtualBox on Linux Mint 20 from the Oracle repositories:

Step 1: Import VirtualBox key

Fire up the terminal and import the Oracle VirtualBox’s public key on your Linux Mint 20 system using the command:

$ wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -

The above-given command requires the sudo privileges, enter the sudo password, and the key will be imported successfully. The ‘OK’ confirms that the key is imported.

Step 2: Add VirtualBox repository

Next, add the VirtualBox repository to your Linux Mint 20 system:

$ echo "deb [arch=amd64] http://download.virtualbox.org/virtualbox/debian focal contrib" | sudo tee /etc/apt/sources.list.d/virtualbox.list

Step 3: Install VirtualBox

First, update the apt listing with the command:

$ sudo apt update

Now, install the VirtualBox with the command:

$ sudo apt install virtualbox-6.1

Press ‘y’ to continue installing VirtualBox.

The VirtualBox will be installed on your system.

Once the VirtualBox is installed, verify the VirtualBox installation with the command:

$ sudo systemctl status vboxdrv

The above-given command checks the VirtualBox Linux Kernel module service status. The output shows that the VirtualBox is successfully installed, and the service is active.

Getting started with VirtualBox

Click on the Application Menu, and search for the VirtualBox.

VirtualBox is ready for use.

Conclusion

This post has learned about installing VirtualBox on Linux Mint 20 from the Linux Mint 20 standard repositories and Oracle’s official repository.  VirtualBox is a hypervisor that allows us to run multiple virtual machines on a single host machine simultaneously. It is designed and maintained by Oracle.

]]>
Sharing Folders between Host OS and Guest OS in VirtualBox https://linuxhint.com/folder_sharing_virtualbox/ Wed, 28 Oct 2020 14:25:36 +0000 https://linuxhint.com/?p=74434 When working on a guest OS, you often need to share files to and from the host OS. A guest OS is an isolated OS that has access to neither the host nor the other machines in VirtualBox. However, the VirtualBox guest addition utility enables the guest machine to share files to and from the host OS.

In this article, we will show you how to install VirtualBox Guest Additions and share folders between the host OS and the guest OS.

Prerequisites

  1. Host OS with VirtualBox installed
  2. Guest OS installed in the virtual machine

For this demonstration, we are using Windows10 as the host OS and Ubuntu 20.04 LTS as the guest OS. To enable sharing between guest and host OS, we will install VirtualBox Guest Additions on the guest OS and then share and mount a folder from the host OS to the guest OS. Let’s get started.

Install VirtualBox Guest Additions on the guest system

To enable file sharing between host and guest, you must install Guest Additions in the guest OS. To do so, the following steps must be taken:

1. Open VirtualBox in your host system and start a guest operating system.

2. On the top menu bar of VirtualBox, click Devices, then select Insert Guest Additions CD image to insert a virtual CD inside the guest system.


3. The following message will appear. Click Run to install Guest Additions on the guest machine.


4. Installation will begin, and once completed, you will be asked to press Enter to close the window. Press Enter to finish the installation.


Once VirtualBox Guest Additions has been installed on the Guest OS, you can share folders between the host system and the guest system.

Share folders between host and guest

Now, we will share a folder between the host and guest systems. You can share multiple folders between the guest OS and the host OS. For folder sharing, either create a new folder or use an existing folder. Follow the steps below to share a file or folder between the host and guest systems.

1. From the top menu bar of VirtualBox, go to Shared Folders > Shared Folders Settings.

2. You will see the following settings window in your guest system. Click the + button to open the Add Share dialog box.

3. In the Add Share dialog box, select the shared folder using the Folder Path drop-down, and choose a folder from your host OS. Then, type a name for your shared folder, and check the Auto-mount box. The Auto-mount option will automatically mount the shared folder on the next boot.


Now, click OK to close the Add Share dialog. You will now see the shared folder in the Settings window. Click OK to close the window.


4. By default, only root and members of vboxsf are allowed to access the shared folder. To assign permissions to your user account, issue the following command in the terminal, replacing with the actual username:

$ sudo usermod -aG vboxsf

5. If you open File Manager or Explorer in your guest OS, then you will see the shared folder sf_shared_folder mounted there, where sf_shared_folder is the name of your shared folder.


The shared folder can also be accessed from the command line. Open the command line using Ctrl+Alt+T, and then navigate to /media directory using the following command in the terminal:

$ cd /media

Here, if you run the cd command, you will see your shared folder listed under the /media directory.


Now, navigate to the shared folder using the cd command as follows:

$ cd sf_shared_folder/

Make sure to replace sf_shared_folder with the name of your shared folder.

In the shared folder, you can place any file you want to share with your host OS. Similarly, you can access any file shared by your host OS.

Conclusion

This article showed you how to set up folder sharing between a host system and a guest system in VirtualBox. You need to follow the above procedure for your guest machines only once. After that, the shared folder of the host will be automatically mounted in the guest OS on every boot for file sharing.

]]>
How to install Peppermint OS in Virtual Box https://linuxhint.com/install_peppermint_os_virtual_box/ Sun, 18 Oct 2020 12:00:21 +0000 https://linuxhint.com/?p=72250 Linux is one of the most sought-after operating systems in recent times. With each passing year, Linux is making a surge and seems to be catching up to Windows and Mac OS. Even now, it is finding its way onto the systems of several large companies, the most notable ones including Facebook, Google, etc. The beauty of Linux is that since it is free and open-source and is highly customizable, users have gone on to create their own versions of operating systems having Linux as their kernel.

These operating systems are often referred to as distributions and each distribution is a flavor that has been catered to meet the interests of a specific set of users. One such great alternative is the Peppermint OS distribution, an extremely lightweight Lubuntu based Linux distribution that makes use of the LXDE desktop environment.

Hence, the topic of our discussion in this article is how one can install Peppermint OS on VirtualBox

Prerequisites

Before we move onto the process of installing Peppermint OS on our VirtualBox, we first need to set up our system and download the required applications. The first thing users need to make sure is that virtualization is turned on in their systems. To check this, open the BIOS Settings and go to System Configuration. Over here, you can see if Virtualization Technology is disabled or enabled. If it is indeed disabled, move the cursor to it and hit the enter key. Now simply select the enabled option and then restart your system.

After enabling virtualization, we need to download VirtualBox, a virtualization software used to host and run operating systems alongside your default one. It is available for all three Windows, Linux, and Mac OS platforms.

Another thing that is required is the Peppermint OS Disk Image File. This can be downloaded by going to its official website and opening the Download and Install section.

It offers multiple ways for users to download their iso file. Choose the one that suits you best.

After downloading the Image file, we need to conduct an integrity check which can simply be done by running the following command into the terminal:

$ md5sum Image-FileName

If your result is the same as the one given below, then the download was successful.

Setting Up Your Virtual Machine

Now, open up VirtualBox and hit the New button at the top to create a new virtual machine.

This will open a prompt asking you to name your virtual machine, set your base folder, the type, and version of the operating system that you will be using. It should be similar to the following:

Do note, if you are using a 32-bit version, then choose the Ubuntu 32-bit option in the version section.

After clicking Next, it will then ask you to set the amount of RAM that you want to allocate to this VM. The minimum system requirement to run Peppermint OS is 512 MB but we will be allocating it around 1500MB, so it runs much more smoothly.

Click on Next and you will be directed to the type of Hard disk you want for your VM. Choose the Create a virtual hard disk now option and click on Next.

In the next prompt, keep it as VDI and move ahead by clicking Next.

In the next prompt, it will ask you whether you want the storage of your hard disk to be dynamically allocated or of fixed size. The main difference between the two is that dynamically allocated disks only use the amount of data that you have on your disk while fixed disks will use the complete space that you have specified. It is much better to use dynamically allocated as your storage in my opinion, but some people prefer the fixed drive as it is often faster to use.

Finally, specify the amount of memory that you want to give to your VM. It is better to give at least 10 GB of disk space to your Peppermint OS virtual machine.

After this, click on Create and your VM should be setup.

Adding Peppermint OS to Virtual Machine

After setting up your virtual machine, you will be directed to the main menu where you should click on the Settings button.

Over here, open the Storage section and then click on Empty under the Controller IDE. Next, click on the CD icon next to the Optical Drive and select the Choose a disk file option. Insert the Peppermint iso file that you downloaded here.

It will look something like the following:

After this, click on OK and you will once again be directed to the main menu. Finally, click on the Start Button to start the Peppermint OS boot menu.

Installing Peppermint OS

After clicking on Start, it will ask you to select the start-up disk which would be the iso file that you set up before.

Next, it will provide you with an installation menu having multiple different options. For users that are still not sure about Peppermint, I recommend choosing the Try Peppermint OS as a Live option. We will be going ahead and selecting the Install Peppermint OS option.

It will then take a few minutes to start up the installation process. Once it does, it will ask you to choose the standard language for your system as well as the keyboard.

After this, it will ask you the applications you want to install along with a few other options like downloading updates and installing third-party software. Choose whichever option suits you best. Selecting the other options, however, will make the installation process longer so do keep that in mind.

After selecting the applications, you will then be asked to specify the installation type. For virtual machines, I recommend going with the default option – Erase disk and install Peppermint.

After this, it will ask you to set up your location which if you are already connected to the internet, the Peppermint installer will automatically set it up.

After setting your username and password for your system, click on Continue to start your installation process which may take a few minutes to complete.

After the installation process is complete, it will then ask you to restart your Peppermint OS in your VirtualBox.

Voila! Peppermint OS has been installed on VirtualBox.

Why Peppermint OS?

Peppermint OS is an extremely lightweight and stable operating system, having a wonderful performance to top it off. Peppermint OS has the LXDE desktop environment as its default which is great for systems with low specs. It integrates all the great things from other Linux distributions and is a solid choice for having as your main operating system.

]]>
Install and Use VirtualBox in Ubuntu 20.04 https://linuxhint.com/install_use_virtualbox_ubuntu/ Mon, 21 Sep 2020 06:32:58 +0000 https://linuxhint.com/?p=68830 VirtualBox is a free and open-source cross-platform virtualization tool developed and maintained by Oracle. VirtualBox offers tons of interesting features, packed in a simple and intuitive UI. Compared to alternatives like VMware Workstation, VirtualBox is more user-friendly for anyone, in any situation.

Interested in testing out a new distro? Instead of installing it over the current system, try the system out first using VirtualBox. Need to have multiple operating systems running at the same time? VirtualBox has got you covered. Almost all aspects of a virtual machine are customizable.

This guide shows you how to install and use VirtualBox in Ubuntu 20.04.

VirtualBox in Ubuntu

There are a few ways to install VirtualBox in Ubuntu 20.04. The simplest way to install VirtualBox is to get it directly from the Ubuntu software repos. The only problem with this method is that you may not get the latest version of VirtualBox.

It is also possible to perform a manual installation of VirtualBox. You can grab the official VirtualBox DEB package for Debian/Ubuntu and install it using APT. The downside with this approach is that you must manually update VirtualBox once a new version is released. This can be circumvented by adding the Oracle repo.

Finally, you can install VirtualBox directly from the source code. This method allows you to build VirtualBox from the source but can be a lengthier and more complex process. Installing VirtualBox using this method is not recommended, as you will have to follow it again to update VirtualBox, but this method can be used by advanced users who like to build programs from the source code.

Let us begin!

Install VirtualBox from the Ubuntu Repository

This is the default method for installing VirtualBox. All you have to do is tell APT to get the VirtualBox package from the default Ubuntu repos.

Fire up the terminal and run the following command:

$ sudo apt update && sudo apt install virtualbox virtualbox-ext-pack -y

When prompted for virtualbox-ext-pack configuration, select “Ok.”

Accept the VirtualBox PUEL license.

The virtualbox-ext-pack will automatically download and install the VirtualBox extension pack.

Install VirtualBox from the Oracle Repository

This method is useful if you need the latest version of VirtualBox. To make this work, you must perform a one-time configuration of the Oracle repo. After that, APT can handle the rest.

Fire up a terminal. Make sure that you have wget installed.

$ sudo apt update && sudo apt install wget -y

Grab and add the Oracle VirtualBox repo GPG keys.

$ wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- |
 sudo apt-key add -

$ wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O-
| sudo apt-key add -

Now, add the repo.

$ sudo add-apt-repository "deb [arch=amd64] http://download.virtualbox.org/
virtualbox/debian $(lsb_release -cs) contrib"

Update the APT cache.

$ sudo apt update

Finally, install VirtualBox. At the time of writing this article, the latest version of VirtualBox is v6.1.12.

$ sudo apt install virtualbox-6.1

Install VirtualBox from the Source Code

The source code of VirtualBox is available for free. This allows the ability to build VirtualBox manually from the source. This is a relatively lengthy and complex process that requires more hardware resources and effort. Installing VirtualBox using this method is not recommended, as you will have to follow it again to update VirtualBox. Full information on building VirtualBox on Linux can be found at the VirtualBox wiki page.

First, install the build dependencies.

$ sudo apt install \
$ acpica-tools chrpath doxygen g++-multilib libasound2-dev libcap-dev \
$ libcurl4-openssl-dev libdevmapper-dev libidl-dev libopus-dev libpam0g-dev \
$ libpulse-dev libqt5opengl5-dev libqt5x11extras5-dev libsdl1.2-dev libsdl-ttf2.0-dev \
$ libssl-dev libvpx-dev libxcursor-dev libxinerama-dev libxml2-dev libxml2-utils \
$ libxmu-dev libxrandr-dev make nasm python3-dev python-dev qttools5-dev-tools \
$ texlive texlive-fonts-extra texlive-latex-extra unzip xsltproc \
$ default-jdk libstdc++5 libxslt1-dev linux-kernel-headers makeself \
$ mesa-common-dev subversion yasm zlib1g-dev

The following build dependencies should also be installed if you are running the 64-bit version of Ubuntu.

$ sudo apt install lib32z1 libc6-dev-i386 lib32gcc1 lib32stdc++6

For Python hacking, consider installing the following packages, as well.

$ sudo apt install pylint python3-psycopg2 python3-willow python-pil

Building VirtualBox on a 64-bit host system still requires all the 32-bit libraries and build tools. In the case of the 64-bit Ubuntu version, it has some missing shared libraries. Run the following command to fix it.

$ sudo ln -s libX11.so.6 /usr/lib32/libX11.so

$ sudo ln -s libXTrap.so.6 /usr/lib32/libXTrap.so

$ sudo ln -s libXt.so.6 /usr/lib32/libXt.so

$ sudo ln -s libXtst.so.6 /usr/lib32/libXtst.so

$ sudo ln -s libXmu.so.6 /usr/lib32/libXmu.so

$ sudo ln -s libXext.so.6 /usr/lib32/libXext.so

Download the latest source code of VirtualBox here.

Extract the compressed archive.

$ tar -xvf VirtualBox-6.1.12a.tar.bz2

Change the current directory to the extracted source and run the configuration script. Note that the “–disable-hardening” flag should not be used if you intend to redistribute or use the build for production.

$ ./configure --disable-hardening

Load the environment setup script.

$ source ./env.sh

It is now finally time to build VirtualBox. Run the following command to build a release package of VirtualBox.

$ kmk all

If the build was not hardened, VirtualBox can be run from the “out/linux.amd64/release/bin” directory under the source code directory. However, the VirtualBox kernel modules must be built and installed first. To do so, enter the following code.

$ cd out/linux.amd64/release/bin/src

$ make -j$(nproc)

$ sudo make install

Load the modules.

$ modprobe vboxdrv

Finally, launch VirtualBox.

$ ./VirtualBox

Using VirtualBox

VirtualBox is very user-friendly. All of its functions are simple, yet VirtualBox offers full control over almost every aspect of a virtual machine. Here, we will check out how to create and launch a VirtualBox virtual machine.

Before creating a virtual machine, install the VirtualBox extension pack. Download it from the VirtualBox download page here.

Once the package is downloaded, install the package using the following command.

$ sudo VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-6.1.12.vbox-extpack

The installation will ask for the PUEL license agreement. Enter “y” to continue.

The installation should complete without any issue.

It is now time to create a virtual machine. Launch VirtualBox.

Click “New” to create a new virtual machine.

Give the new virtual machine a suitable name. In this example, I will create an Ubuntu virtual machine, so I will select the “Type” as “Linux” and the “Version” as “Ubuntu_64.”

Next, assign the amount of RAM space you want the virtual machine to take. It is recommended to assign 4GB of RAM.

VirtualBox will ask for a hard disk file creation for the virtual machine. The file will act as physical storage. Select “Create a virtual hard disk now.”

You will be asked for the file type of the virtual hard disk. For most, the VDI format will be more than enough.

VirtualBox will ask how the virtual storage file will be created. If “Dynamically allocated” is selected, then the storage file will grow as it is used more. If “Fixed size” is selected, the file will use the maximum storage on the physical drive. The benefit of the second option is that it offers more performance for the virtual machine.

Select the size and location of the virtual hard disk file.

The virtual machine is now ready to boot! You will need to have the Ubuntu image file at hand, as the machine will ask for a boot device/image. For the remainder of the installation, check out this awesome guide on how to install Ubuntu 20.04 on VirtualBox here.

Final Thoughts

There are plenty of options available to tweak the behavior of VirtualBox and virtual machines. Feel free to explore these. There are plenty of online materials available on how to use VirtualBox to its fullest capacity.

Enjoy!

]]>
How to Install Virtual Box on Ubuntu 20.04 https://linuxhint.com/installing_virtual_box_ubuntu/ Wed, 16 Sep 2020 11:53:38 +0000 https://linuxhint.com/?p=68384 If you are looking for a free powerful tool to run a virtual operating system, then VirtualBox by Oracle is of no exception.

Oracle Virtualbox is a free, open-source, and cross-platform that helps you to run multiple guests operating systems on your computer at the same time. Oracle corporation developed this amazing feature in the year 2007.

It can be installed on macOS, Linux, Windows, Solaris, and OpenSolaris.

Why should you use and install the Virtual Box on Ubuntu 20.04

1. It is very easy to install and use on your computer.

2. It updates often.

3. There is a great community to support you there.

4. There is a variety of disk images format available on the software that allows us to run multiple OS simultaneously.

5. There are various options available for customization.

This article will provide you complete information on how to install VirtualBox on Ubuntu. 20.04.

Prerequisites:

The following are the prerequisites before the installation of the software:

Before going to install VirtualBox on Ubuntu 20.04 on your operating system, you must have a user account with sudo privileges and a terminal window.

Installation Virtual Box from Ubuntu Repositories:

To install virtual box from Ubuntu repositories, just run the command given below:

$ sudo apt install virtualbox virtualbox-ext-pack

Installation Virtual Box from Oracle Repositories:

Firstly, you should install the latest version of Ubuntu. Many users wish to work on new functionality. Unfortunately, default repositories lack the latest version. Some users want the latest security and functionality, but the default repositories don’t have the latest version of the software. For this reason, they have to work only in the testing environment.

First step: Installation of supporting software:

The VirtualBox on Ubuntu required a package to run on your computer. A specific package is used to run VirtualBox on Ubuntu, known as software-properties-common.

Enter the following keywords in the terminal window:

$ sudo apt-get install software-properties-common

Second Step: Installation of GPG Keys:

Installation of GPG keys helps you to verify and communicate with the VirtualBox Repository.

Following are the commands that you can use to download and install GPG keys:

$ wget -q http://www.virtualbox.org/download/oracle_vbox_2016.asc-O-
 | sudo apt-key add -

$ wget -q http://www.virtualbox.org/download/oracle_vbox.asc-O-
| sudo apt-key add -

Third Step: Adding of VirtualBox Repository to Ubuntu:

Enter the following commands to add VirtualBox Repository to Ubuntu:

$ echo "deb [arch=amd64] http://download.virtualbox.org/virtualbox/debian
$(lsb_release -cs) contrib"
| \ sudo tee -a /etc/apt/sources.list.d/virtualbox.list

Fourth Step: Installation of the latest version of VirtualBox:

Update the package list by using this command:

$ sudo apt update

$ sudo apt install virtualbox-6.1

Fifth step: Installation of VirtualBox extension pack:

If you want to increase the functionality of your virtual machines, install the VirtualBox extension pack too. It will facilitate you with other tools like Remote Desktop, encryption and USB 2.0 & 3.0

Enter the following command to install the extension pack:

$ wget http://download.virtualbox.org/virtualbox/6.1.12/
Oracle_VM_VirtualBox_Extension_Pack-6.1.12.vbox-extpack

In the last, confirm your installation and allow the process to complete.

How to launch the software on your computer:

You can launch the software on your computer by using a terminal or desktop application search.

Conclusion:

You can now create your first Linux or Windows Guest Machine by following the above procedure of installing VirtualBox on Ubuntu 20.04.

]]>
Install VirtualBox Guest Additions on Ubuntu VirtualBox VM https://linuxhint.com/install_virtualbox_guest_additions_ubuntu/ Sun, 12 Jan 2020 11:52:22 +0000 https://linuxhint.com/?p=53298 If you’re using VirtualBox for virtualization, then VirtualBox Guest Additions is a must have tool for you.

VirtualBox Guest Additions allows you to use the following features of VirtualBox:

  • Mouse pointer integration: You can move in and move out of the VM freely. You no longer need to press the Host key (usually Right <Ctrl> key).
  • Shared folders: You can share folders/directories from your host computer to the VirtualBox VM.
  • Shared clipboard: You will be able to share clipboards between the host and the VM.
  • 3D and 2D acceleration: You will be able to use 2D and 3D graphics acceleration in your VirtualBox VM.
  • Resizable VM Window: You will be able to freely resize the VM window and the VM screen resolution will automatically adjust.
  • Time synchronization: You will be able to synchronize the host time with the VM.

In this article, I am going to show you how to install VirtualBox Guest Additions on your Ubuntu VM. So, let’s get started.

Installing Required Build Tools on the Ubuntu VM:

In order to install VirtualBox Guest Additions on Ubuntu, you will have to install all the required build tools.

First, start your Ubuntu VirtualBox VM, open a Terminal and update the APT package repository cache with the following command:

$ sudo apt update

The APT package repository cache should be updated.

Now, install all the required build tools with the following command:

$ sudo apt install build-essential linux-headers-$(uname -r) dkms

Now, press Y and then press <Enter> to confirm the installation.

The APT package manager should start downloading all the required packages from the official package repository of Ubuntu.

At this point, all the required packages should be installed.

Now, shutdown the Ubuntu VM with the following command:

$ sudo poweroff

Inserting the VirtualBox Guest Additions CD to the VM’s CDROM:

Now, you have to insert the VirtualBox Guest Additions CD to the Ubuntu VM.

First, select the Ubuntu VM and click on Settings.

Now, from Storage, select the CDROM device, click on the CD icon and click on Remove Disk from Virtual Drive.

The currently attached CD/DVD should be ejected. Now, click on OK.

Now, select your Ubuntu VM and click on Start to start the VM.

Once the Ubuntu VM starts, click on Devices > Insert Guest Additions CD image… as marked in the screenshot below. The VirtualBox Guest Additions CD image should be attached to the virtual CDROM of the Ubuntu VM.

Installing VirtualBox Guest Additions Graphically:

Once you insert the VirtualBox Guest Additions CD image, Ubuntu should ask whether you want to install VirtualBox Guest Additions or not as you can see in the screenshot below.

You can click on Run to start the installation.

You can also navigate to the VirtualBox Guest Additions CD from the file manager and click on Run Software in order to start the installation. Both ways work just fine.

Once you click on Run, Ubuntu will ask you for the password of your login user. Type in the password of your login user and click on Authenticate.

The installation should start. It may take a while to complete.

The installer is updating the kernel.

At this point, the installation should be complete. Now, press <Enter> to close the Terminal window.

Now, restart your Ubuntu VM for the changes to take effect with the following command:

$ sudo reboot

Installing VirtualBox Guest Additions from the Command Line:

If you’re using Ubuntu server without any graphical user interface, then installing VirtualBox Guest Additions from the command line is your only option.

Once you attached the VirtualBox Guest Additions CD image to the virtual CDROM of your Ubuntu VM, mount the CD image to the /mnt directory with the following command:

$ sudo mount /dev/sr0 /mnt

The VirtualBox Guest Additions CD image should be mounted in the /mnt directory.

Now, navigate to the /mnt directory as follows:

$ cd /mnt

You should see VBoxLinuxAdditions.run shell script in there.

$ ls -lh

Now, run the VBoxLinuxAdditions.run shell script with superuser privileges as follows:

$ sudo bash VBoxLinuxAdditions.run

The installation should start. It may take a while to complete.

The installer is updating the kernel.

At this point, the installation should be complete.

Now, restart your Ubuntu VM for the changes to take effect with the following command:

$ sudo reboot

Enabling Some VirtualBox Guest Additions Features:

Once you have VirtualBox Guest Additions installed, you will immediately be able to resize the VirtualBox window to any size and your Ubuntu VM will adjust to it automatically.

You can also enable Shared Clipboard and Drag and Drop features from the General > Advanced settings of Ubuntu VM.

So, that’s how you install VirtualBox Guest Additions on Ubuntu VirtualBox VM. Thanks for reading this article.

]]>
How to Install VirtualBox 6 on Debian 10 https://linuxhint.com/install_virtualbox6_debian10/ Mon, 30 Dec 2019 03:33:22 +0000 https://linuxhint.com/?p=52607 This tutorial shows how to setup VirtualBox 6.1 on Debian 10 Buster, it is also useful for previous versions of Debian and for Ubuntu too.

This tutorial shows the installation process through the .deb package available at VirtualBox official website omitting the process related to apt or aptitude package managers though keeping it to fix dependencies.

How to Install VirtualBox 6 on Debian 10

To begin downloading VirtualBox from the official website select it from https://www.virtualbox.org/wiki/Linux_Downloads.

You can also download it through console using the command wget:

#  wget https://download.virtualbox.org/virtualbox/6.1.0/virtualbox-6.1_6.1.0
-135406~Debian~buster_amd64.deb

Install it using the dpkg command:

# dpkg -i <package.deb>

In my case I run:

# dpkg -i virtualbox-6.1_6.1.0-135406~Debian~buster_amd64.deb

Note: for more information on dpkg command you can read All about the debian package managers: dpkg, apt and aptitude explained.
At some point the installer may stop returning a dependency error, if that’s your case and your installation doesn’t finish successfully run:

# apt update && upgrade
# apt install -f

The step above should troubleshoot some possible dependency problems.

Now install the kernel headers by running:

# apt install linux-headers-amd64 linux-headers-4.19.0-6-amd64

Build VirtualBox kernel modules by running:

# /sbin/box config

Then launch Virtualbox as non root user

$ virtualbox

The image above shows VirtualBox’s main window without defined virtual devices.

Creating a Windows XP Virtual PC under Debian 10 Buster

 To get started setting up a virtual OS from its ISO image click on the icon “NEW”, the following example shows a Windows XP installation from an ISO installable image, if you prefer to install a Linux distribution you can read Installing Debian 10 on VirtualBox.

Choose your virtual computer name and press on Next.

Select the ram memory amount you can to assign your virtual device and press on Next.

Press Create leaving the default option to continue.

Leave the default VDI option and press Next.

The last step allows us to define the space allocation, press on Create to end the process and start the OS installation.

Once the process is finished, VirtualBox will show the new virtual device on the left menu.

To start installing the OS click on START.

In the next screen select the folder icon to browse searching your OS ISO image.

A new window will prompt in which you need to press on the “Add” icon with a + symbol to select the ISO image.

Select your ISO location and file and press Open to continue.

Press on Choose to confirm and continue the process.

Then press on START to run the Windows installator.

The installator will start requesting you to press ENTER and F8 to begin the process.

Note: during the process the mouse pointer may be captured by the virtual pc, you can press your right CTRL to release your mouse.

Give the total amount of available space and format it as NTFS (Quick).
The first GUI screen will ask for location and language settings, after chosen press on Next.

Then fill the Windows CD key serial.

Set the virtual computer name and press on Continue.

Optionally you can set an Administrator password, contrary to Linux Windows formerly didn’t require a password as mandatory, and even if defined it could be avoided by pressing “cancel”.

On the next screen you need to select your time and location settings:

In the following screen leave “Typical settings” and press Next to continue.

The next step will ask for the Workgroup name, press Next to continue.

Now let Windows installer to finish

Finally Windows XP main screen will show up.

Adding the VirtualBox 6.1.0 Oracle VM VirtualBox Extension Pack


Additional packages can increase VirtualBox functionalities by adding features such as:

(Source: https://www.virtualbox.org/manual/ch01.html#intro-installing)

You can download the extension pack from the link:
https://www.virtualbox.org/wiki/Downloads

Or using wget by running:

# wget https://download.virtualbox.org/virtualbox/6.1.0/Oracle_
VM_VirtualBox_Extension_Pack-6.1.0.vbox-extpack

Then just double click on the downloaded file:

The Extension Pack installer will prompt, press on Install to confirm

On the License screen scroll down and press on I Agree to continue.

If asked, fill your root password to allow the installation.

Once ended the process will show if installed successfully.

Press OK, the Extension Pack is already installed.

I hope you found this brief tutorial on Installing VirtualBox 6 on Debian 10 Buster useful, thank you for reading it.

Related articles

]]>
How to Access VirtualBox 6 VMs Remotely https://linuxhint.com/access_virtualbox6_vms_remotely/ Sat, 28 Dec 2019 04:15:40 +0000 https://linuxhint.com/?p=52436 VirtualBox is an open source virtualization platform. It is an alternative to VMware Workstation Pro, VMware Player and VMware Fusion. VirtualBox VMs can be accessed remotely over the RDP (Remote Desktop Protocol) protocol. In this article, I am going to show you how to setup remote access on VirtualBox VM (virtual machine) and access them from Windows Remote Desktop client and Remmina on Linux. So, let’s get started.

Setting Up Remote Access to VirtualBox VM:

First, open VirtualBox. Now, select the VM (virtual machine) which you want to access remotely and click on Settings. The VM (virtual machine) must be powered off in order to enable remote access. Otherwise, it won’t work.

Now, from Display, click on the Remote Display tab. From the Remote Display tab, check the Enable Server checkbox to enable VirtualBox remote display server.

Now, you can adjust the remote server settings from here.  Here, the main thing is the Server Port. Server Port is a 16-bit integer. It can be a value between 0-65535. The default Server Port is 3389. You should set Server Port to 3389 or higher.

Remember that each VM you enable remote access to must have different server port number. No 2 or more VM can have the same server port.

By default, VirtualBox allows only a single remote session to the virtual machine. If you want multiple remote sessions to the same virtual machine, check the extended feature Allow Multiple Connections.

Once you’re done setting up the VirtualBox Remote Display Server for the VM, click on OK.

Now, start the VM.

The virtual machine should start.

Now, you can check whether the remote server port is being used by VirtualBox VM with the following command:

$ sudo netstat -tlpn | grep VM

As you can see, the port 3389 (in my case) is used by the VirtualBox VM and it’s in LISTEN state. So, the port is ready to accept new connections.

Configuring the Firewall:

If you have a working firewall setup, then you will have to allow access to the VirtualBox VM remote server port. On Ubuntu/Debian and many other Ubuntu/Debian based Linux distributions, the default firewall software is UFW.

On UFW, you can allow access to the TCP port 3389 (in my case) with the following command:

$ sudo ufw allow 3389/tcp

On CentOS/RHEL and many of the RPM based Linux distributions, the default firewall is Firewalld.

On Firewalld, you can allow access to the TCP port 3389 (in my case) with the following commands:

$ sudo firewall-cmd --add-port=3389/tcp --permanent
$ sudo firewall-cmd --reload

Remotely Accessing the VirtualBox VM:

In order to remotely access the VirtualBox VM, you need to know the IP address of the computer where VirtualBox is installed and the remote server port that the VM is listening to.

You can find the IP address of the computer where VirtualBox is installed with the following command:

$ ip a

In my case, the IP address is 192.168.20.143 and the VM remote server port is 3389. It will be different for you. So, make sure to replace it with yours from now on.

Once you know the IP address and VM server port, you can access the VirtualBox remotely from any remote desktop client that supports RDP protocol.

On Windows, you can use the default Remote Desktop Connection client to access the VirtualBox VM remotely over the RDP protocol.

Just open the Remote Desktop Connection client, type in the computer address in the format <IP_ADDRESS>:<PORT> and click on Connect.

Replace the <IP_ADDRESS> with the IP address of your computer where VirtualBox is installed and <PORT> with the VirtualBox VM server port.

In my case the computer address is 192.168.20.143:3389

Click on Yes.

You should be remotely connected to the VirtualBox VM (virtual machine). Now, you can remotely use the VirtualBox VM anyway you like.

On Linux, you can use the Remmina Remote Desktop Client to connect to the VirtualBox VM remotely.

Remmina may not be installed on your computer.

You can install Remmina on Ubuntu/Debian or any Ubuntu/Debian based Linux distributions with the following commands:

$ sudo apt update
$ sudo apt install -y remmina

Once Remmina Remote Desktop Client is installed, start it. Then, click on +.

Now, type in a Name for the remote connection, set the Protocol to RDP – Remote Desktop Protocol, type in the Server address and port in the format <IP_ADDRESS>:<PORT>, set the Resolution and Color depth settings etc.

Once you’re done, click on Save and Connect.

You should be connected to your desired VirtualBox VM remotely.

So, that’s how you set up VirtualBox VMs for remote connection over the RDP protocol and connect to VirtualBox VMs remotely. Thanks for reading this article.

]]>
How to Install VirtualBox on openSUSE https://linuxhint.com/install_virtualbox_opensuse/ Tue, 17 Dec 2019 16:56:46 +0000 https://linuxhint.com/?p=51892 Virtualization is an interesting technology that refers to the creation of a virtual resource (server, desktop, storage, file, network or storage). This is an interesting concept that drives a lot of today’s technological workloads. If you’re interested in having the experience of virtualization, VirtualBox is a great tool to start with.

This guide will showcase how to install and use VirtualBox on openSUSE.

Virtualization and VirtualBox

Here’s a quick example that implements virtualization. Did you ever try running Android on your PC? Android emulators are handy tools that allow running Android apps on your PC. Here, the emulator software creates a virtual machine on which the Android OS runs.

It’s an oversimplified workflow of how the Android emulators work. When you run any of those emulators, it allocates the existing hardware resource (CPU, GPU, RAM, and storage) to an Android OS and interfaces you with the virtual system. You have full control over how much CPU, GPU, RAM and storage it’ll consume.

Virtualization started early in the 1960s where the goal was to logically divide the hardware resource of mainframe computers to different apps. Here’s a short list where virtualization is currently used.

  • Memory virtualization is a useful technique for sharing RAM resources between all the virtualized systems from a single memory pool.
  • Storage virtualization abstracts logical storage from physical storage.
  • Storage virtualization is useful for abstracting the need of physical storage. The virtual disk is such an implementation where it’ll appear as if it’s a single disk irrespective of its physical location.
  • Desktop virtualization is such a technology that allows creating a logical desktop on top of a physical client device. This way, the hardware resource is more efficiently distributed. Android emulators can be an example of desktop virtualization.

In this article, we’ll be focusing on the last point because VirtualBox is such a tool that allows desktop virtualization on your PC.

Why use VirtualBox

The features of VirtualBox are useful in a number of situations. For example,

  • Running multiple OS: Using VirtualBox, you can run multiple machine with different OS at the same time. You can switch quickly from one OS to another seamlessly. You have full control over what “virtual” hardware each virtualized system gets.
  • Testing: Using VirtualBox, you can have a safe environment to test anything you want. As you’re making changes to the virtual systems, there’s no threat of breaking down your current system. Personally, I use VirtualBox for testing new Linux distros and trying out critical system tweaks.
  • Simplicity: Among all the virtualization tools out there, VirtualBox is one of the simplest ones to learn and master. While it’s not the best, it’s probably the easiest way to get accustomed to the world of virtualization. It’s free of cost and you can play around without breaking down your computer.
  • Easier deployment: Let’s take a complete mail server for example. Setting a mail server on a real machine is a tough job. However, it can be run directly from the virtual system without the need of making any changes to the host. VirtualBox allows exporting virtual machines. Thus, the machine can even be deployed without having to go through the installation again. For example, OSboxes is such a place where you can grab VirtualBox VDIs of different OS.

Installing VirtualBox on openSUSE

VirtualBox is directly available from the official repo of openSUSE. Run the following commands.

$ sudo zypper ref

$ sudo zypper in virtualbox virtualbox-qt

For using VirtualBox, the current user account has to be under the group “vboxusers”. We’ll be taking the help of YaST for this. Start YaST from the menu.

Enter the admin password.

From the YaST Control Center, go to Security and Users >> User and Group Management.

Select your user account from the list and click “Edit”.

Under the “Details” tab, check the “vboxusers” group under the section “Additional Groups”. Then, click “OK”.

To take the changes into effect, you need to log out and log in.

For unlocking the maximum features of VirtualBox, it’s also recommended to install the VirtualBox extension pack. Get VirtualBox Extension Pack.

Fire up VirtualBox.

At first, you’ll have this notification. Read it carefully and make sure that whether you want to enable or disable it.

This is the main window of VirtualBox.

For installing the VirtualBox Extension Pack, go to File >> Preferences.

From the left panel, select “Extensions”. Click the “+” icon. You’ll be prompted to select the location of the extension pack.

When selected, this VirtualBox “Question” dialog box will pop up. Click “Install”.

You’ll be prompted with the VirtualBox Extension Pack license agreement. Scroll to the bottom to agree with it.

The action will require “root” permission.

Once the installation is complete, the success message will pop up.

The extension pack will be added on the list of installed extensions.

VirtualBox terminology

Here are some of the common terminologies you’ll come across when dealing with VirtualBox and virtualization in general.

  • Host OS: By the term “host”, we refer to the machine on which VirtualBox is running. Thus, the term “host OS” refers to the operating system that’s running the machine. In the case of VirtualBox, it can be any supported OS, for example, Windows, Linux, and macOS etc.
    Interestingly, the “host” here can be physical/virtual.
  • Guest OS: By the term “guest” here, we regard to the machine that’s being virtualized. Thus, “guest OS” signifies the OS that’s running on top of the virtual machine. In theory, any x86-based OS will run on VirtualBox without any problem. In practice, however, not all will work properly.
  • Virtual machine (VM): This is the virtualized computer that’ll act as if it’s a physical machine. In this case, we’ll be using VirtualBox to create VMs. You can configure every single aspect of the VM, for example, memory (RAM), storage, CPU, and networking etc.
  • Guest additions: It’s a special package of drivers and software for the guest OS. Installing guest addition offers better integration with VirtualBox and unlock some interesting features.

Using VirtualBox

Let’s have a look at how to create a virtual machine using VirtualBox. From the main window, click “New”.

The first step is giving the virtual machine a proper name. Select the proper type of OS you’re going to run on that virtual system.

Next up, select the proper amount of RAM the virtual machine can use. This can be tricky as you have to offer enough memory to the guest OS while maintaining enough memory for the host OS to function properly.

It’s time to manage the virtual storage for the virtual machine. Select “Create a virtual hard disk now”.

There are 3 types of hard disk file types available to choose from. For VirtualBox, I recommend going with the VDI (VirtualBox Disk Image) type.

As of this step, “Dynamically allocated” means the virtual disk will expand gradually as it gets more loaded. On the other hand, “Fixed size” will allocate the fixed amount of storage directly from your storage.

Choose where you want to allocate the virtual storage. As of the storage size, it should be enough to run the guest OS while not clogging up your physical storage.

Voila! The virtual machine is ready to go! If you want to perform further customization, select the virtual machine, right-click and select “Settings”.

Final thoughts

VirtualBox is an incredibly powerful yet super-simplified virtualization tool. It’s also incredibly forgiving. Feel free to explore your way around it. We have plenty of VirtualBox tutorials.

Check out how to install Debian, CentOS, OpenStack, and FreeBSD on VirtualBox.

Enjoy!

]]>
Install VirtualBox 6 on CentOS 8 https://linuxhint.com/install_virtualbox6_centos8/ Sat, 19 Oct 2019 16:51:35 +0000 https://linuxhint.com/?p=48907 VirtualBox is an open source Type-II hypervisor from Oracle. It can be a great free alternative to VMware Workstation Pro.  In this article, I am going to show you how to install VirtualBox 6 on CentOS 8. So, let’s get started.

Enabling Hardware Virtualization Extension:

In order to install any type of hypervisor, you must enable hardware virtualization feature of your processor from the BIOS of your motherboard. Otherwise, your virtual machines will be very laggy and won’t perform as expected.

If you’re using an Intel processor, then the hardware virtualization feature is called VT-x or VT-d.

If you’re using an AMD processor, then the hardware virtualization feature is called AMD-v.

Once you enable hardware virtualization from the BIOS, start CentOS 8 and run the following command to confirm it.

$ grep --color --perl-regexp 'vmx|svm' /proc/cpuinfo

As you can see, svm (for AMD) is available as a CPU feature in my case. I am using an AMD processor.

If you’re using an Intel processor, then the CPU feature will be called vmx.

Installing Required Tools for Building VirtualBox Kernel Modules:

Your CentOS 8 machine must have all the required tools installed in order to build VirtualBox kernel modules. Otherwise, VirtualBox won’t work.

First, do a system update with the following command:

$ sudo yum update

To confirm the installation, press Y and then press <Enter>.

YUM will download and install all the required packages from the internet. It may take a while to complete.

At this point, the system update should be complete.

Now, reboot your CentOS 8 machine with the following command:

$ sudo reboot

Once your CentOS 8 machine starts, install ELF utils and kernel development libraries with the following command:

$ sudo yum install elfutils-libelf-devel kernel-devel-$(uname -r)

Press Y and then press <Enter> to confirm the installation.

ELF utils and kernel development libraries should be installed.

Downloading VirtualBox 6:

VirtualBox is not available in the official package repository of CentOS 8. But, you can easily download it from the official website of VirtualBox.

First, visit the official Linux download page of VirtualBox. Now, click on Oracle Linux 8 / Red Hat Enterprise Linux 8 / CentOS 8 link as marked in the screenshot below.

Your browser should prompt you to save the VirtualBox RPM package file. Select Save File and click on OK.

Your browser should start downloading VirtualBox RPM package file. It may take a while to complete.

Downloading VirtualBox 6 Extension Pack:

You should also download VirtualBox 8 Extension Pack.

First visit the official downloads page of VirtualBox. Then, click on All supported platforms link from the Oracle VM VirtualBox Extension Pack section as marked in the screenshot below.

Your browser should prompt you to save the file. Click on Save File.

Your browser should start downloading VirtualBox Extension Pack file. It may take a while to complete.

Installing VirtualBox 6:

Once the download is complete, navigate to the ~/Downloads directory as follows:

$ cd ~/Downloads

You should find the VirtualBox-6.0-6.0.14_133895_el8-1.x86_64.rpm and Oracle_VM_VirtualBox_Extension_Pack-6.0.14.vbox-extpack file in this directory as you can see in the screenshot below.

$ ls -lh

Now, install VirtualBox RPM package using YUM package manager as follows:

$ sudo yum localinstall VirtualBox-6.0-6.0.14_133895_el8-1.x86_64.rpm

To confirm the installation, press Y and then press <Enter>.

YUM package manager will automatically download all the required dependency packages and install VirtualBox. It may take a while to complete.

At this point, VirtualBox should be installed.

Now, to check whether VirtualBox is working correctly, run the following command:

$ VBoxManage --version

As you can see, I am using VirtualBox 6.0.14. So, it’s working just fine.

Fixing Error Building Kernel Module:

If you did not install all the required tools to build VirtualBox kernel modules, then you may see the following WARNING message when you try to run VBoxManage –version command.

To solve this, make sure you install all the required tools to build VirtualBox kernel modules (as shown in the Installing Required Tools for Building VirtualBox Kernel Modules section of this article) and then run the following command to manually build the VirtualBox kernel modules.

$ sudo /sbin/vboxconfig

The VirtualBox kernel modules should rebuilt.

Starting VirtualBox 6:

Now, you can find VirtualBox in the Application Menu of CentOS 8. Click on the VirtualBox icon.

VirtualBox 6 should start.

Installing VirtualBox 6 Extension Pack:

VirtualBox Extension Pack adds some new functionalities to VirtualBox. i.e,

  • USB 2.0 and USB 3.0 support
  • Access host webcam
  • VirtualBox RDP (Remote Desktop Protocol) server for accessing VMs over RDP.
  • PXE boot ROM
  • Disk encryption
  • NVMe virtual SSD

To install VirtualBox Extension Pack, go to File > Preferences…

Then, go to Extensions and click on the + icon as marked in the screenshot below.

Then, select VirtualBox Extension Pack file that you’ve downloaded and click on Open.

Now, click on Install.

Scroll down all the way and click on I Agree.

Type in your login password and click on Authenticate.

VirtualBox Extension Pack should be installed. Click on OK.

Now, click on OK.

That’s how you install VirtualBox 6 on CentOS 8. Thanks for reading this article.

]]>
Installing Virtual Box on Debian 10 https://linuxhint.com/install_virtualbox_debian_10/ Sat, 27 Jul 2019 04:20:43 +0000 https://linuxhint.com/?p=44204 VirtualBox is a free and open source virtualization solution from Oracle. VirtualBox is cross-platform. It runs on Windows, Linux, and macOS.

In this article, I am going to show you how to install VirtualBox on Debian 10. So, let’s get started.

Prerequisites:

Before you get started, you should enable hardware virtualization (AMD-v/VT-d/VT-x) extension from the BIOS of your motherboard. Otherwise, you won’t get very good performance in virtual machines.

Adding Oracle VirtualBox Package Repository:

VirtualBox 6.0 is the latest version of VirtualBox at the time of this writing. It is not available in the official package repository of Debian 10 Buster. But, you can easily add the Oracle VirtualBox package repository on Debian 10 and install VirtualBox 6.0 from there.

To add the Oracle VirtualBox package repository, run the following command:

$ echo 'deb https://download.virtualbox.org/virtualbox/debian buster contrib' |
 sudo tee /etc/apt/sources.list.d/virtualbox.list

The VirtualBox package repository should be added.

Adding GPG Key:

Now, download the GPG key of the Oracle VirtualBox package repository with the following command:

$ wget -O /tmp/oracle_vbox.asc https://www.virtualbox.org/download/oracle_vbox_2016.asc

The GPG key should be downloaded.

Now, add the GPG key to the APT package manager with the following command:

$ sudo apt-key add /tmp/oracle_vbox.asc

The GPG key should be added.

Updating APT Cache:

Now, update the APT package repository cache with the following command:

$ sudo apt update

The APT package repository cache should be updated.

Installing VirtualBox:

Now, you can install VirtualBox 6.0 with the following command:

$ sudo apt install virtualbox-6.0

Now, press Y and then press <Enter> to confirm the installation.

The APT package manager should download and install all the required packages.

VirtualBox 6.0 should be installed at this point.

Once VirtualBox 6.0 is installed, you should be able to find it in the Application Menu of Debian 10. Click on the VirtualBox logo.

VirtualBox should start.

Downloading VirtualBox Extension Pack:

VirtualBox Extension Pack adds features such as USB 2.0 and USB 3.0 support, RDP, disk encryption etc on top of VirtualBox. I highly recommend you download and install it for a smooth VirtualBox 6.0 experience.

First, you have to find out the full version number of VirtualBox.

You can find the full version number from the command line with the following command:

$ apt-cache show virtualbox-6.0 | grep Version

As you can see, the full version number of the VirtualBox installed on my computer is 6.0.10. Remember it.

You can also find the full version number from the VirtualBox Manager. Just open VirtualBox and go to Help > About VirtualBox…

As you can see, the full version number is 6.0.10

Now, visit the following webpage https://download.virtualbox.org/virtualbox/6.0.10

Once the page loads, click on the “Oracle_VM_VirtualBox_Extension_Pack-6.0.10.vbox-extpack” file as marked in the screenshot below.

NOTE: Replace 6.0.10 with the version you’ve installed on your Debian 10 machine.

Your browser should prompt you to save the file. Select Save File and click on OK.

The download should start. It may take a few minutes to complete.

Installing VirtualBox Extension Pack:

Once the download is completed, open VirtualBox and go to File > Preferences…

Now, go to the Extensions tab and click on the add icon as marked in the screenshot below.

Now, select the vbox-extpack file you just downloaded and click on Open.

Now, click on Install.

Read the VirtualBox License agreement if you wish and click on I Agree.

Now, type in the password of your Debian 10 login user and click on Authenticate.

VirtualBox Extension Pack should be installed. Now, click on OK.

Click on OK to close the Preferences window.

You’ve successfully installed VirtualBox 6.0 (the latest version at the time of this writing) on Debian 10 buster. Enjoy!

Thanks for reading this article.

]]>
Install VirtualBox 6.0 on Ubuntu 18.04 https://linuxhint.com/install_virtualbox_6_ubuntu/ Thu, 27 Dec 2018 02:43:26 +0000 https://linuxhint.com/?p=34542 VirtualBox is a free virtualization solution from Oracle. VirtualBox can virtualize Windows XP, Windows Vista, Windows 7, Windows 10, Ubuntu, Debian, CentOS and many other versions of Linux, Solaris, some BSD variants etc. Recently, VirtualBox 6.0, a major update of VirtualBox came out.  In this article, I will show you how to install VirtualBox 6.0 on Ubuntu 18.04 LTS. This article mainly focuses on Ubuntu 18.04 LTS, but this article will also work for Ubuntu 16.04 LTS and later. So, let’s get started.

Enable Hardware Virtualization:

Before you install VirtualBox 6.0, make sure hardware virtualization is enabled. If you’re using an Intel processor, then you have to enable VT-x or VT-d from the BIOS of your computer. If you’re using a AMD processor, then you have to enable AMD-v from the BIOS of your computer. This is very important. Without hardware virtualization enabled, your virtual machines will perform very badly.

Adding VirtualBox Package Repository:

VirtualBox 6.0 is not available in the official package repository of Ubuntu 18.04 LTS. But we can easily add the package repository of VirtualBox on Ubuntu 18.04 LTS and install VirtualBox 6.0 from there. To add the official package repository of VirtualBox, run the following command:

$ echo "deb https://download.virtualbox.org/virtualbox/debian $(lsb_release -cs) contrib"
| sudo tee /etc/apt/sources.list.d/virtualbox.list

Now, type in your login password and press <Enter>.

The official package repository of VirtualBox should be added.

Adding VirtualBox Public PGP Key:

Now, you have to add the public PGP key of VirtualBox official package repository to APT. Otherwise, you won’t be able to use the VirtualBox official package repository.  To add the public PGP key of the official package repository of VirtualBox, run the following command:

$ wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -

The public PGP Key should be added.

Installing VirtualBox 6.0:

Now that the official VirtualBox package repository is ready to use, we can install VirtualBox 6.0. First, update the APT package repository cache with the following command:

$ sudo apt update

The APT package repository should be updated.

Now, install VirtualBox 6.0 with the following command:

$ sudo apt install virtualbox-6.0

Now, press y and then press <Enter> to continue.

The required packages are being downloaded.

VirtualBox 6.0 should be installed.

Running VirtualBox 6.0:

Now, you should be able to run VirtualBox 6.0 from the Application Menu as you can see in the screenshot below.

VirtualBox 6.0 dashboard.

As you can see, I am currently running VirtualBox 6.0.0. Note the VirtualBox version because you will need it when you will install VirtualBox Extension Pack.

Installing VirtualBox Extension Pack:

VirtualBox Extension Pack enables support for USB 2.0 and USB 3.0 devices, RDP, disk encryption, NVMe and PXE boot for intel cards and many more. It is a must have tool for any VirtualBox user.

You have to download VirtualBox extension pack from the official website of VirtualBox and install it yourself in order to use these extra features in VirtualBox.  First, to visit the official FTP directory of VirtualBox at https://download.virtualbox.org/virtualbox/6.0.0

Once the page loads, click on the “Oracle_VM_VirtualBox_Extension_Pack-6.0.0.vbox-extpack” file as marked in the screenshot below.

NOTE: Here, 6.0.0 is the version of the VirtualBox you installed. If it’s different for you, then replace 6.0.0 in the URL with the version you have.

Your browser should prompt you to save the file. Select Save File and click on OK.

Your download should start.

Once the download is complete, start VirtualBox 6.0 and go to File > Preferences…

Now, go to the Extensions tab.

From the Extensions tab, click on the add icon as marked in the screenshot below.

A file picker should be opened. Now, select the VirtualBox Extension Pack file you just downloaded and click on Open.

Now, click on Install.

Now, you have to accept the VirtualBox License. To do that, scroll down and click on I Agree.

You need super user privileges in order to install VirtualBox Extension Pack. Type in the password for your login user and click on Authenticate.

VirtualBox Extension Pack should be installed.

Finally, click on OK.

Now, you can start using VirtualBox 6.0 to create and run virtual machines of your favorite operating systems. So, that’s how you install VirtualBox 6.0 on Ubuntu 18.04 LTS. Thanks for reading this article.

]]>
Install VirtualBox 6.0 on CentOS 7 https://linuxhint.com/install_virtualbox_6_centos/ Thu, 27 Dec 2018 02:41:49 +0000 https://linuxhint.com/?p=34478 VirtualBox is one of the best free virtualization software package that you can use to virtualize different operating systems. VirtualBox has simple and easy to use user interface. So, VirtualBox is a great choice for people who don’t have much experience on virtualization. It’s very beginner friendly.

Recently, VirtualBox 6.0 came out. Which is a major update to VirtualBox 5.2. In this article, I will show you how to install VirtualBox 6.0 on CentOS 7. So, let’s get started.

Enabling Hardware Virtualization:

Before you start installing VirtualBox, make sure AMD-v or VT-x/VT-d is enabled from the BIOS of your computer. Otherwise, your virtual machines will not perform as expected. It will lag and hurt your workflow.

Adding VirtualBox Package Repository:

VirtualBox 6.0 is not available in the official package repository of CentOS 7. But we can easily add the official VirtualBox package repository on CentOS 7 and install VirtualBox 6.0 from there.

First, navigate to the /etc/yum.repos.d directory with the following command:

$ cd /etc/yum.repos.d

Now, download the virtualbox.repo file and save it to the /etc/yum.repos.d directory with the following command:

$ sudo wget https://download.virtualbox.org/virtualbox/rpm/el/virtualbox.repo

The VirtualBox repository file should be downloaded.

As you can see, a new file virtualbox.repo is created.

Updating YUM Package Repository Cache:

Now, you have to update the YUM package repository cache.

To do that, run the following command:

$ sudo yum makecache

Now, press y and then press <Enter>.

The YUM package repository cache should be updated.

Upgrading Kernel:

Now, you have to update the kernel of CentOS 7. Otherwise, VirtualBox 6.0 kernel module won’t compile correctly. Currently, I am using kernel 3.10.0-693 as you can see in the screenshot below.

To update the kernel, run the following command:

$ sudo yum install kernel

Now, press y and then press <Enter> to continue.

The required packages should be downloaded and installed.

The kernel should be updated at this point.

Now, run the following command to reboot your CentOS 7 machine.

$ sudo reboot

Once your computer starts, it should start using the updated kernel as you can see in the screenshot below.

Installing Dependency Packages:

Now, you have to install some perquisite packages required to build the VirtualBox 6.0 kernel module. To install the required kernel headers and GCC compilers, run the following command:

$ sudo yum install gcc perl make kernel-devel kernel-devel-$(uname -r)

Now, press y and then press <Enter>.

The required packages should be downloaded and installed.

You may be asked to confirm the GPG keys. Just press y and then press <Enter> to continue.

The required packages should be installed.

Installing VirtualBox 6.0:

Now, you can install VirtualBox 6.0 on your CentOS 7 machine with the following command:

$ sudo yum install VirtualBox-6.0

Press y and then press <Enter>.

The required packages should be downloaded and installed.

If you are asked to confirm the GPG key, then just press y and then press <Enter>.

VirtualBox 6.0 should be installed.

Starting VirtualBox:

Now, that VirtualBox 6.0 is installed, you can start VirtualBox 6.0 from the Applications Menu as follows.

As you can see, VirtualBox has started.

I am running VirtualBox version 6.0.0. It may be different for you at the time you read this article. Note the version number as you will need it when you download the VirtualBox Extension Pack.

Installing VirtualBox Extension Pack:

VirtualBox Extension Pack enables support for USB 2.0 and USB 3.0 devices, RDP, disk encryption, NVMe and PXE boot for intel cards and many more.  If you need these features, then you have to download VirtualBox extension pack for the VirtualBox version you installed from the official website of VirtualBox and install it.

First, to visit the official FTP directory of VirtualBox at https://download.virtualbox.org/virtualbox/6.0.0

Once the page loads, click on the “Oracle_VM_VirtualBox_Extension_Pack-6.0.0.vbox-extpack” file as

marked in the screenshot below.

NOTE: Here, 6.0.0 is the version of the VirtualBox you installed. If it’s different for you, then replace

6.0.0 in the URL with the version you have.

Now, select Save File and click on OK.

VirtualBox Extension Pack should be downloaded.

Now, from VirtualBox 6.0, go to File > Preferences… as marked in the screenshot below.

Click on the Extensions tab.

Now, from the Extensions tab, click on the Add icon as marked in the screenshot below.

A file picker should be opened. Now, select the VirtualBox Extension Pack file you just downloaded and click on Open as marked in the screenshot below.

Now, click on Install.

Now, you have to accept the VirtualBox License. To do that, scroll down to the end of the license and click on I Agree.

You need super user privileges in order to install VirtualBox Extension Pack. Just, type in your login password and press <Enter>.

VirtualBox Extension Pack should be installed. Now, click on OK.

Click on OK.

Now, you can start creating virtual machines with VirtualBox 6.0.

So, that’s how you install VirtualBox 6.0 on CentOS 7. Thanks for reading this article.

]]>
How to SSH into your VirtualBox Guest https://linuxhint.com/ssh_virtualbox_guest/ Wed, 20 Jun 2018 03:01:22 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=27416 There are times when you want to have a remote access to your VM. Maybe, it’s just a server operating system running as a VM, where you test your applications before actually deploying them.

Having the capability to SSH into your Guest OS can come in handy when you don’t want to use the GUI of your Virtual Machine. Simply start your VM in a headless mode and SSH in and out of it without having multiple windows open in your terminal.

For those who are new to the idea of SSH, we will have a short introduction to the workings of SSH before diving into the setup. Also we would need to discuss the network related settings of your VM to make sure you have access to that VM from anywhere in your LAN.

How SSH-keys works?

Here’s simplified model of how SSH works. You create a pair of keys on your local computer. A public key and a private key. Messages encrypted using Public key can be decrypted using the private key and vice versa. These keys are usually stored on your local computer at a path ~/.ssh/id_rsa(private key) and~/.ssh/id_rsa.pem(the public key).

You then go to your remote server, login to a console as a regular or root user, open up the file ~/.ssh/authorized_keysof that server. Here you enter the contents of your public key as it is. Once that is done, you can ssh as that user on the server whose .ssh directory has the authorized_keys, from your local device.

The .pem extension signifies that that file is the public key that you can share with anyone. The id_rsa part  just signifies what encryption cipher is being used (in this case it happens to be RSA). The private key can further be protected by a passphrase which you would have to enter, everytime you want to login to a remote server using that private key.

If you have a Mac, Linux or any other UNIX-like system as your local computer you can generate and manage keys using terminal, and you can also SSH into remote servers using the same terminal. For Windows users, I’d suggest use PuTTY or Git Bash the latter being my personal preference. The commands are pretty much the same once you have an SSH client.

SSH-keys Setup

First make sure, if there are no ssh-keys already in your home directory. Check the contents of your home directory’s .ssh folder. If in doubt, back up its contents before executing the following command. Programs like Filezilla use SSH keys all the time, without the user’s knowledge so this step is rather crucial.

In your local machine, open the terminal and enter the command:

$ ssh-keygen

This will be followed up by the following prompts with values in bracket indicating the default values. Proceed with the prompts and give your keys a secure passphrase.

Verify that the keys are created by checking the contents of your ~/.ssh folder.

$ ls -al ~/.ssh

If you see files matching the default values displayed in the ssh-keygen prompt then everything has worked fine.

Now open up a console to your Virtual Machine. First check if your VM has SSH server running or not.

$ service sshd status

If it is not installed, use your package manager to search and install OpenSSH server. Once that is done make sure that your VM’s firewall is open on port number 22. For example, if you are using Ubuntu as a VM, the default firewall ufw should either be disabled or should allow port 22 connections like so:

$ sudo ufw status

If if is not open at port 22, use the follow command:

$ sudo ufw allow ssh

Next open up the file ~/.ssh/authorized_keys  on your VM, using your favorite text editor. You may want to enable host-to-guest or bidirectional clipboard for this next step.

Inside this file (at the bottom of the file, if it is not empty) paste in the contents of your public key. The last part where it says your name and the local host where the keys were generated is not that important as the rest of the string.

(Optional) Not using SSH-keys

If you trust your local network, then you can use the less secure method of using your UNIX password, to ssh into your VM. Open up the file /etc/ssh/sshd_config on your VM and replace the line:

#PasswordAuthentication no

To

PasswordAuthentication yes

Once that is in place, restart your SSH server.

$ service sshd restart

Now you can use the regular password that you use to login to your VM to ssh into it as well.

Your Virtual Machine and Network

For you to ssh into your VM, both your local computer (the one with the private key) and the VM should be on the same network. So you can reach to that VM’s IP address. We will show you how to add the VM to your LAN.

Let’s consider the example of a typical home router setup. Your computer, along with other devices, is connected to the home router. This router also acts as a DHCP server, meaning it assigns each device that’s connected to it, a unique private IP address. Your desktop gets an IP, so does your phone and your laptop. Only the devices that are connected to this router can talk to one another via their IP addresses.

Enable bridged networking mode in the settings of your VM and the VM will show up as being connected to your home router (or a similar DHCP server) with a private IP. If a second device is connected to the same network (say, to the same home router) then it can be used to ssh into the VM.

Open VirtualBox Manager, select your target VM, open up the Settings → Network and select Bridge Networking instead of NAT.

As you can see my host is connected using Wireless so that connection is also shared by the VM, if you are using Ethernet, a different interface name would show up which is fine.

Now, my VM, which is named ubuntuvm, shows up on my LAN setup as following. Check your router settings to see if the same works for you.

Once you know the IP address of your VM, you can SSH into it by running the command:

$ ssh <username>@ip.address.of.your.vm

If you have put a passphrase for your private key in the above steps, you would be prompted to re-enter it.

That’s it! Now you can start your VMs in headless mode and just ssh into them from anywhere in your house. Hope you found this tutorial interesting, let us know if there’s any topic you would want us to cover.

]]>
Install VirtualBox Extension Pack https://linuxhint.com/install_virtualbox_extension_pack/ Mon, 04 Jun 2018 02:41:32 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=27044 A lot of features offered by Oracle (the company that owns VirtualBox) are offered under a separate license from that of the core VirtualBox software. The latter is released under GPL version 2 which is doesn’t allow the former to come preinstalled alongside VirtualBox core package. Which is why you need to install the VirtualBox extension pack and agree to a different license in order to use it.

Functionalities such as USB 2.0 and 3.0 support, full disk encryption for your virtual disk images and even physical disk passthrough are available within this pack. A few extra functionalities include NVMe support, Remote Desktop and PXE boot for Intel chips.

Installation

To get your copy of the extension pack, visit the official VirtualBox site and scroll down to the Oracle section and download the extension pack for your running version of VirtualBox. Click on “All supported platforms” to get this file.

The file is about 20 MB in size and has the extension .vbox-extpack which is the same exact file for any host operating system be it Windows, Linux or macOS.

Once the file is downloaded, open up your VirtualBox manager, from the top menu select File → Preferences (Top-left corner) and a new VirtualBox Preferences window will pop up.

In this Window, select the Extensions option from the left-side menu.

Use the icon on the right side which has a plus sign on it, to open File explorer and locate the Extension pack that we downloaded earlier, in your filesystem. Most likely, it is in your Downloads folder. Upon selecting and clicking OK, you will be informed that some of the system level software can harm your computer if they are untrusted.

Since we obtained our extension pack from the official website, it is quite safe to install it. Click install and then Agree to the terms and services if you would like to use the extension pack.

You will  then be prompted for your root or sudo password (for Linux users) and Windows users will be greeted by a familiar UAC prompt. In either case, give VirtualBox the permission to install the necessary packages.

Once the extension pack is installed, your Preferences → Extension window will show something like this.

Testing out New Features

Let’s start using a few of the features that we now have at our disposal.

1.  Full Disk Encryption

First and foremost would be full disk encryption. This is one of the best ways to ensure that your data inside the VM stays safe from the host.

There are cases where you may not trust the host operating system with your data or privacy, for example, if you are using a company laptop or some obscure OS with un-audited source code. Having your personal data inside a VM doesn’t help very much, unless you have the entire disk encrypted, in which case, the host has fewer ways of getting that information.

To enable disk encryption select your virtual machine from the VirtualBox manager, right click and go to its settings. In the General settings you would notice that the Disk Encryption option is available. Enable it and select any of the cipher that you prefer and then set your password. Once that is done, click OK and it will encrypt the entire .vdi (virtual disk image) file where your OS resides. You can do this while creating a new VM or for your pre-existing VMs as well.

Depending on the actual size of the virtual disk it might take some time. Now everytime you boot your VM, you will be asked for a passphrase:

If you are already using full disk encryption from inside the VM, then this might not be necessary. But, of course, encrypting your disks in this way secures it against vulnerabilities in guest operating system as well.

2.  USB 2.0 devices

If you have some data on a USB device and you want to transfer it to your VM, you would typically do that by copying the data to the host machine and then copy the data from there to the guest machine. You may also try using a shared folder to speed up the process, but there will be copying of data involved.

Wouldn’t it be nice if you can just plug your USB device directly into your VM? Well this can be easily achieved once your extension packs are installed. Just go to your VM’s settings as before, and select USB menu from the sidebar.

Settings → USB

Select the kind of controller that your hardware offers. It can be USB 2.0 or USB 3.0. USB ports are backwards compatible so if you select 3.0 and use a 2.0 device that would still work.

You need not select any USB filtering for now, if you are just experimenting, but I urge you to explore further into it.Things can turn ugly if you select the wrong USB device. For example if your USB mouse is selected to be passed through to the VM, then your host machine, your main computer, has no mouse connected to it!

So for now, we shall leave the filtering part untouched and boot our VM, And once again use the Device option from the menu, go to USB option and select the USB device fitting the description of, say, our flash drive, as shown below.

Once you select that, you will notice that a new media is mounted inside the guest operating system which contains all the data held by your flash device.

Once again, your host operating system will have no idea about the existence of this flash device plugged into its hardware. Your VM would have taken control of the USB interface completely.

Removing Extension Pack

To ensure that removing the extension pack doesn’t break any of your VM, make sure that none of the feature like disk encryption or USB passthrough are actively being used.

With USB devices it is a simple matter of powering down all your VMs and none would use any physical interface avaible to them. With disk encryption, however, it is recommended that you go back to the Settings → General → Disk Encryption and uncheck the Enable Disk Encryption option. This is because your data is encrypted even at rest (on your hard disk) and if you remove the extension pack you have no way of decrypting it unless you reinstall the pack.

Once you are sure that none of the extension features are actively in use, you can go to VirtualBox Manger’s File → Preferences –> Extension.

Then click on the red icon on the right-column and you are back to the vanilla VirtualBox environment.

Hope you found this article on VirtualBox extension pack helpful, informative and fun! Please let us know if there’s any Linux related topic that you might want us to cover. You can reach us on Twitter, Facebook or subscribe to us via email.

]]>
VirtualBox Shared Folders https://linuxhint.com/virtualbox_shared_folders/ Sun, 03 Jun 2018 07:43:58 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=27021

Setting up Shared folders in VirtualBox 

If you have virtual machines installed inside VirtualBox, chances are you wish to share data between the VM and the host operating system. VirtualBox’s Shared Folder feature enables you to share a folder between your host operating system and the guest operating system.

We will be using a Windows 10 host system and share a folder with Ubuntu 18.04 as guest. Everything from read and write permissions to volume management is surprisingly easy and simple to set up in either cases. A linux and a non-linux OS offers a nice generality too, making the following steps widely applicable.

We will be sharing a folder named D:\VboxShare from the host system with the same name on the guest for the sake of simplicity. You can have the shared folder show up with a different name on your guest OS, if you like.

Start your VM and click on Devices options on the VirtualBox window, top row.

In the bottom of the Devices submenu you will get an option saying Insert Guest Additions CD Image… click on it and it will mount an iso file provided by Oracle to extend the capabilities of the VM, including the Shared Folder feature.

Upon clicking, one of two things may happen. If you are using stock Ubuntu, you will be prompted that there’s an autorun.sh script inside the CD image and it requires your sudo password to execute or you may notice just a CD image being mounted on your file system, in which case please see the note below.

Coming back to the ideal case where the autorun.sh script starts on its own, in that case you would need to allow your guest OS to run the script. Click on “Run” when the following window pops up:

You can go ahead and give in your sudo password when you see this prompt:

Finally, you will see the result of the installation (this will only take a few seconds) :

You will notice that the script asks you to install gcc, make and perl so it can install necessary kernel modules. We will do that next.

Note: If the autoinstallation prompt doesn’t show up

Chances are that you are using a distribution like Lubuntu, and you will notice a new CD image being mounted on the path /media/<yourUsername>/Vbox_GA_version_number where the version number would depend on the version of VirtualBox. This CD image may also show up on your desktop screen. If that happens simply open up the terminal, traverse to that directory and run the autorun.sh script as root user. To do that use the following commands:

$ cd /<username>/media/VBox_GAs_5.2.12
$ sudo ./autorun.sh

Of course, you would need to use your username instead of the <username> shown in the command. Also the mounted media /VBox_GAs_x.x.xx will have different name depending on what version of VirtualBox you are using.

Back to installation

Now it’s time to ensure that the Guest Addition software has all the necessary base packages to install kernel modules on the guest OS. As mentioned earlier, these packages are make, gcc and perl. Let’s install them.

$ sudo apt install gcc make perl

Now, as a final point of minutiae, you need to understand that the files shared by VirtualBox can only be access by members of  vboxsf group created by the earlier by the autorun.sh script. To make those files accessible to your regular UNIX user account, that account needs to be a member of the vboxsf group. Make that happen by running the command:

$ sudo adduser <username> vboxsf

Adding the Shared Folder

We are now ready to share folders from the host machine. To do that click on Devices, again, from the VirtualBox menu option of the VM window. (Top row, outside the VM)

You will see the following options there, Devices  → Shared Folders → Shared Folder Settings …

Upon clicking on it you will see something similar to this:

Click on the first folder icon on the right most column. Then enter the path to that folder as seen from your host operating system. In our case, it is a Folder in D: drive. Then Folder Name variable will decide what name that shared folder will have inside the VM. You may also want to select Auto-mount option so that the folder is mounted without manual intervention. Making it a permanent member would ensure that you have the sharing enabled every time you boot that VM.

If the data in the folder is sensitive, or if you use your VM for testing malicious software, you might want to select Read-only option as well. In doing so, you ensure that the VM can’t modify the contents of the folder.

Now we reboot our system so that all the modification we made in the last few steps would actually show up as a Shared Folder on our User’s desktop (or at /media/<sf_VBoxShare)

Conclusion

Let us know if there are any other bugs, issues or set up in your shared folders. If there’s an edge case that you want us to cover of if you still have some lingering doubts about the steps covered above.

You can reach us on Twitter, Facebook or subscribe to us via email. ]]> VirtualBox for Beginners https://linuxhint.com/virtualbox_beginners/ Sun, 03 Jun 2018 07:30:44 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=26991

VirtualBox: Beginners Guide and How to Setup Ubuntu Virtual Machine


What is VirtualBox?

 VirtualBox (VB) is a cross-platform hypervisor or virtualization software developed by Oracle Corporation. Basically VB allows user to run guest operating system on another host operating system virtually without need for partitioning of hard drive or running another OS on dual boot which involves risk of crashing the host system.

What VirtualBox actually does is that it creates virtual hard drive and installs guest OS on it. Virtual hard drive is nothing but a big size file stored on the computer hard drive. This file works as a real hard drive for the guest OS.

Running any application software or video game on virtual machines is sometimes not as smooth as running them on an OS installed on full hardware. Everything depends on amount of hardware resource allocated to virtual machine.

Why to use VB?

I know many of us have heard of VirtualBox but always been shy of trying or using it just because we think it is a messy task to setup a Virtual Machine and it might harm our whole computer system. But it is the misconception because setting up virtual machines is an easy task and it won’t affect your computer system if you set it up correctly. We will find how to do that in later part of the article.

  • VirtualBox can be very useful for people like me who always like to try and mess with different application software’s and operating systems.
  • It can also be a very useful tool for application developers who can test their application on different platforms before releasing it for general public.
  • Software reviewers like me can also use this to try and test software’s on different platforms under one single window.

Installation

First of all head over to downloads page on VirtualBox’s official website and download the installation package depending on your operating system. As I am going to install VB on Windows I will select Windows.

Once the downloading is complete run the installation file and follow the steps as the installer guides you through installation process.

You don’t need to change anything during installation so just click Next every time it asks for and finish the installation.

Once the installation is complete start the VirtualBox from the desktop or Start Menu and you will see home screen will appear as shown below.

Setting Up VirtualBox for Ubuntu Installation

Now we will see how to setup Virtual Machine for installing Ubuntu on VirtualBox. You can follow these steps to install Windows 10, Mac OS and others too.

Create Virtual Machine

To start, click on the New button on the top of VirtualBox’s home screen. Then Create Virtual Machine window will appear where you will have to give Virtual Machine a name like I have given it Ubuntu 18.04, then select type and version of operating system you are going to install.

I am going to install Ubuntu 18.04 LTS (Long Term Support) edition is which is 64-bit operating system.

RAM Allocation

Click Next, then you will be asked for RAM allocation. Always remember new allocate more than half of your total RAM memory else it will affect your computers performance and in some cases it might crash host system.

I have total 4GB of RAM, so I will allocate 2GB i.e. 2048MB which should be enough to run Ubuntu. Again click Next, then it will ask you to create Virtual Hard Disk.

Set Up Virtual Hard Disk

Now you will need to create Virtual Hard Disk to store VM data. Just select Create a virtual hard disk now option and click on Create button.

On the next screen you will be asked whether to create a dynamically allocated or fixed size hard disk. If you want VM to always perform smoothly then you should select fixed size where you will have to set size of the hard disk but it will consume more disk space for better performance.

With dynamically allocated disk, you’ll have to set maximum disk size but file will not consume more than allocated disk space. If you want VM with high performance then you are recommended to select Fixed size and then click Next.

Then you will need to select the size of virtual hard disk. Selecting disk size always depends on how you are going to use VM. If you are going to install lot of applications on Ubuntu for various purposes then you will need to allocate at least 25GB of disk space else you can allocate less space too.

Then finally click on Create and you are ready to install Ubuntu on Virtual Machine.

As shown in above screenshot you can see Ubuntu VM is added on VirtualBox.

Before we start Ubuntu installation we need to tweak some settings to ensure Ubuntu VM performs at its best.

Click on Settings button then following window will appear. Head over to Processor tab under System menu. Here increase Processors value to 2 and click OK.

Now select Motherboard tab where under Boot Order you will notice Floppy set on highest priority. Now unselect Floppy and move Optical to top using Arrow button. Set the priority for Optical and Hard Disk as shown in below screenshot.

Then select Display menu, here under Screen tab you will have to allocate full Video Memory i.e. 128MB. Also mark the checkbox next to Enable 3D Acceleration and Enable 2D Video Acceleration.

Now we will mount .iso file for Ubuntu installation. To do that, go to Storage menu where you will notice Empty disk under Controller: IDE, select Empty.

Besides that from the Optical Drive drop down click on Choose Virtual Optical Disk File and find your Ubuntu installation file.

You can download Ubuntu installation .iso file from here.

Now you can see VBoxGuestAdditions.iso disk is created in place of Empty disk. Finally click OK and you are good to go with Ubuntu installation.

Now we will start with Ubuntu installation. This process is not any different to normal OS installation we do using installation media or bootable pen drive.

To start, click on the Start button on VirtualBox home screen. This will initiate the first boot of Ubuntu.

Next you will be asked to Try Ubuntu or Install Ubuntu. You just need to click on Install Ubuntu.

On next screen you need to select your preferred language and head over to next screen which is Updates and Other Software, just select Normal Installation and click on Continue button.

Next select your time zone and on the next screen you will be asked to provide user details. Insert the details and click on Continue.

Now Ubuntu installation will start, wait for installation to complete.

Once the installation is complete you will be asked to restart the computer. Just click on the Restart Now button and VB will do the rest.

That’s it Ubuntu is installed successfully on Virtual Machine.

Install Guest Additions

To enable all the features of VirtualBox you need to install the Guest Additions in Ubuntu. Select Devices tab from VirtualBox’s window and click on Insert Guest Additions CD image.

Prompt will appear on Ubuntu screen asking you Would you like to run it?

Click Run and enter password to Authenticate. Then Terminal window will open up and it will perform some installation automatically.

When you will see Press Return to close this window… press Enter to finish the setup.

That’s it, you are done with all the setup and now you can enjoy Ubuntu inside your Windows.

Thank you for going through our guide to setup VirtualBox. You can always share your views @LinuxHint.

]]>
Increase VirtualBox Disk Size https://linuxhint.com/increase-virtualbox-disk-size/ Tue, 27 Feb 2018 19:19:49 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=23131 Virtual machines are some of the most important tools in an IT professional’s tool-kit. You can test unknown software, understand how the system works and even fiddle with the kernel from time to time. The only problem is storage. Different versions of packages and orphaned packages keep piling up, log files grow larger and larger with time and soon enough you need more storage.In this tutorial we will see how to grow the size of your virtual machine’s virtual disk in a clean and efficient way.

We shall be using VirtualBox version 5.2.6, if yours is older than that then you may want to update it. There are a few important details changed in the UI in this release and you may have difficulty in following them if your version is a bit older.

Logical Volume Manager, or LVM, makes the matter a little more intricate but that’s fine, we will handle that case as well in this tutorial.

Linux guest without using LVM

The first thing to do when resizing a disk is to get the correct disk name which you will be modifying. From the VirtualBox dashboard go to the VM that you wish to enlarge. Make sure that the machine is in Powered Off state.

  1. Select the machine from the left corner under its storage menu get the name of the virtual disk on which the operating system is installed. In our case the disk is named vdi (Normal 20.00GB).
  2. Now click on the Global Tools button on the top-right corner of the dashboard.
  3. You can see a lot of virtual disks listed in the section. The one that interests us is Ubuntu.vdi as we learned in Step-1. Select the appropriate disk name that your VM uses and adjust its size to the value you desire. We will be increasing its size from 20GB to 40GB. Click apply before going back to Machine Tools.
  4. Now we can start the VM and have a look at the guest operating system. Start the VM, login, open the terminal and enter:
    $df –h

    The available space for the root filesystem is not showing any increase in storage space. To understand why you can run the following command to list all the storage block devices attached to the VM:

    $lsblk

    There’s a block device sda, 40G in size which is of the type It has been partitioned into sda1, of size 20G (on top of which sits the root filesystem) and the rest is unallocated. The /(root) partition is the one that is supposed to grow in our case. There’s also the swap partition sda2. To resize the root partition it is safer for us to turn off the Virtual Machine.

  5. To grow the root filesystem, we will be using gparted utility. Download the .iso file from the link. Next we need gparted to modify our virtual disk vdi.
  6. Go back to the VirtualBox dashboard, right-click on the VM, select Settings and select Storage from the Settings window’s left column.Under the IDE controller, you can see that there is no optical disk attached. You can click where it says Empty, click on CD icon on the extreme right (under Attributes section), select the gparted iso file and mount it under the Controller: IDE.
  7. In the Settings section for your VM go to System and check that the Optical Disk is on top of Hard Disk in boot order. This ensures that the gparted.iso boots instead of the de facto OS.
  8. Now start the VM again, and you will get into the gparted GUI after selecting your preferred language and keymapping. Click on gparted application presented on the desktop.This is where a lot of things would differ for different people. In the above case, we have just one main partition for /(root) mounted on sda1. You may have a different filesystem to grow and you would have to increase the size of corresponding partition. The case above works for the default installation of Ubuntu 16.04 LTS.
  9. The swap partition is between the main partition and the unallocated space and needs to be deleted. If there are any other filesystems like /home mounted in between, don’t delete it! You may end up losing important data. Consider creating a new partition for the unallocated space, if that’s the case. Here’s how it appears when we resized our root partition.
  10. Swap partition is deleted by deleting sda5 and then sda2 and then clicking on apply button. Now you are free to resize the root partition all the way to the end but do leave a few gigabytes in the end for swap partition. Click Apply once you are happy with the way the partitioning is done.That’s it! Now, upon rebooting the system you will notice that the VM’s filesystem have more space available for you to work with.

Linux guests using LVM

If the guest operating system is using LVM then we need to modify a couple of steps. First of all, when you are in the gparted UI, you would notice that there’s a lock icon next to the LVM paritions. Right-click on those partitions and select the deactivate option to enable resizing them.

Reboot the system and open terminal once you have grown the desired partitions.

The next thing to do is to make the lvm partitioning scheme aware of the changes made. As the root user, run the command below to see the list of physical volumes available:

$pvs

You can see that there’s 20G of space made newly available to the physical volume /dev/sda5 to grow the physical volume run:

$pvresize /dev/sda5

Let’s have a look at the block devices now.

$lsblk

Running lsblk shows that the root partition is still occupying only 17.5G whereas there’s 39.5G on the partition sda5. This is because our physical partition has grown but the logical volume manager is not aware of this.

Also make note of the volume’s name which is mounted on /(root) directory. In the above output it is named as ubuntu--lvm--vg-swap_1

To make use of the entire available free space, run the command below, you may want to click on tab after /dev/ubuntu… to get to the appropriate device node:

$lvextend -l+100%FREE /dev/ubuntuServer-vg/root

Make these couple of changes if you are an LVM users and if you are installing a new guest OS, try to avoid LVM if you can.

]]>
Take and Restore VirtualBox Snapshots https://linuxhint.com/take-restore-virtualbox-snapshots/ Tue, 27 Feb 2018 18:53:36 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=23122

VirtualBox: Taking and restoring snapshots

Virtual machines are an excellent place for people to experiment. To run malicious software, test new code or to just understand the system better. If anything goes wrong, the damage is contained within the confines of the virtual machine which you can dispose of and start afresh. But why stop there when you can do much better.

With snapshots you can record the state of a system at a given time, run your tests and if things don’t go the way you wanted them to go, you can always revert back to that previous point where the system was all well and good.

Let’s take a dive into snapshots, how to recover from a system’s failure by restoring a snapshot and understanding what’s backed up and what’s not.

Taking a new Snapshot

Say, you have a freshly installed VM of Ubuntu with just the default packages which are all up-to-date. To label this state from within the VM, let’s login and in our home directory make create an empty file named ImportantFile.

$ touch ImportantFile

Now let’s power off the VM and go back to the VirtualBox dashboard. From the left column select the VM that you want to take a snapshot of.

In our example, that VM is named ubuntu.

With the VM selected, click on the top right corner option which says snapshots. Select current state and click on the icon that says “Take”, it takes the snapshot. Give your snapshot an appropriate name and then let’s start the VM and make some changes.

Restoring a Snapshot

Suppose you accidentally deleted the ImportantFile or made some other changes in the filesystem elsewhere and you would want to restore the initial state. In the directory where you created the file try running:

$rm ImportantFile

Now you have lost ImportantFile. To recover, you simply need to go back to the snapshots section in the VirtualBox UI, as shown before, select the snapshot and click restore. It will prompt you to take a new snapshot of the current state of the VM, if you think that’s important for you, you can do that as well.

That’s it! If you go back to the VM, you will see your ImportantFile is right there, exactly as it was before the disastrous rm command was run.

Additional features of a Snapshot

Fortunately for us the Snapshot functionality of the VM is not limited to just the data stored on a virtual disk. It also keeps track of the hardware related settings like what was the memory allocated in this snapshot, how many processor cores were allocated and what type of network interface was used.

If you take a snapshot, make changes in these setting and then you restore the previous state of the VM you will notice that not only the data on your virtual disk has been restored but other resources have also gone back to their previous state.

The same rule applies when you attach multiple virtual disks to the same VM. They restore their states and if you have added new disks that weren’t there before, they get detached from the VM once it is restored.

Note: Although it is possible to attach the same disk to multiple VMs, it is not a good idea to do so. VirtualBox doesn’t let you create a new snapshot if a disk is attached to multiple VMs simultaneously.

If you want to locate and get rid of these orphaned disks you can always do that going to “Global Tools” and seeing the details of each disk and deleting the ones that are not needed.

Snapshots folder

If you have multiple VMs and multiple snapshots of each of them it is easy to end up with many large files strewn all over your host system without you knowing which ones are important and which ones are not.

When creating a new VM you get an option to select a different directory or folder in which your disk images will be stored. This is particularly helpful if people don’t want to clutter up their C: drive or your /opt directory, if they are on Linux.

Click on the file icon or directly enter the destination path for your virtual disk when creating a new VM.

But when it comes to storing and managing snapshots, VirtualBox forgets this choice and reverts back to its default. To override this, go to your VM’s settings and click on ‘General’ and then select ‘Advanced’ tab in the menu:

Now you can add your custom destination in the Snapshot Folder section and make the entire rigmarole much more manageable.

]]> How to Install VirtualBox on Ubuntu 20.04 https://linuxhint.com/install-virtualbox-linux/ Wed, 19 Jul 2017 22:40:12 +0000 http://sysads.co.uk/?p=16021

VirtualBox is a popular open-source multi-platform virtualization application developed by Oracle. VirtualBox is used for installing and running multiple operating systems at the same time inside of a virtually created machine. Mostly, VirtualBox is used for testing and development purposes.

Installing VirtualBox on Ubuntu 20.04

This tutorial covers the following two methods for installing VirtualBox on Ubuntu 20.04:

  • From the official Ubuntu APT package repository
  • From the official Oracle repositories

Method 1: Install VirtualBox Using the APT Package Repository

In this method, we will install VirtualBox using the APT package repository of Ubuntu. The benefit of installing VirtualBox using this method is that this method makes it very easy and quick to install. The negative side of this method is that it does not update when a new version is released.

To install VirtualBox via the APT package repository, first, update the system’s package repository by issuing the following command.

$ sudo apt update

D:\Sheroz\Feb\08\VirtualBox\Article\images\image16 fianl.png

After updating the system’s APT cache repository, install VirtualBox using the command given below.

$ sudo apt install virtualbox

D:\Sheroz\Feb\08\VirtualBox\Article\images\image7 final.png

D:\Sheroz\Feb\08\VirtualBox\Article\images\image14 final.png

You may be prompted for permission to take additional disk space to install VirtualBox. Type “Y/y” and hit “Enter” to continue the process.

After completing the installation of VirtualBox, you can install the extension package for VirtualBox if you need it to support USB devices, connect the host webcam, control a virtual machine remotely, and more features like this. To install the extension package, issue the following command.

$ sudo apt install virtualbox-ext-pack -y

D:\Sheroz\Feb\08\VirtualBox\Article\images\image11 final.png

In the VirtualBox Extension Pack Configuration window, read and accept the license by selecting “Ok.”

D:\Sheroz\Feb\08\VirtualBox\Article\images\image2 final.png

D:\Sheroz\Feb\08\VirtualBox\Article\images\image12 final.png

Once the extension pack has been installed, you can start using VirtualBox by searching for “VirtualBox” in the “Applications” menu and clicking on the VirtualBox icon.

Now, the latest stable version of VirtualBox should be installed on your Ubuntu 20.04 LTS system.

Method 2: Install VirtualBox from the Oracle Repositories

In this method, we will install VirtualBox from the Oracle repositories. The benefit of installing VirtualBox using this method is that it will automatically update when a new updated version of VirtualBox is released. The only negative to this method is that it is a bit lengthy and difficult to install VirtualBox in this manner. But you already know that you only have to perform the installation process once, so the initial lengthier installation will save you time in the long-run. So, let us begin installing the latest version of VirtualBox on Ubuntu 20.04 LTS.

Step 1: Import GPG keys

First, import and add the GPG repository keys to your system by issuing the following command in your terminal.

$ wget -q https://www.virtualbox.org/download/oracle_vbox_2016.asc -O- | sudo apt-key add -

After adding the GPG keys, add the APT repository of VirtualBox to your system, as well.

Step 2: Add APT Repository of VirtualBox

To add the APT repository of VirtualBox, issue the command provided below.

$ sudo add-apt-repository "deb [arch=amd64] http://download.virtualbox.org/virtualbox/debian $(lsb_release -cs) contrib"

Once the GPG keys and repository of VirtualBox have been added successfully to the system’s sources list, you can now install the latest version of VirtualBox on your Ubuntu system.

Step 3: Update System Package Repository

Next, update the APT cache repository using the following command.

$ sudo apt update

In the image above, you can see that the update process has shown the added VirtualBox repositories.

Step 4: Install Latest Version of VirtualBox

Install the latest version of VirtualBox by entering the command given below.

$ sudo apt install virtualbox-6.1

D:\Sheroz\Feb\08\VirtualBox\Article\images\image8 final.png

You can also install your desired version of VirtualBox by typing the above command without providing the version number and hitting the “Tab” key on your keyboard. By using this technique, you will be able to see all the available versions of VirtualBox, and then you can type the version of your choice. A demonstration of this process is provided below.

First, issue the following command.

$ sudo apt install virtualbox-

Next, hit the “Tab” key on your keyboard after typing the above command.

D:\Sheroz\Feb\08\VirtualBox\Article\images\image1 final.png

You can see that the output has shown all the available versions of VirtualBox. Select the version you prefer and add it to the command in the following format.

$ sudo apt install virtualbox-6.1

D:\Sheroz\Feb\08\VirtualBox\Article\images\image8 final.png

Finally, hit “Enter.”

You have now installed your desired version of VirtualBox onto your Ubuntu 20.04 LTS system.

Step 5: Start VirtualBox

Go to “Activities” and search for “VirtualBox.” From the results, select the VirtualBox icon.

Now, you should have the latest version of VirtualBox installed and running on your Ubuntu 20.04 system.

Conclusion

This article explained the two most effective methods for installing VirtualBox on an Ubuntu 20.04 LTS system. One of these methods uses the APT package repository, which is easy to install. The second method uses the Oracle repository, and the version of VirtualBox installed using this method will be upgraded automatically when a new version is released.

]]>
Manage VirtualBox remotely with RemoteBox – Install on Linux https://linuxhint.com/remotebox-virtualbox-linux/ https://linuxhint.com/remotebox-virtualbox-linux/#respond Sun, 26 Feb 2017 18:00:51 +0000 http://sysads.co.uk/?p=16492 RemoteBox is a VirtualBox client tool that enables you to essentially administer the installation of a virtualbox on a server remotely (ie over the network), including its guests as well as ability to interact with them as if they were running locally.

VirtualBox is installed on the server machine while RemoteBox runs on the client machine. It provides a complete GTK graphical interface with a look and feel very similar to that of VirtualBox’s native GUI.

Key Features

  • Open source VirtualBox client with a graphical (GTK) interface
  • Remote management of VirtualBox and its guests
  • No web server such as Apache or IIS is required to run the app
  • No compilation is required – written entirely in Perl
  • View and interact with the guest’s display via RDP, including sound as well as clipboard
  • Create and edit guests
  • Configure processor, display, input devices, audio, I/O ports, as well as shared folders
  • Set the guest BIOS configuration including the BIOS image
  • Set advanced options such as HPET, Page Fusion, Large Pages, CPU Hotplugging, CPU Throttling etc
  • Attach USB devices as well as set USB device filters
  • Stop, start, pause as well as save guest states
  • Provision and attach storage including hard disks, CDs/DVDs as well as floppy disks
  • Configure networking including host only networks with DHCP servers
  • Supports guest snapshots
  • Compatible with VirtualBox running on Linux, Windows, Mac OS X and Solaris
  • Furthermore, it runs on Linux, *BSD and Mac OS X
  • And much more…

RemoteBox

RemoteBox 2.2 Changelog

  • Added support for adding an NVMe Controller to the guest
  • It now requires VirtualBox 5.1.x
  • Added support for setting the hot-pluggable flag on harddisk as well as optical devices attached to SATA or USB storage controllers
  • Added support for specifying whether a disk controller should be bootable or not
  • Updated the number of possible SAS ports from 8 to 255 for an attached medium
  • Added the ability to set the number of SAS ports
  • Updated FreeBSD guest OS Icons
  • Fixed a bug when assigning a different SAS port to a medium. RemoteBox was not creating the SAS port first causing a port out of range error.
  • Fixed a bug when selecting storage attached to the USB controller. RemoteBox incorrectly showed the IDE controller attributes.
  • Set default guest OS types for new guests to Windows 10 64bit, Fedora 64bit, FreeBSD 64bit as well as DOS for their respective OS families
  • Minor changes to appdata.xml
  • In addition to various GUI tweaks

How to Install RemoteBox 2.2 on Ubuntu 16.10

wget -q -O - http://archive.getdeb.net/getdeb-archive.key | sudo apt-key add -

sudo sh -c 'echo "deb http://archive.getdeb.net/ubuntu yakkety-getdeb apps" >> /etc/apt/sources.list.d/getdeb.list'

sudo apt-get update && sudo apt-get install remotebox

How to Install RemoteBox 2.2 on Ubuntu 16.04

wget -q -O - http://archive.getdeb.net/getdeb-archive.key | sudo apt-key add -

sudo sh -c 'echo "deb http://archive.getdeb.net/ubuntu xenial-getdeb apps" >> /etc/apt/sources.list.d/getdeb.list'

sudo apt-get update && sudo apt-get install remotebox

How to remove RemoteBox 2.2 from Ubuntu

sudo apt-get remove remotebox
]]>
https://linuxhint.com/remotebox-virtualbox-linux/feed/ 0
Install Clear Linux (Intel Linux OS) on a Virtual Machine using VirtualBox https://linuxhint.com/install-clear-linux-intel-linux-os-on-a-virtual-machine-using-virtualbox/ https://linuxhint.com/install-clear-linux-intel-linux-os-on-a-virtual-machine-using-virtualbox/#respond Tue, 10 Jan 2017 17:04:03 +0000 https://linuxhint-com.zk153f8d-liquidwebsites.com/?p=17554 The Clear Linux Project for Intel Architecture is building a Linux OS distribution targeted for various cloud use cases. The goal of the Clear Linux OS is to showcase the best of Intel Architecture technology, from low-level kernel features to more complex use cases that span the entire operating system stack. Emphasis is been put on Power and Performance optimizations throughout the operating system as a whole.

Clear Linux Key Features

  • With Clear Linux OS stateless feature, it can effectively perform a “factory reset” on the system and you can immediately set it up again
  • With Clear Containers, ways are been worked on to improve security of containers by using Intel Virtualization Technology
  • Cloud Integrated Advanced Orchestrator (ciao) is a new workload scheduler designed to address limitations in current cloud OS projects
  • Clear Linux for Intel Architecture includes a telemetry solution that rapidly detects and responds to quality issues in the field
  • Clear Linux OS for Intel Architecture is the first Linux distribution that supports auto proxy
  • Mixing is a term we use to describe composing an OS for very specific use cases
  • AutoFDO uses a sampling-based profile to drive feedback-directed optimizations
  • Function Multiversioning (FMV) is a compiler feature that is capable of optimizing the same code for multiple architectures, automatically selecting the correct architecture-specific version of the code at runtime

How to Install Clear Linux on a Virtual Machine using VirtualBox

Create a virtual machine in VirtualBox

  • Download the latest live version (clear-XXXX-live.img.xz)

[su_button url=”https://download.clearlinux.org/image/” target=”blank” icon=”icon: download”]DOWNLOAD THE LIVE IMAGE[/su_button]

  • Decompress the downloaded image.
    • On Linux Machine
xz -d clear-XXXX-live.img.xz
    • On a Windows Machine, use 7zip.

  • Convert the raw image to VDI format by running either of the following commands (Note: open the command prompt as an Administrator > Change to directory Virtualbox was installed on, in my case “E:\program Files\Oracle\VirtualBox”. Then note to point to directory you extracted the image file to)
VBoxManage convertfromraw e:\Ubuntu\clear-linux\clear-12540-live.img e:\Ubuntu\clear-linux\clear-12540-live.vdi --format VDI

or:

vbox-img convert --srcfilename e:\Ubuntu\clear-linux\clear-12540-live.img --dstfilename e:\Ubuntu\clear-linux\clear-12540-live.vdi --srcformat raw --dstformat vdi

clear linux intel

  • Now create a new virtual machine using the following settings
    • Type: Linux
    • Version: Linux 2.6 / 3.x / 4.x (64-bit)
    • On Hard disk, select “Use an existing virtual hard disk file”

clear linux intel

  • Next go to settings to enable EFI support
    • System -> Enable EFI (special OSes only)

clear linux intel

Start and Configure Clear Linux OS

  • When you start the VM for the first time, Clear Linux will ask for a login user, type root and then enter new password

clear linux intel

Now time to get the OS up and running

  • Install the bundle that supports VirtualBox modules
swupd bundle-add kernel-lts
  • Set a timeout in the bootmanager to shows a menu at boot time
clr-boot-manager set-timeout 10
  • Update the bootloader entries
clr-boot-manager update
  • Reboot the machine
reboot

clear linux intel

  • On restart, choose LTS kernel version

clear linux intel

(Optional) Unset timeout to boot directly to LTS version

clr-boot-manager set-timeout 0
  • Update bootmanger to use always LTS version
clr-boot-manager update

Next Install Guest Additions

  • Install the sysadmin-basic bundle
swupd bundle-add sysadmin-basic
  • Insert Guest Additions CD image using Devices menu and Install
install-vbox-lga
clear linux intel
  • Reboot your system
reboot
  • Setup the Clear Linux graphical user interface ans start it up
swupd bundle-add os-utils-gui

startxfce4

clear linux intel

]]>
https://linuxhint.com/install-clear-linux-intel-linux-os-on-a-virtual-machine-using-virtualbox/feed/ 0