Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and...
Transcript of Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and...
![Page 1: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/1.jpg)
Lecture - 2 and 3 Virtualization, Orchestration and
Design of Cloud Services
Salman Toor [email protected]
![Page 2: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/2.jpg)
Outline• Introduction to virtualization
• Importance
• Types
• Hardware support
• Hypervisors
• libvirt API ?
2
• Cloud virtualization
• Demo
• Virtualization beyond VMs
• Orchestration Tools
• Design of Cloud services
![Page 3: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/3.jpg)
Virtualization• Nutshell: The abstraction of available resources
• Definition:
• Whereas, resources can be either compute, storage, network..etc
3
Virtualizationtechnologiesencompassavarietyofmechanismsandtechniquesusedtodecouplethearchitectureanduser-perceivedbehaviorofhardwareandsoftwareresourcesfromtheirphysicalimplementation.
http://www.computer.org/csdl/mags/co/2005/05/r5028.html
![Page 4: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/4.jpg)
Virtualization Basic illustration
4http://blog.cloudpassage.com/2011/07/22/the-difference-between-virtualization-and-cloud-computing/
Virtualizationlayer
![Page 5: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/5.jpg)
Virtualization• Large verity of platforms:
• Old concept, relaunched (article from 1974)
• Properties of virtual machines (VM) • Efficiency • Resource control • Equivalance
5
https://en.wikipedia.org/wiki/Comparison_of_platform_virtualization_software
http://cs.nyu.edu/courses/fall14/CSCI-GA.3033-010/popek-goldberg.pdf
![Page 6: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/6.jpg)
Virtualization• Virtualization Layer
• Types of Hypervisors
• Bare-Metal • Hosted
6
HypervisororVirtualMachineMonitor(VMM)isasoftwarethatprovidesaninterfacebetweenhardwareandvirtualoperatingsystems.
Hardware
Hypervisor
OS-1 OS-2 OS-N
Bare-Metal
Hardware
OperatingSystem
Processes Hypervisor
Hosted
OS-1 OS-N
![Page 7: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/7.jpg)
Virtualization • Virtualization could address following issues:
• Under-utilized resources
• Complicated system management
• Limited access to shared resources
• inefficient power consumption
• Tight coupling with underlying resources
• …
7
![Page 8: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/8.jpg)
Virtualization
8
CPU
OperatingSystem
APP-1 APP-2 APP-N
Multi-tasking
CPU-1
OperatingSystem
APP-1 APP-2 APP-N
Multi-coreorHyper-threading
CPU-2
VirtualCPU-1
OperatingSystem
APP-1 APP-2 APP-N
VirtualCPU-2
OperatingSystem
APP-1 APP-2 APP-N
Virtualization
VirtualCPU-N
OperatingSystem
APP-1 APP-2 APP-N
http://www.hardwaresecrets.com/everything-you-need-to-know-about-the-intel-virtualization-technology/
![Page 9: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/9.jpg)
Virtualization Types
• Platform virtualization
• Memory virtualization
• Desktop virtualization
• Application virtualization
• Network virtualization
• Storage virtualization
9
![Page 10: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/10.jpg)
Virtualization Platform virtualization
• Full virtualization
• Para virtualization
• Hardware assisted virtualization
• Operating-System (OS) level virtualization
• Hybrid virtualization
10http://www.vmware.com/files/pdf/VMware_paravirtualization.pdf
![Page 11: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/11.jpg)
Virtualization Full
• Guest operating system (VM) is unaware of host OS
• Non-critical instructions run directly on hardware
• Runtime translation of critical non-virtualizable instructions in hypervisor
• Not best in performance
11
![Page 12: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/12.jpg)
Virtualization Para
• Thin layer interfaces between each guest OS and underlying hardware
• Need Guest kernel modification
• No need of runtime translation for critical instructions
• Superior in performance
• Requires expertise to patch the kernels
12
![Page 13: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/13.jpg)
Virtualization Hardware assisted
• Hardware provides support to run instructions independently
• No need to patch the kernels
• Runtime translations not required
• Better performance in comparison to other variants
• Greater stability
13
![Page 14: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/14.jpg)
Virtualization OS level
• Same OS for both Host and guest machines
• Userspace is completely isolated
• High performance
• Extremely light-weight
• Recently acquire lots of attention in Cloud world
14
![Page 15: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/15.jpg)
Virtualization Hybrid
• Combination of • para • hardware assisted virtualization
• Address the issues related to security and system stability
• Use patched guest OS along with hardware support
15
![Page 16: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/16.jpg)
Virtualization Memory
• Brings concepts of consolidation and cost effectiveness
• Managed with virtualizing physical memory by addition of an extra level of address translation
16
physicalmemory
CPU-0 CPU-1 CPU-1 CPU-1
VM-1 VM-2
VMmainmemory VMmainmemory
Question: Is “virtual memory” concept in a single operating system same as the concept of virtualization in terms of VMs?
Answer:NO
![Page 17: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/17.jpg)
Virtualization Desktop and Applications
• Desktop and Applications run on servers
• Stateless thin clients connected to servers
• Efficient system management
• Requires high-end servers for system stability
17
![Page 18: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/18.jpg)
Virtualization Network and Storage
• Similar idea of providing an abstraction layer to the physical infrastructures
• In networks abstraction will be at the level of
• Storage abstraction allows single backends to be used for different requirements
18
• Routers• Switches• loadbalances
• Gateway• Firewalls• …
• Ephemeral• Persistant• Specializestoragebackends
![Page 19: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/19.jpg)
Virtualization Network and Storage
• Aim is to provide provides:
• Efficient infrastructure utilization • Agility • Isolation • Security • ….
19
![Page 20: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/20.jpg)
Virtualization Hardware Acceleration
• Aims:
• enhance the performance • reduce the complexity in the hypervisors/VMM
• Intel and AMD chips support VT
• Intel models
• AMD model
20
http://ark.intel.com/Products/VirtualizationTechnology
http://support.amd.com/en-us/kb-articles/Pages/GPU120AMDRVICPUsHyperVWin8.aspx
![Page 21: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/21.jpg)
Virtualization Concept of overcommits
• Process of allocating more than the available physical resources
• Common types:
• CPU Overcommits • Memory Overcommits • Storage Overcommits
• Strong requirement from infrastructure providers
21
![Page 22: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/22.jpg)
Virtualization Concept of overcommits
• Pros:
• Favorable economic model • Efficient resources utilization • Support green computing
• Cons:
• Performance loss or unstable system response • Complex system understanding • VM shutdown by the hypervisor (extreme cases)
22
![Page 23: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/23.jpg)
Virtualization CPU overcommit
• Allows more virtual CPUs than physically available
• Example: In case of 8 physical cores
• Open stack KVM allows:
23
8 * overcommit-number = total-number-of-virtual-CPUs
overcommit-number = 16.0 (max) , 1.0 (no overcommits)
http://docs.openstack.org/kilo/config-reference/content/section_compute-scheduler.html
![Page 24: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/24.jpg)
Virtualization Memory overcommit
• Allocate more than physical memory
• Open stack KVM allows:
• 1.5 GB is required by the instance • can run on any physical host having1GB free memory
24http://docs.openstack.org/kilo/config-reference/content/section_compute-scheduler.html
overcommit-number = 1.5GB
![Page 25: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/25.jpg)
Virtualization Hypervisors
• Contribution from industry and academia
• Xen • Project from Cambridge Computer Laboratory
• VMware • Commercial product
• KVM (Kernel-based Virtual Machine) • A product of Open Virtualization Alliance (OVA)
• Qemu • Opensource machine emulator and virtualizer
• …..
25
http://www.xenproject.org/developers/teams/hypervisor.htmlhttp://www.vmware.com/https://openvirtualizationalliance.org/what-kvmhttp://wiki.qemu.org/Main_Page
![Page 26: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/26.jpg)
Virtualization KVM
• Hypervisor for x86 solutions with complete hardware support
• Run multiple guest OSes with private virtualized hardware: network card, memory, disk etc
• Consist of Loadable kernel modules:
• kvm.ko for core virtualization • processor specific kvm-intel.ko or kvm- amd.ko
26
![Page 27: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/27.jpg)
Virtualization Tools KVM
• Opensource software
• Support Linux and Windows (limited)
• Peripheral support to the guest OS
• Wide variety of management tools
• Backend for compute resources in many Cloud suites
• Allow resources overcommits
27
![Page 28: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/28.jpg)
Virtualization Tools KVM
28http://www-03.ibm.com/systems/kvm/whykvm.html
• KVM architecture for x86 system
• support nested virtual machines
![Page 29: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/29.jpg)
Virtualization Tools Qemu
• Qemu runs in following modes:
• Emulator; hypervisor runs in the user space • Hypervisor; Hardware supported virtualization
(KQemu)
• Support for multiple OSes
• Based on Xen or KVM, Qemu supports nested virtualization
29http://wiki.qemu.org/Main_Page
![Page 30: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/30.jpg)
Virtualization Tools Qemu
• Opensource software
• Extensive peripheral support
• Diversity of management tools
• Backend for compute resources in many Cloud suites
• Recommended for testing and development environments
30
![Page 31: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/31.jpg)
Virtualization Tools Qemu
31
Hardware
HostOperatingSystem
QEMU QEMU
VM-1 VM-2
Hardware
HostOperatingSystem
QEMU QEMU
VM-1 VM-2
KVMmodule
QemuEmulator QemuwithKVMsupport
![Page 32: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/32.jpg)
Virtualization Tools VMware
• Commercial product by VMware.Inc
• One of the leading server virtualization system
• frontend
• Variety of system management components
• Backend for compute resources in number of Cloud software
32
![Page 33: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/33.jpg)
Virtualization Tools VMware
• VMware vSphere consists of:
• VMware ESXi • VMware vCenter Server • VMware VMFS • VMware Virtual SMP • VMware Clients (Desktop and Web access)
• ESXi is the virtualization platform
• vCenter Server is a service that act as a administrator to ESXi platform
33http://pubs.vmware.com/vsphere-51/topic/com.vmware.vsphere.vcenterhost.doc/GUID-302A4F73-CA2D-49DC-8727-81052727A763.html
![Page 34: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/34.jpg)
Virtualization Tools VMware
• Overview Architecture
34http://www.vmware.com/pdf/vi_architecture_wp.pdf
• Comprehensive solution for data center virtualization
•
![Page 35: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/35.jpg)
Role of LIBVIRT API• Virtualization API
• Provide a common and stable layer to securely communicate with guest OS
• Supports all major hypervisors
• Open source project for secure VM management tasks
• Used to build applications based on virtual environment
35http://libvirt.org/
![Page 36: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/36.jpg)
Virtualization Interesting Articles
• A quantitative comparison between xen and kvm (2010 J. Phys.: Conf. Ser. 219
042005)
• Performance Measuring and Comparing of Virtual Machine Monitors (2008 IEEE/IFIP International Conference on Embedded and Ubiquitous Computing)
• Recommendations for Virtualization Technologies in High Performance Computing (2nd IEEE International Conference on Cloud Computing Technology and Science)
• A Comparison of Software and Hardware Techniques for x86 Virtualization (Advance level) (ASPLOS XII Proceedings of the 12th international
conference on Architectural support for programming languages and operating systems)
36
![Page 37: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/37.jpg)
Virtualization and Clouds OpenStack
• Open source platform for build public and private Clouds
37http://www.openstack.org/
![Page 38: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/38.jpg)
OpenStack Compute
• OpenStack Compute Project (NOVA)
38
Hardware
VMware
KVM Qemu LXC
Docker
LibvirtAPIs
OpenStackNovaAPI operatingsystem
Computehost
![Page 39: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/39.jpg)
Cloud Virtualization Storage
• OpenStack volume (Cinder) • OpenStack object store (Swift)
39Disk-1 Disk-1 Disk-1 Disk-1
Ceph
lib-rbd
CinderGlanceNova
lib-rgw
Swift
libvirt
SNICCloudStoragebackend
![Page 40: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/40.jpg)
Cloud Virtualization Network
• OpenStack network components (Neutron)
40
![Page 41: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/41.jpg)
Cloud Virtualization Network
• OpenStack network components (Neutron)
41http://docs.openstack.org/networking-guide/
![Page 42: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/42.jpg)
DEMO
42
![Page 43: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/43.jpg)
DOES VIRTUALIZATION EFFECT THE SYSTEM PERFORMANCE?
43
![Page 44: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/44.jpg)
Performance• Yes performance loss may occur but it is highly
dependent on
• Type of virtualization layer (Hypervisor) • Use case
• CPU bound application will perform differently than IO bound or network intensive applications
44
![Page 45: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/45.jpg)
Performance• In comparison with the
physical node: • KVM perform 83.46% • Xen perform 97.28%
• Reason; Critical instruction test verses para-virtualization
45Performance Measuring and Comparing of Virtual Machine Monitors (2008 IEEE/IFIP International Conference on Embedded and Ubiquitous Computing)
In both cases, There is a performance different compare to physical machine.
![Page 46: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/46.jpg)
Performance• ApplicafonLevel
• 4%performancelossevaluatedwiththe• HEPSPEC-2006(ThankstoUlfTigerstedt,CSCforhelp
withHEPSPECtests)• SystemLevel
• VMbootresponsebothatlocalvsGlusterFSbasedsetup
46Article:AscalableinfrastructureforCMSdataanalysisbasedonOpenStackCloudandGlusterfilesystem
![Page 47: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/47.jpg)
Images and formats • Cloud images are customized disks images of OSes for
private or public clouds
• Different formats are available: • raw: An unstructured disk image format (big in size) • vhd: VMware, Xen, Microsoft, VirtualBox, and others • vdi: Supported by VirtualBox, QEMU emulator. • iso: Archive format for the data contents of an optical disc • qcow2: Supported by the QEMU emulator that can
expand dynamically and supports Copy on Write. • …
47http://docs.openstack.org/image-guide/content/image-formats.html
![Page 48: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/48.jpg)
Contextualization
In cloud computing contextualization means providing customized computing environment
Or
Allows a virtual machine instance to learn about its cloud environment and user requirement (the ‘context’) and configure itself to run correctly
48http://www.journalofcloudcomputing.com/content/4/1/17
![Page 49: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/49.jpg)
Contextualization• Provide scalable solution
• No need to manage fat images
• Dynamic configuration
• Typically work in two layers • Meta-data : System information handled at cloud level • User-defined-data: User specific requirements/
settings
49
![Page 50: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/50.jpg)
Beyond Virtual Machines
50
![Page 51: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/51.jpg)
Containers• OS level virtualization environment
• Kernelspace is shared • Userspace is separate for each linux system
(container)
• A lightweight alternative to Virtual Machines (VM)
• Shared same resources as host OS
• A simple model for packaging applications in Linux.
51https://linuxcontainers.org/
![Page 52: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/52.jpg)
Basic Illustration of Containers
52
LinuxbasedhostOS NonLinuxhostOSUbuntu
ContainerController
ContainerEngine
Con-1Con-N
Con-2
WindowsorMAC
ContainerController
ContainerEngine
Con-1Con-N
Con-2
LinuxVM
![Page 53: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/53.jpg)
VM and Containers
• Complete isolation • Big in size • High overhead • Flexible support of multiple
OSes • Greater stability both for
hypervisors and VMs • Better security
53
• Application level abstraction • Lightweight • Works well with Linux, limited
support for Windows • Weak security • Significant management Overhead • Not well suited for large applications • Important for micro-services design
VirtualMachine Containers
ItsisimportanttounderstandthatVMsandContainersshouldnotbeviewedascompetitors
![Page 54: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/54.jpg)
LXC• LinuX Container (LXC) is an open source software
• Virtual environment based on separate memory, CPU, network, io etc
• Similar to the concept of chroot
• Used in most of the container based orchestration tools
• LXD is a newer version of LXC, advanced and stronger support for cloud plugins
54http://blog.scottlowe.org/2013/11/25/a-brief-introduction-to-linux-containers-with-lxc/
![Page 55: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/55.jpg)
Container Softwares• OpenVZ
• Virtuozzo (Linux and Windows)
• Solaris Containers (Solaris)
• Spoon (Windows)
• VMware ThinApp (Windows)
55
![Page 56: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/56.jpg)
ORCHESTRATION TOOLS
56
![Page 57: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/57.jpg)
Orchestration • Orchestration is a process of resource contextualization based on the
automation available in the cloud systems.
• A process required for • rapid application deployment • scalability • management • high availability • Agility
• Essential for large complex applications
• A process at the level of Platform as a Service (PaaS)
![Page 58: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/58.jpg)
Orchestration• Available tools
• CoreOS https://coreos.com/ • OpenShift https://www.openshift.com • Docker https://www.docker.com/ • Kubernetes http://kubernetes.io/ • Molns (used in Lab-2) • Heat https://wiki.openstack.org/wiki/Heat
58
![Page 59: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/59.jpg)
HEAT • OpenStack based orchestration software to create a
human- and machine-accessible services
• Consist of template base orchestration engine
• Enables simple or composite cloud applications based on existing services
• Compatible with AWS Cloud Foundation
59https://wiki.openstack.org/wiki/Heat
![Page 60: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/60.jpg)
HEAT Template example
60
heat_template_version:2014-10-16description:Asimpleserver.parameters:ImageID:type:stringdescription:ImageusetobootaserverNetID:type:stringdescription:NetworkIDfortheserverresources:server:type:OS::Nova::Serverproperties:image:{get_param:ImageID}flavor:m1.tinynetworks:-network:{get_param:NetID}outputs:private_ip:description:IPaddressoftheserverintheprivatenetworkvalue:{get_attr:[server,first_address]}
#heatstack-create-ftest-stack.yml-P"ImageID=cirros-0.3.4-x86_64;NetID=$NET_ID"testStack
http://docs.openstack.org/kilo/install-guide/install/yum/content/heat-verify.html
![Page 61: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/61.jpg)
Docker• Docker package an application together with all its dependencies in
the container • Guarantees that it will always run the same regardless of the
environment • Container based orchestration tool • Docker Hub, container registory • Open source
61https://www.docker.com/whatisdocker
![Page 62: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/62.jpg)
Docker• Docker Hub, container registry
• Image repository
• Automated Builds
• Webhooks
• Organizations
• Github and Bitbucket integrations
62https://docs.docker.com/docker-hub/
![Page 63: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/63.jpg)
Kubernetes• Google supported orchestration software
• Open source
• Supported in public, private and multi-cloud environments
• Currently supported for Linux platform
• Support Docker containers
63
![Page 64: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/64.jpg)
Cloud Services Design • Cloud service architecture should adhere with following features:
• Scalability
• Security
• Fault tolerant
• Vendor agnostic
• Elasticity
• Leverage different backends
64
• Loosely coupled components
• ….
![Page 65: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/65.jpg)
Cloud Services Design • Scalability
• Horizontal scaling • Vertical scaling
• Security
• Multi level security • Authorisation • Authentication
65
![Page 66: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/66.jpg)
Cloud Services Design • Fault-Tolerance
• Recover from failover and unexpected short interruptions
• Vendor Agnostic
• No dependency on vendor specific tools
66
![Page 67: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/67.jpg)
Cloud Services Design• Elasticity
• Dynamically adopt according to the requirements
• Support for different backends
• Flexible enough to accommodate different users requirements
67
![Page 68: Lecture - 2 and 3 Virtualization, Orchestration and Design ...Virtualization, Orchestration and Design of Cloud Services Salman Toor salman.toor@it.uu.se. Outline ... • VM boot response](https://reader033.fdocuments.us/reader033/viewer/2022042310/5ed7a41c48b98015c2020ba5/html5/thumbnails/68.jpg)
Cloud Services Design • Loosely coupled service model
• Components should not tightly connected with each other
• Work as micro and macro services
• ….
68