SlideShare a Scribd company logo
CloudStack Metering
Working with the Usage Data
Tariq Iqbal
Senior Consultant
tariq.iqbal@shapeblue.com
Twitter: @TariqIqbal_ @ShapeBlue
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 Involved with CloudStack before donation to Apache
 Built and deployed CloudStack/CloudPlatform based clouds for
Enterprises and Service Providers globally
 Specialise in integrating CloudStack with Business Support and
Operational Support systems, which include:
 CloudPortals (including Payment Gateways, Fraud Control solutions)
 Ticketing Systems
 CRM/ERP Systems
 Monitoring Solutions
About Me
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
“ShapeBlue are expert builders of public & private
clouds. They are the leading global independent
CloudStack / CloudPlatform integrator &
consultancy”
About ShapeBlue
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 CloudStack metering - What and how?
 CloudStack configuration to enable Usage capture
 Usage Data generation process
 Methods of accessing the Usage Data
 Real World Use Cases
Overview
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 Organisations need to be able to meter their cloud's
consumption and monetize the cloud offerings by charging for
usage
 Majority of organisations already have existing billing or business
support systems and just need access to CloudStack Usage Data
 Organisations tend to have different billing criteria and charging
models requiring a comprehensive integrated solution
Metering Requirements
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
CloudStack Usage?
CloudStack Metering
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 CloudStack does not offer any integrated usage monitoring or
billing/chargeback capability
 Root Admin can view
System Capacity
 Domain Admin and Users can view
VM status
Metering in CloudStack today
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 CloudStack includes a Usage Server that creates summary usage records for
the various resources consumed in CloudStack
 The Usage Server is an optional, separately-installed component called
‘cloudstack-usage’
 The Usage Server runs at least once per day. It can be configured to run
multiple times per day and it’s behaviour is controlled by the following global
configuration settings:
•
Cloud Usage Server
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 As CloudStack resources are created, consumed and
destroyed, appropriate Event records are created in the ‘cloud’
database table: usage_events
 There are 110
different Events:
(51 shown)
CloudStack Events
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The Usage Server schedules a job at the time specified by
usage.stats.job.exec.time parameter. This job queries the ‘cloud’
database table: usage_events and generates summary usage records in
the ‘cloud_usage’ database table: cloud_usage as follows:
1. CloudStack events have been logged into the cloud.usage_event table
2. cloudstack_usage job gets a list of the latest usage events
3. Inserts the latest usage events into the cloud_usage.usage_events table
4. Helper tables populated from cloud_usage.usage_event table after
parsing
5. cloud_usage.cloud_usage table populated with aggregation range wise
data. Helper table data is used here
Usage Record Generation
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The Usage Server collects 14 different types of resource usage:
Usage Types
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The Usage Records show the amount of resources consumed by guest instances.
 The Usage Record format for Allocated & Running VMs is shown below:
 The other 7 Usage Record formats are:
 Network Usage
 IP Address
 Disk Volume
 Template, ISO & Snapshot
 Load Balancer & Port Fwd
 Network Offering
 VPN User
Usage Records
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
Usage Record Example
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
Accessing Usage Data
CloudStack Metering
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The usage records can be accessed through the CloudStack API
 This is best done using the authentication port 8080 and requires
both the API Key and Secret Key and for the API request to be
signed
 CloudStack provides the following Usage API calls with Root
Admin access and supports XML and JSON response formats
 listUsageTypes – list of Usage Types accessible
 generateUsageRecords - asynchronous usage record generation
 listUsageRecords - provides Usage records for a date range
CloudStack API
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The base command is:
http://<HOST>:<8080>/client/api?command=listUsageRecords&startdate=y
yyy-MM-dd&enddate=yyyy-MM-dd&signature
 Append the various options:
ListUsageRecords API
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 <listusagerecordsresponse>
<count>1</count>
<usagerecord>
<account>user5</account>
<accountid>10004</accountid>
<domainid>1</domainid>
<zoneid>1</zoneid>
<description>i-3-4-WC running time (Service Offering: 1) (Template: 3)</description>
<usage>2.95288 Hrs</usage>
<usagetype>1</usagetype>
<rawusage>2.95288</rawusage>
<virtualmachineid>4</virtualmachineid>
<name>i-3-4-WC</name>
<offeringid>1</offeringid>
<templateid>3</templateid>
<usageid>245554</usageid>
<type>XenServer</type>
<startdate>2009-09-15T00:00:00-0700</startdate>
<enddate>2009-09-18T16:14:26-0700</enddate>
</usagerecord>
</listusagerecordsresponse>
ListUsageRecords Response
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 CloudMonkey is a CLI tool for CloudStack and can be used as an
interactive shell or from within a shell script to call the API
 It can output the Usage Data in both JSON and Tabular form to a
file or pipe it to another application for further processing
 Filtering can be used to limit the result set
 It supports argument passing and shell automation
 The host, port, apikey and secretkey can be configured on setup
CloudMonkey CLI
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
CloudMonkey list usagerecords
The command to retrieve Usage Records is:
cloudmonkey list usagerecords domainid=7ded1404-d7fc-11e2-a70f-
080027cfaf0b startdate=2013-06-01 enddate=2013-06-23 accountid=2
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 The usage records can be also accessed by directly querying the
cloud_usage.cloud_usage MySQL table in CloudStack
 Usage Data can be exported in a CSV format from a SELECT
query
 The SQL query can become complex if the ID fields in the data
need to be de-referenced
 Typically multiple passes of the query results may be required to
extract the required information
SQL
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 Once you are able to access the Usage Data, you will need to
design the mapping between the fields in the CloudStack Usage
Data and the fields of the target system.
 Considerations:
 Do you actually need all the Usage Data for all Resources?
 Any UUID values of the CloudStack resources should also be
imported into the target system for reference purposes
 Decide which system will be the master for the user account data
and if synchronisation is required
Mediation
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
Real World Use Cases
CloudStack Metering
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 MS Excel can be used to analyse CloudStack Usage Records
 The usage records are imported from the cloud_usage.
cloud_usage table into MS Excel via an MySQL ODBC connection
 Either PivotTables or reports can be used to present the data.
 This is convenient and
great for integration
testing between CloudStack
and external systems.
MS Excel
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 Citrix CloudPortal Business Manager tightly integrates with the
cloud_usage database on CloudStack/CloudPlatform.
 The Usage Data is cross referenced against the utility pricing and
subscription pricing in CPBM.
 Scheduled Billing and Invoicing jobs generate the invoices in XML
or PDF based on the
tenants billing cycle.
Citrix CloudPortal
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 splunk> is an operational intelligence tool that was initially used
for collecting and indexing infrastructure logs
 We then connected splunk> to the CloudStack Usage database
and automated the collection and indexing of Usage Data
 Setup feature-rich dashboards
and the capability to drill down into
the Usage Data for BI reporting
splunk>
@ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013
 CloudStack Developers Guide, API Documentation & Wiki:
 http://cloudstack.apache.org/
 CloudMonkey
 https://cwiki.apache.org/CLOUDSTACK/cloudstack-cloudmonkey-
cli.html
 How to Use MS Excel to Analyze CloudStack Usage Records:
 http://support.citrix.com/article/CTX132030
 CloudStack Mailing Lists (Users, Development, Marketing):
 http://cloudstack.apache.org/mailing-lists.html
Further Information
CloudStack Metering
Working with the Usage Data
Tariq Iqbal
Senior Consultant
tariq.iqbal@shapeblue.com
Twitter: @TariqIqbal_ @ShapeBlue

More Related Content

What's hot

Azure Data Factory presentation with links
Azure Data Factory presentation with linksAzure Data Factory presentation with links
Azure Data Factory presentation with links
Chris Testa-O'Neill
 
Building a Lambda Architecture with Elasticsearch at Yieldbot
Building a Lambda Architecture with Elasticsearch at YieldbotBuilding a Lambda Architecture with Elasticsearch at Yieldbot
Building a Lambda Architecture with Elasticsearch at Yieldbot
yieldbot
 
Hands-on Lab: Data Lake Analytics
Hands-on Lab: Data Lake AnalyticsHands-on Lab: Data Lake Analytics
Hands-on Lab: Data Lake Analytics
Amazon Web Services
 
Building a fully-automated Fast Data Platform
Building a fully-automated Fast Data PlatformBuilding a fully-automated Fast Data Platform
Building a fully-automated Fast Data Platform
Manuel Sehlinger
 
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
Matt Stubbs
 
Data Modeling and Relational to NoSQL
Data Modeling and Relational to NoSQLData Modeling and Relational to NoSQL
Data Modeling and Relational to NoSQL
DATAVERSITY
 
SQL to Azure Migrations
SQL to Azure MigrationsSQL to Azure Migrations
SQL to Azure Migrations
Datavail
 
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent OzarGeek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
IDERA Software
 
Solutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
Solutions for bi-directional Integration between Oracle RDMBS & Apache KafkaSolutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
Solutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
Guido Schmutz
 
The hidden engineering behind machine learning products at Helixa
The hidden engineering behind machine learning products at HelixaThe hidden engineering behind machine learning products at Helixa
The hidden engineering behind machine learning products at Helixa
Alluxio, Inc.
 
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
Big Data Week
 
Confluent & Attunity: Mainframe Data Modern Analytics
Confluent & Attunity: Mainframe Data Modern AnalyticsConfluent & Attunity: Mainframe Data Modern Analytics
Confluent & Attunity: Mainframe Data Modern Analytics
confluent
 
Cloud sim report
Cloud sim reportCloud sim report
Cloud sim report
Jiachen Yang
 
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
Sergey Smetanin
 
Migrating on premises workload to azure sql database
Migrating on premises workload to azure sql databaseMigrating on premises workload to azure sql database
Migrating on premises workload to azure sql database
PARIKSHIT SAVJANI
 
Big Data LDN 2017: The Streaming Transformation
Big Data LDN 2017: The Streaming TransformationBig Data LDN 2017: The Streaming Transformation
Big Data LDN 2017: The Streaming Transformation
Matt Stubbs
 
Streaming Visualization
Streaming VisualizationStreaming Visualization
Streaming Visualization
Guido Schmutz
 
Fully fault tolerant real time data pipeline with docker and mesos
Fully fault tolerant real time data pipeline with docker and mesos Fully fault tolerant real time data pipeline with docker and mesos
Fully fault tolerant real time data pipeline with docker and mesos
Rahul Kumar
 
Modern big data and machine learning in the era of cloud, docker and kubernetes
Modern big data and machine learning in the era of cloud, docker and kubernetesModern big data and machine learning in the era of cloud, docker and kubernetes
Modern big data and machine learning in the era of cloud, docker and kubernetes
Slim Baltagi
 

What's hot (19)

Azure Data Factory presentation with links
Azure Data Factory presentation with linksAzure Data Factory presentation with links
Azure Data Factory presentation with links
 
Building a Lambda Architecture with Elasticsearch at Yieldbot
Building a Lambda Architecture with Elasticsearch at YieldbotBuilding a Lambda Architecture with Elasticsearch at Yieldbot
Building a Lambda Architecture with Elasticsearch at Yieldbot
 
Hands-on Lab: Data Lake Analytics
Hands-on Lab: Data Lake AnalyticsHands-on Lab: Data Lake Analytics
Hands-on Lab: Data Lake Analytics
 
Building a fully-automated Fast Data Platform
Building a fully-automated Fast Data PlatformBuilding a fully-automated Fast Data Platform
Building a fully-automated Fast Data Platform
 
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
Big Data LDN 2017: Look Ma, No Code! Building Streaming Data Pipelines With A...
 
Data Modeling and Relational to NoSQL
Data Modeling and Relational to NoSQLData Modeling and Relational to NoSQL
Data Modeling and Relational to NoSQL
 
SQL to Azure Migrations
SQL to Azure MigrationsSQL to Azure Migrations
SQL to Azure Migrations
 
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent OzarGeek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
Geek Sync | Planning a SQL Server to Azure Migration in 2021 - Brent Ozar
 
Solutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
Solutions for bi-directional Integration between Oracle RDMBS & Apache KafkaSolutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
Solutions for bi-directional Integration between Oracle RDMBS & Apache Kafka
 
The hidden engineering behind machine learning products at Helixa
The hidden engineering behind machine learning products at HelixaThe hidden engineering behind machine learning products at Helixa
The hidden engineering behind machine learning products at Helixa
 
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
BDW16 London - Scott Krueger, skyscanner - Does More Data Mean Better Decisio...
 
Confluent & Attunity: Mainframe Data Modern Analytics
Confluent & Attunity: Mainframe Data Modern AnalyticsConfluent & Attunity: Mainframe Data Modern Analytics
Confluent & Attunity: Mainframe Data Modern Analytics
 
Cloud sim report
Cloud sim reportCloud sim report
Cloud sim report
 
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
Firebase Realtime Database and Remote Config in Practice - DroidCon Moscow 2016
 
Migrating on premises workload to azure sql database
Migrating on premises workload to azure sql databaseMigrating on premises workload to azure sql database
Migrating on premises workload to azure sql database
 
Big Data LDN 2017: The Streaming Transformation
Big Data LDN 2017: The Streaming TransformationBig Data LDN 2017: The Streaming Transformation
Big Data LDN 2017: The Streaming Transformation
 
Streaming Visualization
Streaming VisualizationStreaming Visualization
Streaming Visualization
 
Fully fault tolerant real time data pipeline with docker and mesos
Fully fault tolerant real time data pipeline with docker and mesos Fully fault tolerant real time data pipeline with docker and mesos
Fully fault tolerant real time data pipeline with docker and mesos
 
Modern big data and machine learning in the era of cloud, docker and kubernetes
Modern big data and machine learning in the era of cloud, docker and kubernetesModern big data and machine learning in the era of cloud, docker and kubernetes
Modern big data and machine learning in the era of cloud, docker and kubernetes
 

Similar to CloudStack Metering – Working with the Usage Data

Working with CloudStack Usage Data - CCCEU13
Working with CloudStack Usage Data - CCCEU13Working with CloudStack Usage Data - CCCEU13
Working with CloudStack Usage Data - CCCEU13
ShapeBlue
 
Cloudstack autoscaling
Cloudstack autoscalingCloudstack autoscaling
Cloudstack autoscaling
ShapeBlue
 
cloud computing documentation
cloud computing documentationcloud computing documentation
cloud computing documentation
shilpa bojji
 
Cloudstack collaboration - customer focus
Cloudstack collaboration - customer focusCloudstack collaboration - customer focus
Cloudstack collaboration - customer focus
ShapeBlue
 
Whats the Use!? (Real Customer Use-Cases)
Whats the Use!? (Real Customer Use-Cases)Whats the Use!? (Real Customer Use-Cases)
Whats the Use!? (Real Customer Use-Cases)
ShapeBlue
 
CloudStack 101 CCCEU13
CloudStack 101 CCCEU13CloudStack 101 CCCEU13
CloudStack 101 CCCEU13
ShapeBlue
 
Accelerating Time-to-Value Through Hybrid Cloud Automation
Accelerating Time-to-Value Through Hybrid Cloud AutomationAccelerating Time-to-Value Through Hybrid Cloud Automation
Accelerating Time-to-Value Through Hybrid Cloud Automation
Cognizant
 
Citrix cloud platform 4.2 data sheet
Citrix cloud platform 4.2 data sheetCitrix cloud platform 4.2 data sheet
Citrix cloud platform 4.2 data sheet
Nuno Alves
 
Seminar presentation 05042011_v7_with_cl
Seminar presentation 05042011_v7_with_clSeminar presentation 05042011_v7_with_cl
Seminar presentation 05042011_v7_with_cl
miket60
 
Cloud computing
Cloud computingCloud computing
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
IRJET Journal
 
Dynamic congestion management system for cloud service broker
Dynamic congestion management system for cloud service  brokerDynamic congestion management system for cloud service  broker
Dynamic congestion management system for cloud service broker
IJECEIAES
 
Meet the Committers Webinar_ Lab Preparation
Meet the Committers Webinar_ Lab PreparationMeet the Committers Webinar_ Lab Preparation
Meet the Committers Webinar_ Lab Preparation
Timothy Spann
 
Cloud computing
Cloud computingCloud computing
Cloud computing
حيدر نافع nafaa
 
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackupDATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
Symantec
 
Introduction to Google Cloud & GCCP Campaign
Introduction to Google Cloud & GCCP CampaignIntroduction to Google Cloud & GCCP Campaign
Introduction to Google Cloud & GCCP Campaign
GDSCVJTI
 
Hybrid Cloud Management and Orchestration : The Complete Solution
Hybrid Cloud Management and Orchestration : The Complete SolutionHybrid Cloud Management and Orchestration : The Complete Solution
Hybrid Cloud Management and Orchestration : The Complete Solution
John Katrick
 
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARINGSURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
Editor IJMTER
 
Big Data: It’s all about the Use Cases
Big Data: It’s all about the Use CasesBig Data: It’s all about the Use Cases
Big Data: It’s all about the Use Cases
James Serra
 
Unit v
Unit vUnit v
Unit v
upendarrao3
 

Similar to CloudStack Metering – Working with the Usage Data (20)

Working with CloudStack Usage Data - CCCEU13
Working with CloudStack Usage Data - CCCEU13Working with CloudStack Usage Data - CCCEU13
Working with CloudStack Usage Data - CCCEU13
 
Cloudstack autoscaling
Cloudstack autoscalingCloudstack autoscaling
Cloudstack autoscaling
 
cloud computing documentation
cloud computing documentationcloud computing documentation
cloud computing documentation
 
Cloudstack collaboration - customer focus
Cloudstack collaboration - customer focusCloudstack collaboration - customer focus
Cloudstack collaboration - customer focus
 
Whats the Use!? (Real Customer Use-Cases)
Whats the Use!? (Real Customer Use-Cases)Whats the Use!? (Real Customer Use-Cases)
Whats the Use!? (Real Customer Use-Cases)
 
CloudStack 101 CCCEU13
CloudStack 101 CCCEU13CloudStack 101 CCCEU13
CloudStack 101 CCCEU13
 
Accelerating Time-to-Value Through Hybrid Cloud Automation
Accelerating Time-to-Value Through Hybrid Cloud AutomationAccelerating Time-to-Value Through Hybrid Cloud Automation
Accelerating Time-to-Value Through Hybrid Cloud Automation
 
Citrix cloud platform 4.2 data sheet
Citrix cloud platform 4.2 data sheetCitrix cloud platform 4.2 data sheet
Citrix cloud platform 4.2 data sheet
 
Seminar presentation 05042011_v7_with_cl
Seminar presentation 05042011_v7_with_clSeminar presentation 05042011_v7_with_cl
Seminar presentation 05042011_v7_with_cl
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
IRJET- A Detailed Study and Analysis of Cloud Computing Usage with Real-Time ...
 
Dynamic congestion management system for cloud service broker
Dynamic congestion management system for cloud service  brokerDynamic congestion management system for cloud service  broker
Dynamic congestion management system for cloud service broker
 
Meet the Committers Webinar_ Lab Preparation
Meet the Committers Webinar_ Lab PreparationMeet the Committers Webinar_ Lab Preparation
Meet the Committers Webinar_ Lab Preparation
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackupDATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
DATASHEET▶ Enterprise Cloud Backup & Recovery with Symantec NetBackup
 
Introduction to Google Cloud & GCCP Campaign
Introduction to Google Cloud & GCCP CampaignIntroduction to Google Cloud & GCCP Campaign
Introduction to Google Cloud & GCCP Campaign
 
Hybrid Cloud Management and Orchestration : The Complete Solution
Hybrid Cloud Management and Orchestration : The Complete SolutionHybrid Cloud Management and Orchestration : The Complete Solution
Hybrid Cloud Management and Orchestration : The Complete Solution
 
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARINGSURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
SURVEY ON KEY AGGREGATE CRYPTOSYSTEM FOR SCALABLE DATA SHARING
 
Big Data: It’s all about the Use Cases
Big Data: It’s all about the Use CasesBig Data: It’s all about the Use Cases
Big Data: It’s all about the Use Cases
 
Unit v
Unit vUnit v
Unit v
 

Recently uploaded

Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
Mariano Tinti
 
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
Neo4j
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
名前 です男
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
IndexBug
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
Full-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalizationFull-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalization
Zilliz
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
Zilliz
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
Claudio Di Ciccio
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
Neo4j
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
Neo4j
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
Kumud Singh
 

Recently uploaded (20)

Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
 
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
Full-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalizationFull-RAG: A modern architecture for hyper-personalization
Full-RAG: A modern architecture for hyper-personalization
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
 

CloudStack Metering – Working with the Usage Data

  • 1. CloudStack Metering Working with the Usage Data Tariq Iqbal Senior Consultant tariq.iqbal@shapeblue.com Twitter: @TariqIqbal_ @ShapeBlue
  • 2. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  Involved with CloudStack before donation to Apache  Built and deployed CloudStack/CloudPlatform based clouds for Enterprises and Service Providers globally  Specialise in integrating CloudStack with Business Support and Operational Support systems, which include:  CloudPortals (including Payment Gateways, Fraud Control solutions)  Ticketing Systems  CRM/ERP Systems  Monitoring Solutions About Me
  • 3. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 “ShapeBlue are expert builders of public & private clouds. They are the leading global independent CloudStack / CloudPlatform integrator & consultancy” About ShapeBlue
  • 4. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  CloudStack metering - What and how?  CloudStack configuration to enable Usage capture  Usage Data generation process  Methods of accessing the Usage Data  Real World Use Cases Overview
  • 5. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  Organisations need to be able to meter their cloud's consumption and monetize the cloud offerings by charging for usage  Majority of organisations already have existing billing or business support systems and just need access to CloudStack Usage Data  Organisations tend to have different billing criteria and charging models requiring a comprehensive integrated solution Metering Requirements
  • 6. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 CloudStack Usage? CloudStack Metering
  • 7. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  CloudStack does not offer any integrated usage monitoring or billing/chargeback capability  Root Admin can view System Capacity  Domain Admin and Users can view VM status Metering in CloudStack today
  • 8. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  CloudStack includes a Usage Server that creates summary usage records for the various resources consumed in CloudStack  The Usage Server is an optional, separately-installed component called ‘cloudstack-usage’  The Usage Server runs at least once per day. It can be configured to run multiple times per day and it’s behaviour is controlled by the following global configuration settings: • Cloud Usage Server
  • 9. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  As CloudStack resources are created, consumed and destroyed, appropriate Event records are created in the ‘cloud’ database table: usage_events  There are 110 different Events: (51 shown) CloudStack Events
  • 10. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The Usage Server schedules a job at the time specified by usage.stats.job.exec.time parameter. This job queries the ‘cloud’ database table: usage_events and generates summary usage records in the ‘cloud_usage’ database table: cloud_usage as follows: 1. CloudStack events have been logged into the cloud.usage_event table 2. cloudstack_usage job gets a list of the latest usage events 3. Inserts the latest usage events into the cloud_usage.usage_events table 4. Helper tables populated from cloud_usage.usage_event table after parsing 5. cloud_usage.cloud_usage table populated with aggregation range wise data. Helper table data is used here Usage Record Generation
  • 11. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The Usage Server collects 14 different types of resource usage: Usage Types
  • 12. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The Usage Records show the amount of resources consumed by guest instances.  The Usage Record format for Allocated & Running VMs is shown below:  The other 7 Usage Record formats are:  Network Usage  IP Address  Disk Volume  Template, ISO & Snapshot  Load Balancer & Port Fwd  Network Offering  VPN User Usage Records
  • 13. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 Usage Record Example
  • 14. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 Accessing Usage Data CloudStack Metering
  • 15. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The usage records can be accessed through the CloudStack API  This is best done using the authentication port 8080 and requires both the API Key and Secret Key and for the API request to be signed  CloudStack provides the following Usage API calls with Root Admin access and supports XML and JSON response formats  listUsageTypes – list of Usage Types accessible  generateUsageRecords - asynchronous usage record generation  listUsageRecords - provides Usage records for a date range CloudStack API
  • 16. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The base command is: http://<HOST>:<8080>/client/api?command=listUsageRecords&startdate=y yyy-MM-dd&enddate=yyyy-MM-dd&signature  Append the various options: ListUsageRecords API
  • 17. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  <listusagerecordsresponse> <count>1</count> <usagerecord> <account>user5</account> <accountid>10004</accountid> <domainid>1</domainid> <zoneid>1</zoneid> <description>i-3-4-WC running time (Service Offering: 1) (Template: 3)</description> <usage>2.95288 Hrs</usage> <usagetype>1</usagetype> <rawusage>2.95288</rawusage> <virtualmachineid>4</virtualmachineid> <name>i-3-4-WC</name> <offeringid>1</offeringid> <templateid>3</templateid> <usageid>245554</usageid> <type>XenServer</type> <startdate>2009-09-15T00:00:00-0700</startdate> <enddate>2009-09-18T16:14:26-0700</enddate> </usagerecord> </listusagerecordsresponse> ListUsageRecords Response
  • 18. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  CloudMonkey is a CLI tool for CloudStack and can be used as an interactive shell or from within a shell script to call the API  It can output the Usage Data in both JSON and Tabular form to a file or pipe it to another application for further processing  Filtering can be used to limit the result set  It supports argument passing and shell automation  The host, port, apikey and secretkey can be configured on setup CloudMonkey CLI
  • 19. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 CloudMonkey list usagerecords The command to retrieve Usage Records is: cloudmonkey list usagerecords domainid=7ded1404-d7fc-11e2-a70f- 080027cfaf0b startdate=2013-06-01 enddate=2013-06-23 accountid=2
  • 20. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  The usage records can be also accessed by directly querying the cloud_usage.cloud_usage MySQL table in CloudStack  Usage Data can be exported in a CSV format from a SELECT query  The SQL query can become complex if the ID fields in the data need to be de-referenced  Typically multiple passes of the query results may be required to extract the required information SQL
  • 21. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  Once you are able to access the Usage Data, you will need to design the mapping between the fields in the CloudStack Usage Data and the fields of the target system.  Considerations:  Do you actually need all the Usage Data for all Resources?  Any UUID values of the CloudStack resources should also be imported into the target system for reference purposes  Decide which system will be the master for the user account data and if synchronisation is required Mediation
  • 22. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013 Real World Use Cases CloudStack Metering
  • 23. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  MS Excel can be used to analyse CloudStack Usage Records  The usage records are imported from the cloud_usage. cloud_usage table into MS Excel via an MySQL ODBC connection  Either PivotTables or reports can be used to present the data.  This is convenient and great for integration testing between CloudStack and external systems. MS Excel
  • 24. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  Citrix CloudPortal Business Manager tightly integrates with the cloud_usage database on CloudStack/CloudPlatform.  The Usage Data is cross referenced against the utility pricing and subscription pricing in CPBM.  Scheduled Billing and Invoicing jobs generate the invoices in XML or PDF based on the tenants billing cycle. Citrix CloudPortal
  • 25. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  splunk> is an operational intelligence tool that was initially used for collecting and indexing infrastructure logs  We then connected splunk> to the CloudStack Usage database and automated the collection and indexing of Usage Data  Setup feature-rich dashboards and the capability to drill down into the Usage Data for BI reporting splunk>
  • 26. @ShapeBlue #CloudStack #CCC13 CloudStack Collaboration Conference 2013  CloudStack Developers Guide, API Documentation & Wiki:  http://cloudstack.apache.org/  CloudMonkey  https://cwiki.apache.org/CLOUDSTACK/cloudstack-cloudmonkey- cli.html  How to Use MS Excel to Analyze CloudStack Usage Records:  http://support.citrix.com/article/CTX132030  CloudStack Mailing Lists (Users, Development, Marketing):  http://cloudstack.apache.org/mailing-lists.html Further Information
  • 27. CloudStack Metering Working with the Usage Data Tariq Iqbal Senior Consultant tariq.iqbal@shapeblue.com Twitter: @TariqIqbal_ @ShapeBlue

Editor's Notes

  1. eSkyCityBroker BinSunGardCiscoOrangeT-Mobile
  2. eSkyCityBroker BinSunGardCiscoOrangeT-Mobile