Question about type 1 VS type 2 Hypervisors.

The network is the forum.

Moderators: Steel, notfred

Question about type 1 VS type 2 Hypervisors.

Postposted on Fri Jul 25, 2014 6:45 pm

I've googled this like crazy, but just can't quite find the answer I'm looking for.

What is the big performance difference between a Type 2 hypervisor such as VirtualBox, which runs like software inside another operating system. Compared to a type 1 hypervisor such as ESXi which runs on a server machine, and the virtual machines are accessed remotely on other pc's?

I've used VirtualBox quite a bit, and never used ESXi yet, but I just can't quite wrap my head around how a type 1 hypervisor could work, or perform anywhere near the level of a type 2? I mean, there must be such an incredible amount of data exchanged. I'm imagining all the data from a 1920x1080 display being refreshed 60 times a second, plus all sorts of input and output data, and who knows what else, having to be sent through a little ethernet cord. I mean, even a DVI cord used to connect a monitor to a PC is has something like 18-24 pins, so how can an 8 wire ethernet cord supply all that video data, plus all the other necessary data fast enough to be usable?
mxmaniac
Gerbil In Training
 
Posts: 5
Joined: Fri Jun 27, 2014 12:34 pm

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Sat Jul 26, 2014 11:25 am

Type 1 vs. type 2 is not (directly) related to the issue of whether the display and I/O is remote; it relates to whether the virtualization tool performs its I/O through another host OS or not. Type 1 (or "bare metal") hypervisors are essentially a special-purpose OS designed specifically to virtualize other OSes; they deal directly with the hardware, and have their own device drivers. Type 2 hypervisors run on top of a conventional OS, and work through the host OS's existing device drivers to access the hardware on behalf of the guest OS.

When using a remote display with a VM, you're not sending every frame at 60 Hz. You're using a remote display protocol like Microsoft RDP or VNC (or possibly a remote X terminal in the case of *NIX based guests). The VM is running on the server, so the bulk of the I/O (disk and network) does not travel over the remote display connection at all.

For virtual servers (e.g. a hosted VPS in "the cloud"), you generally won't have a full remote GUI at all. Server administration is done via either a Web-based management interface, or remote CLI sessions (e.g. SSH).

Bottom line: How the display (or lack thereof) is handled is completely independent of the type of hypervisor.

As far as performance goes, type 1 hypervisors generally perform better and consume fewer resources, because you don't incur the extra overhead of having another OS running. The downside is narrower hardware compatibility, since a Type 1 hypervisor must have native device drivers for all of the hardware, whereas a Type 2 hypervisor relies on the device drivers of the host OS.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 38087
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Sat Jul 26, 2014 12:41 pm

just brew it! wrote:As far as performance goes, type 1 hypervisors generally perform better and consume fewer resources, because you don't incur the extra overhead of having another OS running. The downside is narrower hardware compatibility, since a Type 1 hypervisor must have native device drivers for all of the hardware, whereas a Type 2 hypervisor relies on the device drivers of the host OS.


Don't forget that type 1 hypervisors often get thwarted by bad iommu implementations in consumer boards *cough* asus, MSI *cough*
Deanjo
Gerbil XP
 
Posts: 424
Joined: Tue Mar 03, 2009 11:31 am

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Sat Jul 26, 2014 1:15 pm

Deanjo wrote:
just brew it! wrote:As far as performance goes, type 1 hypervisors generally perform better and consume fewer resources, because you don't incur the extra overhead of having another OS running. The downside is narrower hardware compatibility, since a Type 1 hypervisor must have native device drivers for all of the hardware, whereas a Type 2 hypervisor relies on the device drivers of the host OS.

Don't forget that type 1 hypervisors often get thwarted by bad iommu implementations in consumer boards *cough* asus, MSI *cough*

That's a potential concern. IOMMU support isn't a hard-and-fast requirement for all Type 1 hypervisors though, is it? There are also Type 2 hypervisors which can take advantage of IOMMU if it is present, so it is not necessarily an issue specific to Type 1 either.

Regardless, it seems to me that Type 1 makes more sense in an enterprise or commercial hosting service scenario, whereas Type 2 makes more sense at the consumer level since it allows you to retain full use of the host OS at native performance levels [edit: and supports a wider range of hardware]. (Yeah, that's probably a bit of an over-generalization, but I think it is a reasonable rule of thumb.)
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 38087
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Sat Jul 26, 2014 4:14 pm

Yeah, type 1s are more for headless servers, and type 2s are more for desktop usage.
Flatland_Spider
Gerbil Elite
 
Posts: 875
Joined: Mon Sep 13, 2004 8:33 pm
Location: The 918/539

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Tue Jul 29, 2014 4:48 pm

Flatland_Spider wrote:Yeah, type 1s are more for headless servers, and type 2s are more for desktop usage.

I would rather say: type 1s are for server environments, and type 2s are for desktop environments. You don't want to manager an OS running on another OS (running on another OS) in a server environment, but you also don't want the performance-sapping overhead of that extra OS layer either. So it's not just about being headless, it's about server environments in general: ease of administration, more scalable, etc.
Buub
Maximum Gerbil
Silver subscriber
 
 
Posts: 4214
Joined: Sat Nov 09, 2002 11:59 pm
Location: Seattle, WA

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Tue Jul 29, 2014 6:16 pm

just brew it! wrote:That's a potential concern. IOMMU support isn't a hard-and-fast requirement for all Type 1 hypervisors though, is it? There are also Type 2 hypervisors which can take advantage of IOMMU if it is present, so it is not necessarily an issue specific to Type 1 either.


It is not a hard and fast requirement for type 1's but it is a main draw of type 1 configurations. There is one type 2 virtualization that can in theory utilize iommu (virtual box) but trying to get it working properly on anything but a few models of NICs is a waste of time. Other type 2's such as VM Workstation, Parallels, etc do not even attempt to use iommu.

Regardless, it seems to me that Type 1 makes more sense in an enterprise or commercial hosting service scenario, whereas Type 2 makes more sense at the consumer level since it allows you to retain full use of the host OS at native performance levels [edit: and supports a wider range of hardware]. (Yeah, that's probably a bit of an over-generalization, but I think it is a reasonable rule of thumb.)


Many personal Xen, KVM and ESXi users would disagree with it only making sense in an enterprise/commercial product.
Deanjo
Gerbil XP
 
Posts: 424
Joined: Tue Mar 03, 2009 11:31 am

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Tue Jul 29, 2014 6:20 pm

Deanjo wrote:
Regardless, it seems to me that Type 1 makes more sense in an enterprise or commercial hosting service scenario, whereas Type 2 makes more sense at the consumer level since it allows you to retain full use of the host OS at native performance levels [edit: and supports a wider range of hardware]. (Yeah, that's probably a bit of an over-generalization, but I think it is a reasonable rule of thumb.)

Many personal Xen, KVM and ESXi users would disagree with it only making sense in an enterprise/commercial product.

I didn't say "only making sense" I said "makes more sense". :wink:

IOW the features seem more geared towards those types of use cases.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 38087
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Tue Jul 29, 2014 9:05 pm

Yet one of the big appeals of using a type 1 hypervisor is to allow proper passthrough to videocards for display purposes. That typically isn't the enterprise/commercial market. Xen has this use widely documented, right down to pointing people to where they can find out how to mod their consumer class videocards so they seen as multi-os cards.
Deanjo
Gerbil XP
 
Posts: 424
Joined: Tue Mar 03, 2009 11:31 am

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Wed Jul 30, 2014 10:41 am

Deanjo wrote:There is one type 2 virtualization that can in theory utilize iommu (virtual box) but trying to get it working properly on anything but a few models of NICs is a waste of time.


I can confirm Intel NICs work, and Broadcom NICs do not. Everytime I try to use the paravirt driver with the Broadcom NIC in my desktop, my Linux VMs panic on boot, but they work fine with the builtin Intel NIC.

Deanjo wrote:Yet one of the big appeals of using a type 1 hypervisor is to allow proper passthrough to videocards for display purposes. That typically isn't the enterprise/commercial market.


VMware uses graphic performance via passthrough as a selling point for its VDI solution. Their idea is to deploy thin clients which access VMs backed by graphics cards to provide the experience people expect from a regular laptop or desktop. Even graphics heavy applications like AutoCAD are supposed to be able to be virtualized.
Flatland_Spider
Gerbil Elite
 
Posts: 875
Joined: Mon Sep 13, 2004 8:33 pm
Location: The 918/539

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Wed Jul 30, 2014 11:19 am

Flatland_Spider wrote:
Deanjo wrote:There is one type 2 virtualization that can in theory utilize iommu (virtual box) but trying to get it working properly on anything but a few models of NICs is a waste of time.

I can confirm Intel NICs work, and Broadcom NICs do not. Everytime I try to use the paravirt driver with the Broadcom NIC in my desktop, my Linux VMs panic on boot, but they work fine with the builtin Intel NIC.

OK, now I am confused. If you have enabled IOMMU and PCI passthrough shouldn't you be using the native (Broadcom) driver for the NIC, not the paravirt driver? I think your Broadcom/paravirt crash is a separate, unrelated issue.
(this space intentionally left blank)
just brew it!
Administrator
Gold subscriber
 
 
Posts: 38087
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Wed Jul 30, 2014 11:51 am

I didn't realize VB supported IOMMUs, but the manual tells me it's only for Linux hosts. :-?
Think for yourself, schmuck!
i5-2500K@4.3|Asus P8P67-LE|8GB DDR3-1600|Powercolor R7850 2G|1.5TB 7200.11|1988 Model M|Saitek X-45 & P880|Logitech MX 518|Dell 2209WA|Sennheiser PC151|Asus Xonar DX
bthylafh
Grand Gerbil Poohbah
 
Posts: 3232
Joined: Mon Dec 29, 2003 11:55 pm
Location: Southwest Missouri, USA

Re: Question about type 1 VS type 2 Hypervisors.

Postposted on Wed Jul 30, 2014 1:34 pm

just brew it! wrote:OK, now I am confused. If you have enabled IOMMU and PCI passthrough shouldn't you be using the native (Broadcom) driver for the NIC, not the paravirt driver? I think your Broadcom/paravirt crash is a separate, unrelated issue.


bthylafh wrote:I didn't realize VB supported IOMMUs, but the manual tells me it's only for Linux hosts. :-?


...
Yeah, don't listen to me. I'm in the weeds, and I have no idea what I'm talking about today.
:oops:
Flatland_Spider
Gerbil Elite
 
Posts: 875
Joined: Mon Sep 13, 2004 8:33 pm
Location: The 918/539


Return to Networking

Who is online

Users browsing this forum: Google [Bot] and 4 guests