Virtual machine for Linux: concept, purpose, characteristics, features of use, installation and configuration

The article will discuss what a virtual machine for Linux is, how it differs from others, for example, for Windows, how to create a new machine, where it is used, and, most importantly, how to install any Linux distribution on her. It is recommended to read the article to the end, as it reveals the essence of programs for running Linux on other operating systems.

What is a virtual machine?

In fact, the virtual machine for Linux from the one for Windows is no different at all. In simple words, it is a computer emulator, and what operating system you will install on this virtual computer is up to you.

virtual machine for linux




If you go deeper, then the virtual machine is a special program designed to run the operating system within the framework of an already installed operating system. That is, you can easily install from the installation image of the same Linux without even turning off the computer and creating a bootable flash drive.

This program creates a computer inside the computer. The virtual device uses resources, as you might guess, of the present, so you need to have considerable resources so that the performance is enough for two operating systems at once.





How is the creation of a virtual machine and interaction with it

We figured out what a virtual machine for Linux is, now let's move away from the definition and talk about how virtualization works.

Firstly, there are several programs of the type presented on the network. There is no point in listing all of them, but let's say that the most popular are VirtualBox and VMware. After you have made your choice, the program must be installed. This is done in a standard way - using the installation file.

kali linux to the virtual machine




Having a virtual machine installed on your computer, you can go directly to its launch and virtualization of the working machine. But you need to install an operating system on the machine, so download its image from the Web in advance. Looking ahead, we say that the article will provide instructions on how to install the OS, and Kali Linux will be disassembled as an example.

In general, that’s all. Having the installed program and the image of the operating system, you can proceed to install it. This is done differently in each program, and we will consider how exactly later.

Scope of application

Now let's talk about why virtual machines are needed at all, because a simple user will say that it’s easier to write a bootable USB flash drive with the desired distribution and install the OS directly on the computer through it. And more informed ones will add that this can be done in a non-standard way, for example, next to an already installed Windows, or, without installing it at all, to start from LiveCD. But not so simple.





installing linux on a virtual machine




Here are the most obvious and common reasons for using virtual machines:

  • Checking unknown operating systems. This is the most obvious reason, because when you find a distribution, you first want to look at it before installation to understand whether it is suitable or not. The virtual machine will help you one hundred percent.
  • Testing software from dubious sources. If you value security and do not want to run everything that got on your main operating system, then it is better to check the dubious program on a virtual machine.
  • Surfing the Internet without the risk of picking up a virus. Some use virtual machines to secure their stay on the World Wide Web.

And these are just three reasons, although they are an order of magnitude larger. But we will not focus on this for a long time and move on to the varieties of these programs.

Varieties of Virtual Machines

As noted earlier, there are many virtual machines on the market. So far, two have been named - VirtualBox and VMware. Without a doubt, they are the most popular and often used, but you can not ignore less noticeable, but no less good programs, for example, Qemu or Parallels Desktop. They are undoubtedly good to use, but will not be parsed in the article for some reason.

So, Qemu is able to run any version of operating systems, but it is difficult to use. Despite the fact that it has an order of magnitude more various tools, working with them will be convenient only for professionals. The main drawback of Parallels Desktop is generally trivial - it only works on MacOS. Yes, you can run both Linux and Windows on it, but only if you are a lucky owner of an Apple product.

Preparations for Installing Linux on a Virtual Machine

Now let's move on to the most interesting. As promised, we will now talk about installing Kali Linux on a virtual machine. However, before that we’ll talk about preparatory activities, without which nothing will work.

As already mentioned, no flash drives need to be recorded, which is undoubtedly a plus. However, an operating system image must be uploaded. Since this is Kali Linux, download the ISO file from the official website of the developers. You also need to install the virtual machine itself. Below we look at Virtual Box and VMware, therefore, we recommend using one of them so that there are no problems launching the downloaded operating system on a virtual machine.

In general, this is all that needs to be done before installing Kali Linux on a virtual machine. Well, then we will go directly to the process of setting up machines for the correct launch of operating systems on them.

How to install Linux on a virtual machine

how to install linux on a virtual machine




So, you downloaded the image of the Linux distribution, completed the installation of the virtual machine, so you can immediately proceed to install the OS on it. First of all, we will analyze the VirtualBox program, as it is more popular, well, and after it will be told about VMware.

Program No. 1: VirtualBox

installing kali linux on a virtual machine




Installing Linux on a VirtualBox virtual machine is as follows:

  1. Run the program itself.
  2. In the window that appears, click on the "Create" button, which is located on the top panel. Also for this you can click on the "Create" button in the "File" menu.
  3. A new window will open. In it you need to enter the name of the future operating system (enter any name you like), select the type of operating system, since we are talking about Kali Linux, select Linux, and in the end the version of the selected distribution. Kali Linux will not be among all the others, so choose Linux 2.6 / 3.x / 4.x (64-bit).
  4. At the next stage, you will be asked to set the amount of RAM that you are ready to give under the control of the virtual machine. It is recommended that you select a value within the green line, otherwise there may be problems with virtualization.
  5. Now you need to choose a virtual hard drive. You are given three options to choose from: do not connect a hard drive, create a new virtual one, or use an already created one. If you are installing Kali Linux for the first time, then choose the second option, if it is already there and you want the files from the previous one to be on this one, then the third.
  6. Now you need to select the type of hard drive. Without going around the bush, let’s say that choosing VDI is best.
  7. When choosing a format for storing data on disk, it is recommended to specify "Dynamic" so that its volume increases as it is full, and not stand out from the main system immediately.
  8. Now specify the maximum volume allocated for the virtual OS.
installing linux on a virtualbox virtual machine




That's all, the car is created. You just need to run it, specify the image of the Kali Linux distribution and perform a standard installation.

Program No. 2: VMware

astra linux virtual machine




Well, now we’ll show you how to install Linux on VMware. Here is the detailed instruction:

  1. Having opened the program, click on the "Create a new virtual machine" button.
  2. When choosing the type of machine configurations, select "Normal".
  3. Since the installation will take place from the image, select the "Image file" item and specify the image itself by clicking the "Browse" button.
  4. At the stage of choosing the operating system, specify Linux and select the version of Debian 7, these are the parameters that are suitable for installing Kali Linux.
  5. Now you need to specify the name of the machine and the storage folder for all its data.
  6. Specify the amount of disk space for the OS. It is recommended to leave everything as default and click "Next".
  7. Click Finish.

The creation of the machine is over. Click the "Enable Virtual Machine" button to launch the installation image. By the way, in the same way you can install the Astra Linux distribution on a virtual machine.

Conclusion

We found out what it is - a virtual machine for Linux, and why use it. As a result, you even learned how to create your own machine to run Kali Linux, but, as mentioned earlier, the instructions for this distribution can be applied to almost everyone else.




All Articles