Topic 20 – Virtualisation Flashcards

1
Q

how is

hardware support for virtualistaion acheived

A

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 well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

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

A

describe the

system view

that a container will have

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

describe the

file system view

of a container

A

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

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

give 1 advantage that an

overlay file system brings for containers

A

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
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

describe the term

merged view file system

A

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
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

describe the term

copy on write

A

a method for modifying files while maintaining the original file.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

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

A

describe a

hypervisor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

This is also known as a hosted hypervisor and is software that will run as a device driver on the host OS.

A

describe a

type 2 hypervisor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

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.

A

describe

Hardware/machine emulation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

describe

Application virtualisation

A

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

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

software that can emulate hardware and present it to a virtual machine

A

describe the term

hypervisor

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

describe the term

overlay file system

A

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
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

these include:

  • Virtual runtime environments
  • Hardware/machine emulation
  • Application virtualisation
  • Network virtualisation
A

name 4

types of virtualisation which are not in relation to the OS

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

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
A

describe the term

overlay file system

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

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

A

describe a

vm switch

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

each of these actions are summarised below

A

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
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

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

A

describe

Application virtualisation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

how can an

overlay file system for a container be implemented

A

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 well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

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

A

how is

hardware support for virtualistaion acheived

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

describe

containerisation

A

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

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

upon a

VM switch

what information would be saved/restored

A

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
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

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
A

what does docker require in order to run and how is this problem solved for:

  • linux
  • macOS
  • windows
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

describe a

hypervisor

A

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

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

properties of this include:

  1. Isolation - Applications or even full operating systems can be ran alongside each other without any knowledge of the others existence
    1. Has the benefit of protection from malware or system corruption
    2. Different instances of the same application can be run but serve separate purposes
    3. Each can mange there own files
    4. Upgrades can be achieved on a container or vm basis and only affect that instance
  2. Management - can be easily managed without any disturbance to other running processes
    1. Start, stop or pause
    2. Add/remove resources such as memory or processing time
  3. Encapsulation - any data created can be encapsulated into a file and imported and exported to different systems
  4. Flexibility - the ability to quickly create and destroy different environments is a great benefit in development of applications or for testing purposes
A

give 4

properties that virtualisation has

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
this is a repository offered by docker where pre built containers can be downloaded from
what is the ## Footnote **docker hub**
26
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
27
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 ## Footnote **container**
28
a method for modifying files while maintaining the original file.
describe the term ## Footnote **copy on write**
29
this is as the diagram below
describe the ## Footnote **structure of the system when using containers**
30
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
31
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
32
describe the ## Footnote **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
33
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 ## Footnote **merged view file system**
34
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
35
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 ## Footnote **overlay file system for a container be implemented**
36
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 ## Footnote **overlay file system brings for containers**
37
describe ## Footnote **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.
38
give 4 ## Footnote **properties that virtualisation has**
properties of this include: 1. **Isolation -** Applications or even full operating systems can be ran alongside each other without any knowledge of the others existence 1. Has the benefit of protection from malware or system corruption 2. Different instances of the same application can be run but serve separate purposes 3. Each can mange there own files 4. Upgrades can be achieved on a container or vm basis and only affect that instance 2. **Management -** can be easily managed without any disturbance to other running processes 1. Start, stop or pause 2. Add/remove resources such as memory or processing time 3. **Encapsulation -** any data created can be encapsulated into a file and imported and exported to different systems 4. **Flexibility** - the ability to quickly create and destroy different environments is a great benefit in development of applications or for testing purposes
39
give 3 points about the processor ## Footnote **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
40
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 ## Footnote **hypervisor mode**
41
describe the term ## Footnote **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
42
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
43
describe a ## Footnote **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.
44
describe the ## Footnote **structure of the system when using containers**
this is as the diagram below
45
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
46
give the 6 steps of the following scenario ## Footnote **an I/O operation issued by a virtual machine that has completed**
the 6 steps for this scenario include: 1. An I/O operation issued by a VM completes and issues an interrupt 2. The processor switches to hypervisor mode 3. The hypervisor now decides which VM the interrupt is for 4. The hypervisor then proceeds to present the virtualised hardware to the VM in a ready state 5. The processor is switched to kernel mode and the interrupt is passed to the VM 6. 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
47
name 4 ## Footnote **types of virtualisation which are not in relation to the OS**
these include: * Virtual runtime environments * Hardware/machine emulation * Application virtualisation * Network virtualisation
48
describe a ## Footnote **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
49
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 ## Footnote **overlay file system**
50
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 ## Footnote **docker**
51
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
52
describe the term ## Footnote **hypervisor**
software that can emulate hardware and present it to a virtual machine
53
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 ## Footnote **Virtual runtime environments**
54
what is ## Footnote **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
55
describe the term ## Footnote **Virtual machine manager**
software that is used to create and run and mange virtual machines _example_ virtual box
56
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. ## Footnote _benefit_ This gives the hypervisor kernel privileges so that it can directly speak to hardware and the OS
57
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
58
software that is used to create and run and mange virtual machines _example_ virtual box
describe the term ## Footnote **Virtual machine manager**
59
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
60
the 6 steps for this scenario include: 1. An I/O operation issued by a VM completes and issues an interrupt 2. The processor switches to hypervisor mode 3. The hypervisor now decides which VM the interrupt is for 4. The hypervisor then proceeds to present the virtualised hardware to the VM in a ready state 5. The processor is switched to kernel mode and the interrupt is passed to the VM 6. 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 ## Footnote **an I/O operation issued by a virtual machine that has completed**
61
describe 2 examples of **Network virtualisation** using vlans and virtual switches as the example
examples of this include: 1. **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 2. **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
62
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
63
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 ## Footnote **containerisation**
64
examples of this include: 1. **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 2. **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
65
describe an example of ## Footnote **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
66
When a virtual machine manager creates a VM a hypervisor will also be installed as a device driver on the host OS. ## Footnote _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
67
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**
68
what is the ## Footnote **docker hub**
this is a repository offered by docker where pre built containers can be downloaded from