SlideShare ist ein Scribd-Unternehmen logo
1 von 23
EC2                                                                               API Layer                 CloudStack


                                                                                                          Access Control
Virtual Machine Manager




                                                              Console Proxy Manager




                                                                                                                                                       Async Job Manager
                                            Network Manager




                                                                                                                                                                               Template Manager
                                                                                       Snapshot Manager
                          Storage Manager




                                                                                                                     …

                                                                                                          Agent Manager

XenServer                                     KVM                                     vSphere                   SRX           F5           NetScaler                         OVM
Resource                                    Resource                                  Resource                Resource     Resource        Resource                        Resource
Cloud                                                        Other
  UI                                              CLI                            Clients
                    Portal




                                                     Management Server
                                                             REST API
       OAM&P API                     End User API           EC2 API      Other APIs           Pluggable Service API Engine


Console Proxy                               ACL & Authentication                                   Security Adapters
Management                 -        Accounts, Domains, and Projects
                           -        ACL, limits checking                                         Account Management
                                                                                                     Connectors
  Template                                       Services API
   Access
                                                                                                 Deployment Planning




                                                                                 Plugin API
       HA
                                                        Kernel                                                                Job
                                     -     Drives long running VM
                                                                                                                             Queue
                     Services API




                                                                                                Network Configurations
    Usage                                  operations
 Calculations                        -     Syncs between resources
                                           managed and DB                                          Network Elements
 Additional                          -     Generates events
  Services
                                                                                                   Hypervisor Gurus


     Cluster                         Resource                 Job               Alert & Event              Database
   Management                       Management             Management           Management                  Access
                                                                                                                              DB

                                                                         Event Bus
                                                          Message Bus

       Hypervisor                         Network             Storage             Image                 Snapshot
       Resources                         Resources           Resources          Resources               Resources
Kernel Module
• Understands how to orchestrate long running
  processes (i.e. VM starts, Snapshot copies,
  Template propagation)
• Well defined process steps
• Calls Plugin API to execute functionalities that
  it needs
Plugins
• Various ways to add more capability to
  CloudStack
• Implements clearly defined interfaces
• All operations must be idempotent
• All calls are at transaction boundaries
• Compiles only against the Plugin API module
Anatomy of a Plugin


                                      Rest API
-       Optional. Required only if needs to expose configuration API to admin.   ServerResource
                                                                                 -   Optional. Required if
                                                                                     Plugin needs to be co-
                                                                                     located with the
                                                                                     resource
                                                                                 -   Implements translation
                                                                                     layer to talk to resource
                                                                                 -   Communicates with
Plugin API




                                    Implmentation                                    server component via
                                                                                     JSON




                                     Data Access Layer
Anatomy of a Plugin
• Can be two jars: server component to be
  deployed on management server and an optional
  ServerResource component to be deployed co-
  located with the resource
• Server component can implement multiple Plugin
  APIs to affect its feature
• Can expose its own API through Pluggable Service
  so administrators can configure the plugin
• As an example, OVS plugin actually implements
  both NetworkGuru and NetworkElement
Plugin Interfaces Available
• NetworkGuru – Implements various network isolation technologies
  and ip address technologies
• NetworkElement – Facilitate network services on network elements
  to support a VM (i.e. DNS, DHCP, LB, VPN, Port Forwarding, etc)
• DeploymentPlanner – Different algorithms to place a VM and
  volumes.
• Investigator – Ways to find out if a host is down or VM is down.
• Fencer – Ways to fence off a VM if the state is unknown
• UserAuthenticator – Methods of authenticating a user
• SecurityChecker – ACL access
• HostAllocator – Provides different ways to allocate host
• StoragePoolAllocator – Provides different ways to allocate volumes
Adding a Plugin to CloudStack
• Components are configured though
  components.xml
• Supports DAO, Manager, and Adapter patterns
• Open to other component frameworks (OSGi a
  possibility)
Components.xml Example
<components.xml>
    <system-integrity-checker class="com.cloud.upgrade.DatabaseUpgradeChecker">
        <checker name="ManagementServerNode" class="com.cloud.cluster.ManagementServerNode"/>
        <checker name="EncryptionSecretKeyChecker"
class="com.cloud.utils.crypt.EncryptionSecretKeyChecker"/>
        <checker name="DatabaseIntegrityChecker" class="com.cloud.upgrade.DatabaseIntegrityChecker"/>
        <checker name="DatabaseUpgradeChecker" class="com.cloud.upgrade.PremiumDatabaseUpgradeChecker"/>
    </system-integrity-checker>
   <interceptor library="com.cloud.configuration.DefaultInterceptorLibrary"/>
    <management-server class="com.cloud.server.ManagementServerExtImpl"
library="com.cloud.configuration.PremiumComponentLibrary">
        <adapters key="com.cloud.storage.allocator.StoragePoolAllocator">
            <adapter name="LocalStorage" class="com.cloud.storage.allocator.LocalStoragePoolAllocator"/>
            <adapter name="Storage" class="com.cloud.storage.allocator.FirstFitStoragePoolAllocator"/>
        </adapters>
    <pluggableservice name="VirtualRouterElementService"
key="com.cloud.network.element.VirtualRouterElementService"
class="com.cloud.network.element.VirtualRouterElement"/>
    </management-server>
</components.xml>
Sequence Flow for deploy VM                                             Kernel
                          End User         Security          User VM       VirtualMac       Network              Storage   Network      Job
                          Rest API         Checkers            Mgr          hine Mgr          Mgr                  Mgr      Guru     Scheduling
   Deploy VM
                                ACL Checks

                                     Allocate Entity in CS

                                                                  Allocate VM

                                                                                 Allocate NIC

                                                                                                   Allocate IP

                                                                                 Allocate Volume


                                Schedules Deploy Job


 Returns with job id, VM id


 Query Job Result


Returns with job status
Sequence Flow for deploy VM
                                                                                                                                      Deploymen    Server
                                User VM      VirtualMac     Network         Storage       Network         Network         Template         t
Job Threads     Services API                                                                                                                      Resources
                                  Mgr         hine Mgr        Mgr             Mgr          Guru           Element           Mgr        Planner



        Start VM

                       Start User VM

                                       Start VM

                                                   Get a Deployment Plan (Host and StoragePool)

                                                   Prepare Nics

                                                                     Reserve resources for Nic

                                                                      Notify that Nic is about to be started in network

                                                                                                                 Agent Calls

                                                   Prepare Volumes


                                                                                   Prepare template on Primary Storage
                                                                                                                               Agent Calls
                                                   Agent Start VM Call

       Stores job result
ServerResource
• Translation layer between CloudStack
  commands and resource API
• May be Co-located with resource
• Have no access to DB
• API defined in JSON messages
DAO
• SQL generation done mostly in GenericDaoBase
• Uses JPA annotations
• Very little code to write for each individual DAO
• Database Access Layer for Kernel
• No support for more complicated features such
  as fetch strategy
• Welcome to use other types of ORM in other
  modules but like to hear about preferred library.
  (Hibernate is out due to licensing issues)
Example DAO
// ExampleVO.java                     // ExampleDao.java
@Entity                               public interface ExampleDao
@Table(name=“example”)                    extends GenericDao<ExampleVO, Long> {
public class ExampleVO {              }
    @Id
    @GeneratedValue(strategy=         // ExampleDaoImpl.java
GenerationType.IDENTITY)              @Local(value=ExampleDao.class)
    @Column(name=“id”)                public class ExampleDaoImpl
    long id;                              extends GenericDaoBase<ExampleVO, Long>
                                          implements ExampleDao {
    @Column(name=“name”)
    String name;                          protected ExampleDaoImpl() {
                                          }
    @Column(name=“value”)             }
    String value;
}
Triggering High Availability
VM HA are triggered via the following methods:
• VM Sync detects out of band VM death
• Resource Management detects that a resource is
  unreachable and its state can not be determined.
• VM start/stop has been sent to the resource but
  resource does not return
• Details of how high availability is done is at
  http://docs.cloudstack.org/CloudStack_Documentation/Design_Documents/CloudStack_High_Availability_-
  _Developer's_Guide
High Availability Future
• Moving toward using the native HA capability
  of the hypervisor.
• Looking to do more in the DRS area to
  coordinate recovery of wide spread outage.
VM Sync
•   Currently a sync of VM state, not entire VM
•   VM Sync happens between management server and hypervisor resources
•   Peer-to-peer sync
•   Hypervisor DB is considered to be the DB of truth
•   Two steps:
    – Full Sync
    – Intermittent delta sync
• Establishes full sync when first connecting to the hypervisor resource
• After full sync, hypervisor resource keeps track of the last sync results and
  only report out of band changes on delta sync
• Utilizes the most abundant resources in data center: CPU and memory
• Conserve the most scarce resource: DB connections
• Virtually no DB connections utilized during delta sync unless there are out
  of band changes.
Storage
                                                                 Zone-Level Layer 3 Switch               Private Network




Pod 1                                                                         Pod 2          Pod N
                        Pod-Level Layer-2 Switch
                                                                                                     …
                                                                                                                    Scale-Out NFS
               Computing Server
                      1                       Primary Storage
   Cluster 2




               Computing Server
                      2                        Primary Storage



               Computing Server
                      3
   Cluster 1




                                               Primary Storage

               Computing Server
                      4
Storage
• CloudStack supports two types of storage
  – Primary Storage: block device to the VM
  – WORM Storage: Secondary or Object Store for
    templates, ISO, and snapshot archiving
• Primary storage is high on IOPs (expensive)
• Secondary storage is high on capacity (cheap)
• CloudStack manages the storage between the
  two to achieve maximum benefit and
  resiliency
Disk Offering
• Disk Offering is how disks are offered to the
  end user
• Disk Offering has storage tags which can be
  used to implementing storage tiering
• Service Offering actually contains a disk
  offering for the root disk
Snapshots
• Snapshots are used as backups
• Taken on the primary storage and moved to
  secondary storage
• Full snapshots on VmWare and KVM. Need
  help.
• Incremental snapshots on XenServer
XenServer Snapshot

 Base Copy

                           Full1   Full2


D1           Template


                           S11     S21
D2             S1


                           S12     S22
VM             S2


                           S13     S23
Storage Future
•   Secondary Storage multi-homed in Pod
•   Object Store for between zones
•   Direct Access to Storage for enterprise
•   Storage Plugins

Weitere ähnliche Inhalte

Was ist angesagt?

Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
Virtualization in the Cloud @ Build a Cloud Day SFO May 2012Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
The Linux Foundation
 
Christian ferver xen server_6.1_overview
Christian ferver xen server_6.1_overviewChristian ferver xen server_6.1_overview
Christian ferver xen server_6.1_overview
Digicomp Academy AG
 
Xen Cloud Platform at Build a Cloud Day at SCALE 10x
Xen Cloud Platform at Build a Cloud Day at SCALE 10x Xen Cloud Platform at Build a Cloud Day at SCALE 10x
Xen Cloud Platform at Build a Cloud Day at SCALE 10x
The Linux Foundation
 
Xen Project Update LinuxCon Brazil
Xen Project Update LinuxCon BrazilXen Project Update LinuxCon Brazil
Xen Project Update LinuxCon Brazil
The Linux Foundation
 
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCPOscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
The Linux Foundation
 

Was ist angesagt? (20)

CloudStack-Developer-Day
CloudStack-Developer-DayCloudStack-Developer-Day
CloudStack-Developer-Day
 
CloudStack Architecture Future
CloudStack Architecture FutureCloudStack Architecture Future
CloudStack Architecture Future
 
Xen and Apache cloudstack
Xen and Apache cloudstack  Xen and Apache cloudstack
Xen and Apache cloudstack
 
DevCloud and CloudMonkey
DevCloud and CloudMonkeyDevCloud and CloudMonkey
DevCloud and CloudMonkey
 
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 PreviewCloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
CloudStack DC Meetup - Apache CloudStack Overview and 4.1/4.2 Preview
 
2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-1
2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-12012 CloudStack Design Camp in Taiwan--- CloudStack Overview-1
2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-1
 
12th Japan CloudStack User Group Meetup MidoNet with scalable virtual router
12th Japan CloudStack User Group Meetup   MidoNet with scalable virtual router12th Japan CloudStack User Group Meetup   MidoNet with scalable virtual router
12th Japan CloudStack User Group Meetup MidoNet with scalable virtual router
 
Apache CloudStack AlpesJUG
Apache CloudStack AlpesJUGApache CloudStack AlpesJUG
Apache CloudStack AlpesJUG
 
Decisions behind hypervisor selection in CloudStack 4.3
Decisions behind hypervisor selection in CloudStack 4.3Decisions behind hypervisor selection in CloudStack 4.3
Decisions behind hypervisor selection in CloudStack 4.3
 
BACD July 2012 : The Xen Cloud Platform
BACD July 2012 : The Xen Cloud Platform BACD July 2012 : The Xen Cloud Platform
BACD July 2012 : The Xen Cloud Platform
 
Scale11x : Virtualization with Xen and XCP
Scale11x : Virtualization with Xen and XCP Scale11x : Virtualization with Xen and XCP
Scale11x : Virtualization with Xen and XCP
 
CloudStack Networking at CloudOpen Japan
CloudStack Networking at CloudOpen JapanCloudStack Networking at CloudOpen Japan
CloudStack Networking at CloudOpen Japan
 
Xen in the Cloud at SCALE 10x
Xen in the Cloud at SCALE 10xXen in the Cloud at SCALE 10x
Xen in the Cloud at SCALE 10x
 
Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
Virtualization in the Cloud @ Build a Cloud Day SFO May 2012Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
Virtualization in the Cloud @ Build a Cloud Day SFO May 2012
 
Christian ferver xen server_6.1_overview
Christian ferver xen server_6.1_overviewChristian ferver xen server_6.1_overview
Christian ferver xen server_6.1_overview
 
Xen Cloud Platform at Build a Cloud Day at SCALE 10x
Xen Cloud Platform at Build a Cloud Day at SCALE 10x Xen Cloud Platform at Build a Cloud Day at SCALE 10x
Xen Cloud Platform at Build a Cloud Day at SCALE 10x
 
Xen Project Update LinuxCon Brazil
Xen Project Update LinuxCon BrazilXen Project Update LinuxCon Brazil
Xen Project Update LinuxCon Brazil
 
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCPOscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
Oscon 2012 : From Datacenter to the Cloud - Featuring Xen and XCP
 
XCP: The Art of Open Virtualization for the Enterprise and the Cloud
XCP: The Art of Open Virtualization for the Enterprise and the CloudXCP: The Art of Open Virtualization for the Enterprise and the Cloud
XCP: The Art of Open Virtualization for the Enterprise and the Cloud
 
Art of Using Xen at Scale
Art of Using Xen at ScaleArt of Using Xen at Scale
Art of Using Xen at Scale
 

Andere mochten auch

CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief ComparisonCloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
bizalgo
 

Andere mochten auch (11)

Silicon Valley CloudStack User Group - Introduction to Apache CloudStack
Silicon Valley CloudStack User Group - Introduction to Apache CloudStackSilicon Valley CloudStack User Group - Introduction to Apache CloudStack
Silicon Valley CloudStack User Group - Introduction to Apache CloudStack
 
Designing CloudStack Clouds
Designing CloudStack CloudsDesigning CloudStack Clouds
Designing CloudStack Clouds
 
Gartner report on cloud360 cloud management platform
Gartner report on cloud360 cloud management platformGartner report on cloud360 cloud management platform
Gartner report on cloud360 cloud management platform
 
Cloud management (IBM)
Cloud management (IBM)Cloud management (IBM)
Cloud management (IBM)
 
Introduction to CloudStack
Introduction to CloudStack Introduction to CloudStack
Introduction to CloudStack
 
Presentation cloud management platform
Presentation   cloud management platformPresentation   cloud management platform
Presentation cloud management platform
 
Comparing open source private cloud platforms
Comparing open source private cloud platformsComparing open source private cloud platforms
Comparing open source private cloud platforms
 
CloudStack vs OpenStack
CloudStack vs OpenStackCloudStack vs OpenStack
CloudStack vs OpenStack
 
CloudStack vs Openstack
CloudStack vs OpenstackCloudStack vs Openstack
CloudStack vs Openstack
 
7 Common Questions About a Cloud Management Platform
7 Common Questions About a Cloud Management Platform7 Common Questions About a Cloud Management Platform
7 Common Questions About a Cloud Management Platform
 
CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief ComparisonCloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
CloudStack vs OpenStack vs Eucalyptus: IaaS Private Cloud Brief Comparison
 

Ähnlich wie Management server internals

Mach Technology
Mach Technology Mach Technology
Mach Technology
Open Stack
 
VMware Performance for Gurus - A Tutorial
VMware Performance for Gurus - A TutorialVMware Performance for Gurus - A Tutorial
VMware Performance for Gurus - A Tutorial
Richard McDougall
 
Operating the Hyperscale Cloud
Operating the Hyperscale CloudOperating the Hyperscale Cloud
Operating the Hyperscale Cloud
Open Stack
 
Configurando Private Cloud con System Center 2012
Configurando Private Cloud con System Center 2012Configurando Private Cloud con System Center 2012
Configurando Private Cloud con System Center 2012
Juanchi_43
 
Building Cloud-Aware Applications
Building Cloud-Aware ApplicationsBuilding Cloud-Aware Applications
Building Cloud-Aware Applications
Chris Haddad
 
PHP Day 2011 PHP goes to the cloud
PHP Day 2011 PHP goes to the cloudPHP Day 2011 PHP goes to the cloud
PHP Day 2011 PHP goes to the cloud
pietrobr
 
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
OpenCity Community
 

Ähnlich wie Management server internals (20)

2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-2
2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-22012 CloudStack Design Camp in Taiwan--- CloudStack Overview-2
2012 CloudStack Design Camp in Taiwan--- CloudStack Overview-2
 
Paving the Way to IT-as-a-Service
Paving the Way to IT-as-a-ServicePaving the Way to IT-as-a-Service
Paving the Way to IT-as-a-Service
 
CloudStack Collaboration Conference 12; Refactoring cloud stack
CloudStack Collaboration Conference 12; Refactoring cloud stackCloudStack Collaboration Conference 12; Refactoring cloud stack
CloudStack Collaboration Conference 12; Refactoring cloud stack
 
The role of hyper-v in nist model
The role of hyper-v in nist modelThe role of hyper-v in nist model
The role of hyper-v in nist model
 
CloudStack Intro NYC
CloudStack Intro NYCCloudStack Intro NYC
CloudStack Intro NYC
 
10 Minute Overview of Apache CloudStack
10 Minute Overview of Apache CloudStack10 Minute Overview of Apache CloudStack
10 Minute Overview of Apache CloudStack
 
Citrix CloudStack - Build Your Own Scalable Infrastructure Cloud with CloudStack
Citrix CloudStack - Build Your Own Scalable Infrastructure Cloud with CloudStackCitrix CloudStack - Build Your Own Scalable Infrastructure Cloud with CloudStack
Citrix CloudStack - Build Your Own Scalable Infrastructure Cloud with CloudStack
 
Private cloud day session 4 automating and delivering services in your privat...
Private cloud day session 4 automating and delivering services in your privat...Private cloud day session 4 automating and delivering services in your privat...
Private cloud day session 4 automating and delivering services in your privat...
 
Venus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScienceVenus-c: Using open source clouds in eScience
Venus-c: Using open source clouds in eScience
 
Private Cloud Day Session 1: Building your Private Cloud Infrastructure
Private Cloud Day Session 1: Building your Private Cloud InfrastructurePrivate Cloud Day Session 1: Building your Private Cloud Infrastructure
Private Cloud Day Session 1: Building your Private Cloud Infrastructure
 
Mach Technology
Mach Technology Mach Technology
Mach Technology
 
Brief about Windows Azure Platform
Brief about Windows Azure Platform Brief about Windows Azure Platform
Brief about Windows Azure Platform
 
Building a cloud with cisco ucs and citrix
Building a cloud with cisco ucs and citrixBuilding a cloud with cisco ucs and citrix
Building a cloud with cisco ucs and citrix
 
VMware Performance for Gurus - A Tutorial
VMware Performance for Gurus - A TutorialVMware Performance for Gurus - A Tutorial
VMware Performance for Gurus - A Tutorial
 
Operating the Hyperscale Cloud
Operating the Hyperscale CloudOperating the Hyperscale Cloud
Operating the Hyperscale Cloud
 
Configurando Private Cloud con System Center 2012
Configurando Private Cloud con System Center 2012Configurando Private Cloud con System Center 2012
Configurando Private Cloud con System Center 2012
 
Configuring and deploying a private cloud with system center 2012
Configuring and deploying a private cloud with system center 2012Configuring and deploying a private cloud with system center 2012
Configuring and deploying a private cloud with system center 2012
 
Building Cloud-Aware Applications
Building Cloud-Aware ApplicationsBuilding Cloud-Aware Applications
Building Cloud-Aware Applications
 
PHP Day 2011 PHP goes to the cloud
PHP Day 2011 PHP goes to the cloudPHP Day 2011 PHP goes to the cloud
PHP Day 2011 PHP goes to the cloud
 
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
Dell open stack powered cloud solution introduce & crowbar demo cosug-2012
 

Mehr von CloudStack - Open Source Cloud Computing Project

vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
vBACD - Introduction to Puppet, Configuration Management and IT Automation So...vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
CloudStack - Open Source Cloud Computing Project
 
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
CloudStack - Open Source Cloud Computing Project
 

Mehr von CloudStack - Open Source Cloud Computing Project (19)

Apache CloudStack from API to UI
Apache CloudStack from API to UIApache CloudStack from API to UI
Apache CloudStack from API to UI
 
CloudStack Hyderabad Meetup: How the Apache community works
CloudStack Hyderabad Meetup: How the Apache community worksCloudStack Hyderabad Meetup: How the Apache community works
CloudStack Hyderabad Meetup: How the Apache community works
 
CloudStack Hyderabad Meetup: Migrating applications to IaaS clouds
CloudStack Hyderabad Meetup: Migrating applications to IaaS cloudsCloudStack Hyderabad Meetup: Migrating applications to IaaS clouds
CloudStack Hyderabad Meetup: Migrating applications to IaaS clouds
 
Introduction to CloudStack: How to Deploy and Manage Infrastructure-as-a-Serv...
Introduction to CloudStack: How to Deploy and Manage Infrastructure-as-a-Serv...Introduction to CloudStack: How to Deploy and Manage Infrastructure-as-a-Serv...
Introduction to CloudStack: How to Deploy and Manage Infrastructure-as-a-Serv...
 
vBACD July 2012 - Apache Hadoop, Now and Beyond
vBACD July 2012 - Apache Hadoop, Now and BeyondvBACD July 2012 - Apache Hadoop, Now and Beyond
vBACD July 2012 - Apache Hadoop, Now and Beyond
 
vBACD July 2012 - Scaling Storage with Ceph
vBACD July 2012 - Scaling Storage with CephvBACD July 2012 - Scaling Storage with Ceph
vBACD July 2012 - Scaling Storage with Ceph
 
vBACD July 2012 - Deploying Private PaaS with ActiveState Stackato
vBACD July 2012 - Deploying Private PaaS with ActiveState StackatovBACD July 2012 - Deploying Private PaaS with ActiveState Stackato
vBACD July 2012 - Deploying Private PaaS with ActiveState Stackato
 
vBACD July 2012 - Xen Cloud Platform
vBACD July 2012 - Xen Cloud PlatformvBACD July 2012 - Xen Cloud Platform
vBACD July 2012 - Xen Cloud Platform
 
vBACD- July 2012 - Crash Course in Open Source Cloud Computing
vBACD- July 2012 - Crash Course in Open Source Cloud ComputingvBACD- July 2012 - Crash Course in Open Source Cloud Computing
vBACD- July 2012 - Crash Course in Open Source Cloud Computing
 
Virtualization in the cloud
Virtualization in the cloudVirtualization in the cloud
Virtualization in the cloud
 
Build a Cloud Day San Francisco - Ubuntu Cloud
Build a Cloud Day San Francisco - Ubuntu CloudBuild a Cloud Day San Francisco - Ubuntu Cloud
Build a Cloud Day San Francisco - Ubuntu Cloud
 
CloudStack Scalability
CloudStack ScalabilityCloudStack Scalability
CloudStack Scalability
 
Cloudstack UI Customization
Cloudstack UI CustomizationCloudstack UI Customization
Cloudstack UI Customization
 
CloudStack Networking
CloudStack NetworkingCloudStack Networking
CloudStack Networking
 
vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
vBACD - Introduction to Puppet, Configuration Management and IT Automation So...vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
vBACD - Introduction to Puppet, Configuration Management and IT Automation So...
 
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
vBACD - Distributed Petabyte-Scale Cloud Storage with GlusterFS - 2/28
 
vBACD - Crash Course in Open Source Cloud Computing - 2/28
vBACD - Crash Course in Open Source Cloud Computing - 2/28vBACD - Crash Course in Open Source Cloud Computing - 2/28
vBACD - Crash Course in Open Source Cloud Computing - 2/28
 
vBACD - Introduction to Opscode Chef - 2/29
vBACD - Introduction to Opscode Chef - 2/29vBACD - Introduction to Opscode Chef - 2/29
vBACD - Introduction to Opscode Chef - 2/29
 
vBACD - Deploying Infrastructure-as-a-Service with CloudStack - 2/28
vBACD - Deploying Infrastructure-as-a-Service with CloudStack - 2/28vBACD - Deploying Infrastructure-as-a-Service with CloudStack - 2/28
vBACD - Deploying Infrastructure-as-a-Service with CloudStack - 2/28
 

Kürzlich hochgeladen

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Kürzlich hochgeladen (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 

Management server internals

  • 1. EC2 API Layer CloudStack Access Control Virtual Machine Manager Console Proxy Manager Async Job Manager Network Manager Template Manager Snapshot Manager Storage Manager … Agent Manager XenServer KVM vSphere SRX F5 NetScaler OVM Resource Resource Resource Resource Resource Resource Resource
  • 2. Cloud Other UI CLI Clients Portal Management Server REST API OAM&P API End User API EC2 API Other APIs Pluggable Service API Engine Console Proxy ACL & Authentication Security Adapters Management - Accounts, Domains, and Projects - ACL, limits checking Account Management Connectors Template Services API Access Deployment Planning Plugin API HA Kernel Job - Drives long running VM Queue Services API Network Configurations Usage operations Calculations - Syncs between resources managed and DB Network Elements Additional - Generates events Services Hypervisor Gurus Cluster Resource Job Alert & Event Database Management Management Management Management Access DB Event Bus Message Bus Hypervisor Network Storage Image Snapshot Resources Resources Resources Resources Resources
  • 3. Kernel Module • Understands how to orchestrate long running processes (i.e. VM starts, Snapshot copies, Template propagation) • Well defined process steps • Calls Plugin API to execute functionalities that it needs
  • 4. Plugins • Various ways to add more capability to CloudStack • Implements clearly defined interfaces • All operations must be idempotent • All calls are at transaction boundaries • Compiles only against the Plugin API module
  • 5. Anatomy of a Plugin Rest API - Optional. Required only if needs to expose configuration API to admin. ServerResource - Optional. Required if Plugin needs to be co- located with the resource - Implements translation layer to talk to resource - Communicates with Plugin API Implmentation server component via JSON Data Access Layer
  • 6. Anatomy of a Plugin • Can be two jars: server component to be deployed on management server and an optional ServerResource component to be deployed co- located with the resource • Server component can implement multiple Plugin APIs to affect its feature • Can expose its own API through Pluggable Service so administrators can configure the plugin • As an example, OVS plugin actually implements both NetworkGuru and NetworkElement
  • 7. Plugin Interfaces Available • NetworkGuru – Implements various network isolation technologies and ip address technologies • NetworkElement – Facilitate network services on network elements to support a VM (i.e. DNS, DHCP, LB, VPN, Port Forwarding, etc) • DeploymentPlanner – Different algorithms to place a VM and volumes. • Investigator – Ways to find out if a host is down or VM is down. • Fencer – Ways to fence off a VM if the state is unknown • UserAuthenticator – Methods of authenticating a user • SecurityChecker – ACL access • HostAllocator – Provides different ways to allocate host • StoragePoolAllocator – Provides different ways to allocate volumes
  • 8. Adding a Plugin to CloudStack • Components are configured though components.xml • Supports DAO, Manager, and Adapter patterns • Open to other component frameworks (OSGi a possibility)
  • 9. Components.xml Example <components.xml> <system-integrity-checker class="com.cloud.upgrade.DatabaseUpgradeChecker"> <checker name="ManagementServerNode" class="com.cloud.cluster.ManagementServerNode"/> <checker name="EncryptionSecretKeyChecker" class="com.cloud.utils.crypt.EncryptionSecretKeyChecker"/> <checker name="DatabaseIntegrityChecker" class="com.cloud.upgrade.DatabaseIntegrityChecker"/> <checker name="DatabaseUpgradeChecker" class="com.cloud.upgrade.PremiumDatabaseUpgradeChecker"/> </system-integrity-checker> <interceptor library="com.cloud.configuration.DefaultInterceptorLibrary"/> <management-server class="com.cloud.server.ManagementServerExtImpl" library="com.cloud.configuration.PremiumComponentLibrary"> <adapters key="com.cloud.storage.allocator.StoragePoolAllocator"> <adapter name="LocalStorage" class="com.cloud.storage.allocator.LocalStoragePoolAllocator"/> <adapter name="Storage" class="com.cloud.storage.allocator.FirstFitStoragePoolAllocator"/> </adapters> <pluggableservice name="VirtualRouterElementService" key="com.cloud.network.element.VirtualRouterElementService" class="com.cloud.network.element.VirtualRouterElement"/> </management-server> </components.xml>
  • 10. Sequence Flow for deploy VM Kernel End User Security User VM VirtualMac Network Storage Network Job Rest API Checkers Mgr hine Mgr Mgr Mgr Guru Scheduling Deploy VM ACL Checks Allocate Entity in CS Allocate VM Allocate NIC Allocate IP Allocate Volume Schedules Deploy Job Returns with job id, VM id Query Job Result Returns with job status
  • 11. Sequence Flow for deploy VM Deploymen Server User VM VirtualMac Network Storage Network Network Template t Job Threads Services API Resources Mgr hine Mgr Mgr Mgr Guru Element Mgr Planner Start VM Start User VM Start VM Get a Deployment Plan (Host and StoragePool) Prepare Nics Reserve resources for Nic Notify that Nic is about to be started in network Agent Calls Prepare Volumes Prepare template on Primary Storage Agent Calls Agent Start VM Call Stores job result
  • 12. ServerResource • Translation layer between CloudStack commands and resource API • May be Co-located with resource • Have no access to DB • API defined in JSON messages
  • 13. DAO • SQL generation done mostly in GenericDaoBase • Uses JPA annotations • Very little code to write for each individual DAO • Database Access Layer for Kernel • No support for more complicated features such as fetch strategy • Welcome to use other types of ORM in other modules but like to hear about preferred library. (Hibernate is out due to licensing issues)
  • 14. Example DAO // ExampleVO.java // ExampleDao.java @Entity public interface ExampleDao @Table(name=“example”) extends GenericDao<ExampleVO, Long> { public class ExampleVO { } @Id @GeneratedValue(strategy= // ExampleDaoImpl.java GenerationType.IDENTITY) @Local(value=ExampleDao.class) @Column(name=“id”) public class ExampleDaoImpl long id; extends GenericDaoBase<ExampleVO, Long> implements ExampleDao { @Column(name=“name”) String name; protected ExampleDaoImpl() { } @Column(name=“value”) } String value; }
  • 15. Triggering High Availability VM HA are triggered via the following methods: • VM Sync detects out of band VM death • Resource Management detects that a resource is unreachable and its state can not be determined. • VM start/stop has been sent to the resource but resource does not return • Details of how high availability is done is at http://docs.cloudstack.org/CloudStack_Documentation/Design_Documents/CloudStack_High_Availability_- _Developer's_Guide
  • 16. High Availability Future • Moving toward using the native HA capability of the hypervisor. • Looking to do more in the DRS area to coordinate recovery of wide spread outage.
  • 17. VM Sync • Currently a sync of VM state, not entire VM • VM Sync happens between management server and hypervisor resources • Peer-to-peer sync • Hypervisor DB is considered to be the DB of truth • Two steps: – Full Sync – Intermittent delta sync • Establishes full sync when first connecting to the hypervisor resource • After full sync, hypervisor resource keeps track of the last sync results and only report out of band changes on delta sync • Utilizes the most abundant resources in data center: CPU and memory • Conserve the most scarce resource: DB connections • Virtually no DB connections utilized during delta sync unless there are out of band changes.
  • 18. Storage Zone-Level Layer 3 Switch Private Network Pod 1 Pod 2 Pod N Pod-Level Layer-2 Switch … Scale-Out NFS Computing Server 1 Primary Storage Cluster 2 Computing Server 2 Primary Storage Computing Server 3 Cluster 1 Primary Storage Computing Server 4
  • 19. Storage • CloudStack supports two types of storage – Primary Storage: block device to the VM – WORM Storage: Secondary or Object Store for templates, ISO, and snapshot archiving • Primary storage is high on IOPs (expensive) • Secondary storage is high on capacity (cheap) • CloudStack manages the storage between the two to achieve maximum benefit and resiliency
  • 20. Disk Offering • Disk Offering is how disks are offered to the end user • Disk Offering has storage tags which can be used to implementing storage tiering • Service Offering actually contains a disk offering for the root disk
  • 21. Snapshots • Snapshots are used as backups • Taken on the primary storage and moved to secondary storage • Full snapshots on VmWare and KVM. Need help. • Incremental snapshots on XenServer
  • 22. XenServer Snapshot Base Copy Full1 Full2 D1 Template S11 S21 D2 S1 S12 S22 VM S2 S13 S23
  • 23. Storage Future • Secondary Storage multi-homed in Pod • Object Store for between zones • Direct Access to Storage for enterprise • Storage Plugins