Topic 20 – Virtualisation Flashcards
how is
hardware support for virtualistaion acheived
To achieve this there must be hardware support for it. More specifically the processor must support it.
the processor does this by introducing a new mode that can be used along with user mode and kernel mode. Called hypervisor mode
this view from the containers perspective
it will only be able to see the parts of the system it has access to
running any system commands will only reveal the parts of the system it has been allocated to use
describe the
system view
that a container will have
describe the
file system view
of a container
this view of a container can be summarised as:
it will share the file system of the base OS however any changes made are not made to the base OS instead a layer known as the overlay file system will keep track of any changes and present it to the container with a merged view of the OS file system and the overlay file system
give 1 advantage that an
overlay file system brings for containers
an advantage of this is:
- A simultaneous Shared and separate file system - Only file changes made by the container are held here. any files that are used but unchanged from the underlying file system can be shared directly from the underlying file system to the container
describe the term
merged view file system
this is the view of the file system that the container will see
it is a combination of:
- base file system - held on the host OS
- overlay file system - which reflects any changes or added data that has been made by the container
describe the term
copy on write
a method for modifying files while maintaining the original file.
This is software that can emulate hardware.
It is able to perform very much like an OS in that it will share resources between the different virtual machines that run on top of it and ensure that each gets its fair share of time to process
describe a
hypervisor
This is also known as a hosted hypervisor and is software that will run as a device driver on the host OS.
describe a
type 2 hypervisor
this is software that can imitate hardware.
One use of this is emulating old hardware so that old applications and games can be bought into the modern age and ran on new hardware.
describe
Hardware/machine emulation
describe
Application virtualisation
where an application offers functionality but is able to virtualise that functionality between different instances.
One example is Apache web server that can host many websites within its application but resources between the websites must be kept isolated
software that can emulate hardware and present it to a virtual machine
describe the term
hypervisor
describe the term
overlay file system
a file system used by a single container that allows it to:
- Share the underlying file system
- make changes to the shared underlying file system. Without changing the host file system
these include:
- Virtual runtime environments
- Hardware/machine emulation
- Application virtualisation
- Network virtualisation
name 4
types of virtualisation which are not in relation to the OS
a file system used by a single container that allows it to:
- Share the underlying file system
- make changes to the shared underlying file system. Without changing the host file system
describe the term
overlay file system
an action carried out by the hypervisor that allows it to switch between the different virtual machines by saving and restoring there state.
This is a similar behaviour of an OS context switch
describe a
vm switch
each of these actions are summarised below

describe how a containers merged view of a file system would look when there is
- no change made by the container
- a modification by the container to the original file on the host file system
- a deleted file by the container
- a created file by the container
where an application offers functionality but is able to virtualise that functionality between different instances.
One example is Apache web server that can host many websites within its application but resources between the websites must be kept isolated
describe
Application virtualisation
how can an
overlay file system for a container be implemented
This can be achieved by the container creating its own mounted file system and writing changes to the mounted file system using the method known as copy-on-write
To achieve this there must be hardware support for it. More specifically the processor must support it.
the processor does this by introducing a new mode that can be used along with user mode and kernel mode. Called hypervisor mode
how is
hardware support for virtualistaion acheived
describe
containerisation
This is a virtualisation solution that will create what are known as containers.
Each container can run one or more applications and shares the underlying kernel and file system.
However each container is unaware that it is a container and believes it has sole control of the system
upon a
VM switch
what information would be saved/restored
when this occurs the following information would be saved/restored
- The hardware view for the VM
- Whether the VM is in an active state or a inactive state
- The values of the registers
this requires a linux kernel as a base OS this problem is solved by:
- Linux - the already installed linux kernel is used as the base OS
- macOS - a linux kernel is installed and that is used as the base OS instead of the macOS
- Windows - the Windows Subsystem for Linux (WSL) is installed that is a customized version of the linux kernel that is and will integrate with the windows OS
what does docker require in order to run and how is this problem solved for:
- linux
- macOS
- windows
describe a
hypervisor
This is software that can emulate hardware.
It is able to perform very much like an OS in that it will share resources between the different virtual machines that run on top of it and ensure that each gets its fair share of time to process
properties of this include:
-
Isolation - Applications or even full operating systems can be ran alongside each other without any knowledge of the others existence
- Has the benefit of protection from malware or system corruption
- Different instances of the same application can be run but serve separate purposes
- Each can mange there own files
- Upgrades can be achieved on a container or vm basis and only affect that instance
-
Management - can be easily managed without any disturbance to other running processes
- Start, stop or pause
- Add/remove resources such as memory or processing time
- Encapsulation - any data created can be encapsulated into a file and imported and exported to different systems
- Flexibility - the ability to quickly create and destroy different environments is a great benefit in development of applications or for testing purposes
give 4
properties that virtualisation has
this is a repository offered by docker where pre built containers can be downloaded from
what is the
docker hub
how can
copy-on-write
be implemented
this can be implemented by copying the file to a new destination when ever a change must be made.
Changes are then made to the file in the new destination so that the original file can be preserved
a lightweight and fast virtualisation solution that is able to share the underlying OS kernel and file system.
while at the same time running applications in a virtual isolated environment and managing its own files
describe the term
container
a method for modifying files while maintaining the original file.
describe the term
copy on write
this is as the diagram below

describe the
structure of the system when using containers
this can be implemented by copying the file to a new destination when ever a change must be made.
Changes are then made to the file in the new destination so that the original file can be preserved
how can
copy-on-write
be implemented
these must be supported by the OS
- Known as partitions in windows
- Jails in BSD-based versions of linux
to make use of containers what must have support for them
describe the
overlay file system
This is a key feature of containers and is what allows a container to create its own file system.
Any changes the container makes to the underlying file system will be held here and then a merged view can be presented to the container such that:
base file system + this = merged view of file system
this is the view of the file system that the container will see
it is a combination of:
- base file system - held on the host OS
- overlay file system - which reflects any changes or added data that has been made by the container
describe the term
merged view file system
give 3
advantages of containers
advantages of this include:
- fast execution - Are fast to run as a kernel does not need to be loaded it is already running
- conflict avoidance - Dependency hell can be avoided as each container has its own file system via the overlay file system and can be updated independently
- Lightweight - as they can contain only what is needed to run the applications within the container and can also share resources already on the base OS
This can be achieved by the container creating its own mounted file system and writing changes to the mounted file system using the method known as copy-on-write
how can an
overlay file system for a container be implemented
an advantage of this is:
- A simultaneous Shared and separate file system - Only file changes made by the container are held here. any files that are used but unchanged from the underlying file system can be shared directly from the underlying file system to the container
give 1 advantage that an
overlay file system brings for containers
describe
Hardware/machine emulation
this is software that can imitate hardware.
One use of this is emulating old hardware so that old applications and games can be bought into the modern age and ran on new hardware.
give 4
properties that virtualisation has
properties of this include:
-
Isolation - Applications or even full operating systems can be ran alongside each other without any knowledge of the others existence
- Has the benefit of protection from malware or system corruption
- Different instances of the same application can be run but serve separate purposes
- Each can mange there own files
- Upgrades can be achieved on a container or vm basis and only affect that instance
-
Management - can be easily managed without any disturbance to other running processes
- Start, stop or pause
- Add/remove resources such as memory or processing time
- Encapsulation - any data created can be encapsulated into a file and imported and exported to different systems
- Flexibility - the ability to quickly create and destroy different environments is a great benefit in development of applications or for testing purposes
give 3 points about the processor
hypervisor mode
points for this include:
- More privileged than kernel mode and takes priority
- Contains extra instructions
- Specific instructions and interrupts will put the processor into this processor mode
points for this include:
- More privileged than kernel mode and takes priority
- Contains extra instructions
- Specific instructions and interrupts will put the processor into this processor mode
give 3 points about the processor
hypervisor mode
describe the term
container
a lightweight and fast virtualisation solution that is able to share the underlying OS kernel and file system.
while at the same time running applications in a virtual isolated environment and managing its own files
when this occurs the following information would be saved/restored
- The hardware view for the VM
- Whether the VM is in an active state or a inactive state
- The values of the registers
upon a
VM switch
what information would be saved/restored
describe a
type 2 hypervisor
This is also known as a hosted hypervisor and is software that will run as a device driver on the host OS.
describe the
structure of the system when using containers
this is as the diagram below

what does docker require in order to run and how is this problem solved for:
- linux
- macOS
- windows
this requires a linux kernel as a base OS this problem is solved by:
- Linux - the already installed linux kernel is used as the base OS
- macOS - a linux kernel is installed and that is used as the base OS instead of the macOS
- Windows - the Windows Subsystem for Linux (WSL) is installed that is a customized version of the linux kernel that is and will integrate with the windows OS
give the 6 steps of the following scenario
an I/O operation issued by a virtual machine that has completed
the 6 steps for this scenario include:
- An I/O operation issued by a VM completes and issues an interrupt
- The processor switches to hypervisor mode
- The hypervisor now decides which VM the interrupt is for
- The hypervisor then proceeds to present the virtualised hardware to the VM in a ready state
- The processor is switched to kernel mode and the interrupt is passed to the VM
- The VM carries out its usual execution process such as calling the appropriate interrupt service routine (ISR)
note
When an interrupt does occur and the processor is in hypervisor mode the hypervisor can take this time to schedule which VM should run next.
This behaviour is very much like how the OS scheduler works
name 4
types of virtualisation which are not in relation to the OS
these include:
- Virtual runtime environments
- Hardware/machine emulation
- Application virtualisation
- Network virtualisation
describe a
vm switch
an action carried out by the hypervisor that allows it to switch between the different virtual machines by saving and restoring there state.
This is a similar behaviour of an OS context switch
This is a key feature of containers and is what allows a container to create its own file system.
Any changes the container makes to the underlying file system will be held here and then a merged view can be presented to the container such that:
base file system + this = merged view of file system
describe the
overlay file system
This is open source container manager software that comes with everything needed to create and manage containers including the docker daemon that is used to start and stop containers
what is
docker
this view of a container can be summarised as:
it will share the file system of the base OS however any changes made are not made to the base OS instead a layer known as the overlay file system will keep track of any changes and present it to the container with a merged view of the OS file system and the overlay file system
describe the
file system view
of a container
describe the term
hypervisor
software that can emulate hardware and present it to a virtual machine
one example of this is the Java virtual machine (JVM) that creates an environment for code to execute in
this will offer functionality similar to the OS such as memory management and process scheduling but is an application that runs on top the OS
describe an example of
Virtual runtime environments
what is
docker
This is open source container manager software that comes with everything needed to create and manage containers including the docker daemon that is used to start and stop containers
describe the term
Virtual machine manager
software that is used to create and run and mange virtual machines
example
virtual box
describe the structure of a type 2 hypervisor being used and its bene
When a virtual machine manager creates a VM a hypervisor will also be installed as a device driver on the host OS.

benefit
This gives the hypervisor kernel privileges so that it can directly speak to hardware and the OS
to make use of containers what must have support for them
these must be supported by the OS
- Known as partitions in windows
- Jails in BSD-based versions of linux
software that is used to create and run and mange virtual machines
example
virtual box
describe the term
Virtual machine manager
describe the
system view
that a container will have
this view from the containers perspective
it will only be able to see the parts of the system it has access to
running any system commands will only reveal the parts of the system it has been allocated to use
the 6 steps for this scenario include:
- An I/O operation issued by a VM completes and issues an interrupt
- The processor switches to hypervisor mode
- The hypervisor now decides which VM the interrupt is for
- The hypervisor then proceeds to present the virtualised hardware to the VM in a ready state
- The processor is switched to kernel mode and the interrupt is passed to the VM
- The VM carries out its usual execution process such as calling the appropriate interrupt service routine (ISR)
note
When an interrupt does occur and the processor is in hypervisor mode the hypervisor can take this time to schedule which VM should run next.
This behaviour is very much like how the OS scheduler works
give the 6 steps of the following scenario
an I/O operation issued by a virtual machine that has completed
describe 2 examples of
Network virtualisation
using vlans and virtual switches as the example
examples of this include:
- Virtual local area networks (VLANS) - where all clients can be plugged into the same switch but are logically separated so they appear to be on different networks and in turn cannot see each other
- Virtual switches - a database and a web server can be installed on the same system. Since communication must occur through networking protocols a virtual switch can be used in place of making use of actual networking hardware and so performance is increased
describe how a containers merged view of a file system would look when there is
- no change made by the container
- a modification by the container to the original file on the host file system
- a deleted file by the container
- a created file by the container
each of these actions are summarised below

This is a virtualisation solution that will create what are known as containers.
Each container can run one or more applications and shares the underlying kernel and file system.
However each container is unaware that it is a container and believes it has sole control of the system
describe
containerisation
examples of this include:
- Virtual local area networks (VLANS) - where all clients can be plugged into the same switch but are logically separated so they appear to be on different networks and in turn cannot see each other
- Virtual switches - a database and a web server can be installed on the same system. Since communication must occur through networking protocols a virtual switch can be used in place of making use of actual networking hardware and so performance is increased
describe 2 examples of
Network virtualisation
using vlans and virtual switches as the example
describe an example of
Virtual runtime environments
one example of this is the Java virtual machine (JVM) that creates an environment for code to execute in
this will offer functionality similar to the OS such as memory management and process scheduling but is an application that runs on top the OS
When a virtual machine manager creates a VM a hypervisor will also be installed as a device driver on the host OS.

benefit
This gives the hypervisor kernel privileges so that it can directly speak to hardware and the OS
describe the structure of a type 2 hypervisor being used and its bene
advantages of this include:
- fast execution - Are fast to run as a kernel does not need to be loaded it is already running
- conflict avoidance - Dependency hell can be avoided as each container has its own file system via the overlay file system and can be updated independently
- Lightweight - as they can contain only what is needed to run the applications within the container and can also share resources already on the base OS
give 3
advantages of containers
what is the
docker hub
this is a repository offered by docker where pre built containers can be downloaded from