Installing Microsoft Hyper-V | Windows Server Virtualization

Microsoft Hyper-V, known as Windows Server Virtualization, is a native (bare) hypervisor. It can create virtual machines on x86-64 systems running Windows OS, starting with Windows 8. Hyper-V supersedes Windows Virtual PC as the hardware virtualization component of the client editions of Windows NT. A server computer running Hyper-V can be configured to expose individual virtual machines to one or more networks.

Let us see how to install a Hyper-V role in a Windows Server by following the steps given below.

Step 1 To Install Hyper-V role go to “Server Manager” → Manage → Add Roles and Features.

VM

Step 2 Click on “Next”.

VM

Step 3 Select “Role-based or feature-based installation” option → click on “Next”.

VM

Step 4 We will locally install the Hyper-V role as such “Select a server from the server pool” → click “Next”.

VM

Step 5 From the Roles lists, check the “Hyper-V” Server role → click on Add Features on the popup window → click “Next”.

VM

Step 6Click “Next”.

VM

Step 7 Choose your server’s physical network adapters that will take part in the virtualization and responsible for network switching → click on “Next”.

VM

Step 8 Under Migration, leave the default settings → click on “Next”.

VM

Step 9Choose the path where you want to save the file → click on “Next”.

VM

Step 10 Click “Install” and wait for the installation bar to finish.

VM

Duplicating a VM

To duplicate or clone a machine means making an exact copy of it. Most of the hypervisors support this feature. By duplicating a machine, we copy down every detail, including the name of the machine and the different network addresses attached to the machine.

Duplicating a machine and putting it in to function is not always the best option because a duplicate name or IP in network can be a problem. We make duplication generally for backup purposes. Most hypervisors can clone while the machine is turned off. If the hypervisor accepts to clone while it is on, it is recommend to turn it off, because the process can crash the machine.

Backing Up and Recovering a VM

There are three methods for backing up virtual machines.

Method 1

The most common one is to install traditional backup software on the guest VM. If Windows OS is used on our VM, we can use “Backup and restore” to back up the machine, which is found in the “Control Panel”. For Linux OS, we can use many open source tools depending on our needs, like “Bacula”, “rsync”, etc.

VM

Method 2

Another strategy or method is to copy all of the files that define a VM. Therefore, we will have to go out and find all of the individual files that define our virtual machine and copy them to an alternate location. Some of these files are going to be large.

VM

To find the files that we have to copy or to backup, we have to right click on the VM machine. Go to “Storage” then move your mouse over the virtual HDD and it will show the full path where the VDI files are found.

VM

Method 3

The third option to backup and restore VM machines is to use third party software.

Converting a Physical Server into a Virtual Server

VMware puts out a product that is called vCenter Converter, which will convert from a physical machine specifically into a VMware virtual machine. The software can be downloaded from - https://www.vmware.com/products/converter.html

VM

Microsoft has a product called Disk2vhd, which will convert a physical hard drive into a VHD formatted virtual hard drive. It can be downloaded from the following link – https://technet.microsoft.com/en-us/sysinternals/ee656415.aspx
We just have to install the software on the physical server and click “Create” as shown in the screenshot below. A VHDX file will be created which could be imported in a Hypervisor.

VM

Both of these products will convert machines, while the server is running and is free. All the vendors of hypervisors have some P2V tool and they are typically free. From the vendor’s point of view, they would very much like you to convert your physical machines into virtual machines that are optimized for their hypervisor.

Converting a Virtual Server into a Physical Server

To convert a virtual server to a physical server also commonly called as V2P is certainly less common than a P2V conversion. However sometimes, it is needed in development-based environments. It does happen where a product needs to be tested in the virtual server than to a physical server, or to clone a production machine and move it to test.