Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

What is virtualization, and describe its overhead?

Muhammad Ahmad

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Overview

The hypervisor and virtual machines share the host computer's physical central processing unit (CPU) in a virtualized environment. Because multiple processes want to use the physical CPU simultaneously, virtual machines may have to be scheduled on the CPU. This is one of the other overheads of virtualization.

In this Answer, we'll learn about virtualization, its significant categories, and its overhead of virtualization.

Virtualization

Virtualization uses different software-based solutions to create an abstract layer on our computer hardware. This allows us to divide the hardware elements of a single computer (processors, memory, storage, and so on) into virtual machines (VMs). Each VM runs its operating system, which runs only on some of the underlying computer hardware but behaves like a stand-alone computer.

Simulation of OS-level virtualization

Virtualization can be categorized into two categories:

Categorization of virtualization

Hardware-based

In this implementation, the hypervisors provide the virtual machine's implementation through firmware, allowing it to run on the core hardware (CPU). Its also known as a type-00 hypervisor.

OS based

In this implementation, the hypervisors provide for the virtual machine's on top of the existing operating system. The new virtual machine(VM) also runs the conventional operating system. Its also known as a type-11 hypervisor.

The practical use cases of virtualization are:

  • Cloud virtualization
  • Storage virtualization
  • CPU virtualization
  • Network virtualization

And many more!

Overheads

Virtualization is associated with some overhead:

Additional access time

After virtualization, the virtual machines require additional time to access the memory due to the layer on top of the OS or core hardware. The processor's paging hardware uses the page tableIt’s a shadow page table for OS-based approach or two level page table for hardware-based approach..

Require extra space

The hypervisor requires extra space to implement its data structure and code, excluding the memory allocated to the virtual machine (VM) separately.

CPU utilization

Some percentage of the CPU is unavailable to the virtual machine (after virtualization) because the CPU is consumed by other virtual machines, VMware itself, or other processes. We can use the gauge It shows the percentage of CPU that is unavailable to this virtual machine.to show this percentage.

RELATED TAGS

CONTRIBUTOR

Muhammad Ahmad
Copyright ©2022 Educative, Inc. All rights reserved

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Keep Exploring