Microsoft Hyper-V vs VMware vSphere
Virtualization has become a massively important part of almost all server workloads and there are lots of options to choose from. For this article, we will just focus on the two frontrunners, Microsoft Hyper-V and VMware ESXi and why you might choose one over the other.
First I will talk about their similarities and then highlight how they differ. Both of ESXi and Hyper-V are Type I or bare metal hypervisors. This means that you can load VM's directly onto them and do not need a base operating system as well. They both feature live migration, high-availability and failover capabilities and they both can support a large array of guest VM operating systems.
So how do they differ then? Well, for starters, Hyper-V can come in a couple different flavors. You may load Hyper-V Server as it's own standalone setup like you would with ESXi but there is also the option to use Windows Server 2016 and simply add the Hyper-V role. This kind of blurs the line of it being a type I and type II hypervisor, but this can be very handy for many people as it allows virtualization to be built on top of already existing server stacks running other Windows Server services. Anyone already using Windows Server will likely be more comfortable using Hyper-V because it using the same UI and design principles. ESXi being Linux based will likely be quicker to pickup for those more familiar with bash and less GUI heavy interaction.
One other thing that varies between them rather significantly is their licensing. Both of them charge you per physical CPU so if you have a quad socket system then you will have to pay for four licenses. This is very important because the licenses are not cheap. I have to give Hyper-V the advantage on this one though because on ESXi you will have to buy the ESXi license as well as the Microsoft License underneath if you are using their services. If you are using Hyper-V then it can come as a free role bundled in with your Windows Server license.
One huge win that ESXi has over Hyper-V is that it has been around in one form or another for much longer than Hyper-V has been around. This means that lots more support material and guides are available. Many add-ons and additional software tools have been made over the year to aid in almost anything you could want to do with virtualization. This is largely why ESXi is still used in much larger corporations. It has greater flexibility and power when combined with all of the advanced tools that have been created over the years. But then on the flipside, you have the active directory integration with Hyper-V which allows for easier setup of a secure environment.
Last thing to consider is the potential size of your deployment. I won't go into detail on this because there are too many specifics to hash out, but basically, I highly recommend you read through the documentation if you are looking at very packed hosts because you may eventually run into issues where you are exceeding the limits of the hypervisor in terms of RAM or VM's or CPU's/vCPU's.
So finally which one wins? Well, like with most things, it really depends on your use and the current environment you are running and what you are willing to learn. Most people would agree that ESXi is a more complete solution but you are also going to need to learn a new environment if you choose ESXi over Hyper-V and you are giving up some creature comforts as well as likely paying a bit more for licensing.
Types of Hypervisors(Type 1 and Type 2)
If you've looked into hypervisors at all you have probably realized that there are a ton of different options and packages, even from one vendor there might be many different options like with Citrix and VMware. All of these can be separated into two groups. Type 1, commonly referred to as a bare-metal or client hypervisor. Or, Type 2, commonly referred to as a hosted hypervisor. Both of these are incredibly valuable, but your use case will greatly determine which you want to use.
Type 1 hypervisors are installed directly onto your system and are a standalone operating system, hence, bare-metal. Once you have installed this kind of hypervisor then you can install OSes onto the hypervisor and it will run that operating system once you spin it up to run. These systems you will typically be accessed by some remote connection or send actions via command prompt. You can have many virtual machines spun up on these kinds of hypervisors at once. Here is a list of type I hypervisors. Here are some type 1 hypervisors to look into(sorted by market share): ESXi , Hyper-V, and Xen.
Type 2 hypervisors, in contrast, do not run directly on the system and instead run inside of the host operating system. This means that if you are already running Windows Server 2016 then you might install a type 2 hypervisor into this environment. This is very handy if you need to run some linux only software or swap between operating systems. This will save you from needing to dual boot and do a restart everytime you want to go back and forth. These can be used in a similar way to how a type 1 is where you load up a few different operating systems and let it run in the background doing server tasks and that was common before everyone had virtualized their infrastructure because that allowed them to leave their current equipment and setup in place and simply take on additional functionality inside of a type 2 hypervisor, but at this point most people go directly for type 1 when they are building out their systems. Type 2 is mainly used now for individual systems needing another environment. Here is a list of type 2 hypervisors you might be interested in VMware Workstation, VirtualBox, QEMU
Setting Up VirtualBox to Experiment with New Software in Windows
There are lots of reasons why you might want to set up a virtual environemnt. You might want to run a version of Ubuntu in order to run some Linux only software without needing to dual boot and totally restart your computer to switch back and forth or you may want it to test out some risky software within a sandbox that won't damage any of your normal working environment. Whatever the purpose, it is very simple and quick to setup and can be a powerful trick to have in your arsenal.
1. Visit virtualbox.org
and click on the large download button to look at the various versions. At the top of the page you will find links that mention Windows, OS X, Linux and Solaris. VirtualBox works for all of these operating systems and you can follow the directions under each of the installations but in this guide, I will walk you through how to do it on Windows as that is what most people's base OS is. Once you click Windows Hosts it will start a download of the Virtual Box program. Once this is finished downloading run the executable. Continue through the installation process by hitting next. There are some things along the way you can tweak, but it is likely best to leave everything as default if it is your first time trying out virtualization software and don't know what your needs will be.
When you first open up the program after installation it will look something like this, but probably without the Ubuntu and setup information there.
The first thing you will want to do once you have reached this screen is click the "New" button in the top left so that you may start setting up a VM. Here you will set a name and tell Virtual Box which operating system you are planning on installing. For this tutorial, I will use Ubuntu as an example but all other operating systems should follow the same process after this step. Once you select your operating system click next and then it will ask you how much memory you want to allocate to the virtual machine.
The menu shows a color gradient where it eventually goes red at the right side. You generally won't want to allocate your VM that much RAM as that will end up taking away too many resources from your base operating system. Anywhere in the green region is generally safe, but you might want to experiment with this and check the recommendations for your specific operating system as some want more RAM than others.
Once you have made that decision it will lead you to a screen asking you to make a virtual hard drive. This is just like the memory setup where you set aside some hard drive space for the VM. I recommend you do that in this step and leave it as its default for now. After that screen it will lead you to choosing a virtual hard disk type if you chose to create one. You have the choice between VDI, VHD and VMDK. Most likely it is best to just use VDI as that is the native format for VirtualBox, but if you are interested in testing other virtualization solutions you may want to choose a format that will most easily port to the other solutions you are looking at using. VHD is used by VMWare, Sun xVM, QEMU, SUSE Studio, and .NET DiscUtils. VHD is used by Microsofts virtualization solutions like Hyper-V.
Afte you have completed that you will be asked if you want a dynamically allocated disk or fixed disk. A dynamically allocated disk will start at a small size but continue expanding up to the maximum size so it will not show it has consumed space on the hard drive in your base OS. Fixed on the other hand will automatically reserve all of that space for the VM.
Now it will let you choose the maximum size of your virtual hard disk. This is entirely up to you, just make sure you will have enough room to put your VM OS on there and also make sure you have enough room left for your base OS. You can move and change these settings after setup as well so don't stress if you think you need to expand the VM's storage later.
Ok. So it's all setup, now what? It isn't doing anything. Now what you have to do is go down to the storage tab and assign it an ISO to install the operating system you want. For me, I went to the Ubuntu Desktop Download page and downloaded Ubuntu 17.04. Take note of where it is downloading and then click the storage tab where it says Optical Drive and then assign the ISO you just downloaded. This is simulating putting in the install disk like you would on a physical computer. After this, just hit the green start button in the top and it will start up a window of a system like you just started a physical system and booted to the disc.