KEMBAR78
Introduction to Google Compute Engine | PDF
Getting Started with Google's Infrastructure
!
!
!
!


+ColinSu
Developer Expert, Google Cloud Platform
A Tour of Google Compute Engine
Google Cloud Platform
Slides are available on slideshare.net
goo.gl/ARRyaq
Google Cloud Platform
Overview
Google Cloud Platform
Google Cloud Platform
The best way how Google share their
+ Cloud Infrastructure
+ Cloud Knowledge
+ Cloud Engineers
Your own data center, with minimum cost
as possible as it could be
What is Google Cloud Platform
Google Cloud Platform
You will be using Google's Infrastructure

Virtual Machines

Networking

Storage
And be placed in a safe place

Google's Data Center
And Google will do those for you

Scaling

Migrating

Maintenance

Take over anything you don't wanna do

Powered by Google
Google Cloud Platform
Google Cloud Family
Google Cloud Platform
Manage all API services on Google
Cloud 

(e.g. Translation API, Prediction API, Maps API...)
Compose equivalent commands for:

Command-line tools (Google Cloud SDK)

RESTful API
Dashboard for monitoring all
resources on Google Cloud Platform
Cloud Developer Console
Google Cloud Platform
Install/uninstall/upgrade all
command-line tools related to
Google Cloud Platform
Notification for new release of any
Cloud SDK component
Automatization
Google Cloud SDK
Google Cloud Platform
Storage
Storage Services in Google Cloud Platform
Google Cloud Platform
It's MySQL, but managed by Google
Relational Data Storage on Google Cloud
Use Cases
+ LAMP Applications
+ Google App Engine
Cloud SQL
Google Cloud Platform
Non-relational database (NoSQL)
Schema-less data
Use Cases
+ Highly scalable application
Cloud Datastore
Google Cloud Platform
Protected

Your data is protected at multiple physical locations
Strong, configurable security

OAuth or simple access control on your data
Multiple usages
+ Serve static objects directly
+ Use with other Google Cloud products (Bridge)
Cloud Storage
Google Cloud Platform
Google Compute Engine
Infrastructure-as-a-Service in Google Cloud Platform
Google Cloud Platform
Google has resources
+ CPU Cores
+ Memory
+ Networking
+ Persistency (Disks, Snapshot, Cloud Storage...)
+ Well-trained engineering monkeys
You have business and be busy
Infrastucture-as-a-Service
Google Cloud Platform
High-performance virtual machines

from micro-VM to large instance
Powered by Google's global network

you could build a large cluster with strong and consistent bandwidth, provided by
Google
Load Balancing

spread incoming traffic across instances
Fast Bullet Reloading

quick deployment of large VMs

command-line interface

web-based console
Highly secured

All data written to disk in Compute Engine will be encrypted by high-class
encryption algorithm
Google Compute Engine
Google Cloud Platform
KVM-based Virtual machines
Fast booting time

routinely takes less than 30 secs
Various OS support
Various machine types
Instances on GCE
http://gce-demos.appspot.com
Google Cloud Platform
Operating Systems
Google Cloud Platform
Operating Systems
Google Cloud Platform
Operating Systems
Limited Preview
Google Cloud Platform
Operating Systems
Limited Preview
Google Cloud Platform
a unit of CPU capacity used to describe the compute power of instance
types
2.75 GCEUs = 1 minimum power of 1 logical core on Sandy Bridge
platform
Google Compute Engine Units (GCEUs)
=
Google Cloud Platform
Machine Types (Shared-Core)
f1-micro
Shared Core
0.6 GB Memory
g1-small
1 Core
1.7 GB Memory
1.38 GCEUs
Google Cloud Platform
Machine Types (Standard)
n1-standard-n
Starts from 1 Core
Start from 3.75 GB Memory
n Virtual CPUs Memory GCEUs
1 1 3.75 GB 2.75
2 2 7.50 GB 5.50
4 4 15 GB 11
8 8 30 GB 30
16 16 60 GB 60
Google Cloud Platform
Machine Types (High Memory)
n1-highmem-n
Starts from 2 Core
Start from 13 GB Memory
n Virtual CPUs Memory GCEUs
2 2 13 GB 5.50
4 4 26 GB 11
8 8 52 GB 22
16 16 104 GB 44
Google Cloud Platform
Machine Types (High CPU)
n1-highcpu-n
Starts from 2 Core
Start from 1.8 GB Memory
n Virtual CPUs Memory GCEUs
2 2 1.8 GB 5.50
4 4 3.6 GB 11
8 8 7.2 GB 22
16 16 14.4 GB 44
Google Cloud Platform
Regions & Zones
us-central1-a

us-central1-b
europe-west1-a

europe-west1-b
Google Cloud Platform
Regions & Zones
us-central1-a

us-central1-b
europe-west1-a

europe-west1-b
Singapore?
asia-east-a

asia-east-b
Google Cloud Platform
Transparent Maintenance
Auto restart instances shutdown by system events
During transparent maintenance, you could set GCE to handle your
instance in two ways:
+ Live migrate

affect performance in some degree

but remain your instances online (no downtime)
+ Terminate and reboot
Live Migration
Google Cloud Platform
Virtual SCSI device
Block Storage
Persistent until deleted
Hot-plug to GCE instances (attach/deattach)
Persistent Disk
Google Cloud Platform
Primary Disk: OS boot volume
Persistent Disk Mode
GCE Virtual Machine
Root
Stateful Root Volume
Google Cloud Platform
Additional Disk: Read/Write Mode for user managed data volume
Persistent Disk Mode
GCE Virtual Machine
Root
Stateful Root Volume
RW Data
Stateful Data Volume
Google Cloud Platform
Distribution Disk: Instant distribution of static content
Persistent Disk Mode
GCE Virtual Machine
RO Data
Read-Only Data Volume
GCE Virtual MachineGCE Virtual Machine
Google Cloud Platform
Target Pools
Health Checking
Forwarding Rules

iptables for target pools
Load Balancing
Google Cloud Platform
CGE reserved IP for instance, won't change with the reboot of VMs
You can promote ephemeral IP to persistent IP
no DNS changing anymore
Persistent IP Addresses
Google Cloud Platform
Networking is first-class object on GCE

which means you could apply/unapply it anytime easily
pre-defined networks before the first instance started
Integrated Networking
Google Cloud Platform
Those resources are global resources
+ Images (OS Images)
+ Snapshots
+ Network
+ Firewalls
+ Routes
And they're also first-class object in GCE
Multi-Region Resources
Google Cloud Platform
Scalr
Right Scale
Services Host GCE
Google Cloud Platform
Benchmark
How Google Compute Engine performs?
Google Cloud Platform
Benchmarks - Sequential I/O
w/ a well-known and you-know competitor
http://github.com/Scalr/perf-benchmarks
Google Cloud Platform
Volume I/O
GCE EC2
Writes on ephemeral 175 MB/s 38-45 MB/s
Reads on ephemeral 93.3 MB/s 100-110 MB/s
Writes on persistent 84.5 MB/s 35-45 MB/s
Reads on persistent 98.9 MB/s 80-100 MB/s
http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/
w/ a well-known and you-know competitor
Google Cloud Platform
Fast Booting Time
http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/
w/ a well-known and you-know competitor
Google Cloud Platform
Network Bandwidth & Latency
http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/
w/ a well-known and you-know competitor
Google Cloud Platform
Machine Types (Shared-Core) & Pricing
Google Cloud Platform
Machine Types (Standard) & Pricing
Google Cloud Platform
Machine Types (High Memory) & Pricing
Google Cloud Platform
Machine Types (High CPU) & Pricing
Google Cloud Platform
Other Pricing
https://developers.google.com/compute/pricing
Google Cloud Platform
Limited Preview Projects
Sealed Projects with Google Compute Engine
Google Cloud Platform
Create and manage a large number of homogeneous resources
Set up health checking to ensure you will have certain number of heathy
instance to serve requests
config-based tool
Replica Pool Limited Preview
Google Cloud Platform
Replica Pool Limited Preview
Pool Resource
GCE Virtual Machine GCE Virtual MachineGCE Virtual Machine
Replica
Resource
Replica
Resource
Replica
Resource
Google Cloud Platform
Replica Pool Configuration Limited Preview
{!
"name": POOLNAME,!
"type": "SMART_VM",!
"initialNumReplicas": "3",!
"template": {!
"vmParams": {!
"machineType": "n1-standard-1",!
"baseInstanceName": "my-replica",!
"disksToCreate": [{!
"boot": "true",!
"mode": "READ_WRITE",!
"initializeParams": {!
"sourceImage": IMAGE_URI,!
"diskSizeGb": "100"!
}!
}],!
"networkInterfaces": [{!
"network": "default",!
"accessConfigs": [{!
"type": "ONE_TO_ONE_NAT",!
"name": "External NAT"!
}]!
}]!
}!
}!
}!
Google Cloud Platform
Useful Template Settings Limited Preview
"action": {!
"name": "install-apache",!
"commands": [!
"sudo apt-get update"!
"sudo apt-get install apache"!
...!
],!
"envVariables: [!
...!
]!
}!
"template.action": specify Linux command that will run on your instances after deployed
Google Cloud Platform
Useful Template Settings Limited Preview
"baseInstanceName": "my-vm-replicas"!
"template.vmParams.baseInstanceName": The base instance name to use for these replicas
Google Cloud Platform
Useful Template Settings Limited Preview
"disksToAttach": [{!
"source": "full-uri-to-disk",!
"mode": "read-only",!
"type": "PERSISTENT",!
}!
]!
"template.vmParams.disksToAttach[]": Attaches persistent disks to your replicas
Google Cloud Platform
Health Checking Limited Preview
"healthChecks": [{!
"name": "testhealth",!
"path": "localhost/healthCheck"!
}]!
Make sure all instance are healthy, if not, Pool will create more instances until it satisfies
Google Cloud Platform
Health Checking Options Limited Preview
checkIntervalSec

Determines how often, in seconds, to make HTTP requests for the health check.
healthyThreshold

Sets the number of consecutive health check requests that must succeed before the replica is considered healthy. The default is
2 successful consecutive health checks.
timeoutSec

How long to wait in seconds before claiming failures for a health check.
unhealthyThreshold

The number of consecutive health check requests that need to fail to consider the replica unhealthy.
Only a HTTP 2xx response is considered successful.
Google Cloud Platform
Windows Server Images

https://developers.google.com/compute/docs/premium-operating-systems
SSD Persistent Disks

https://developers.google.com/compute/docs/disks#typeofdisks
Advanced Routing

https://developers.google.com/compute/docs/networking#routing
Push-to-deploy

https://developers.google.com/appengine/docs/push-to-deploy
Other Limited Preview Projects
Google Cloud Platform
Technical Detail of Google Compute Engine

http://commondatastorage.googleapis.com/io2012/presentations/live%20to%20website/313.pdf
Github Google Cloud Platform Team

http://googlecloudplatform.github.io/
Resources
Google Cloud Platform
EOF


Thanks For Listening

+GDGTaipei
Google Cloud Platform
Questions?
Google Cloud Platform
Interested?
Search "google cloud starter pack", use promo code: gcpteam-in

Introduction to Google Compute Engine

  • 1.
    Getting Started withGoogle's Infrastructure ! ! ! ! 
 +ColinSu Developer Expert, Google Cloud Platform A Tour of Google Compute Engine
  • 2.
    Google Cloud Platform Slidesare available on slideshare.net goo.gl/ARRyaq
  • 3.
  • 4.
    Google Cloud Platform Thebest way how Google share their + Cloud Infrastructure + Cloud Knowledge + Cloud Engineers Your own data center, with minimum cost as possible as it could be What is Google Cloud Platform
  • 5.
    Google Cloud Platform Youwill be using Google's Infrastructure
 Virtual Machines
 Networking
 Storage And be placed in a safe place
 Google's Data Center And Google will do those for you
 Scaling
 Migrating
 Maintenance
 Take over anything you don't wanna do
 Powered by Google
  • 6.
  • 7.
    Google Cloud Platform Manageall API services on Google Cloud 
 (e.g. Translation API, Prediction API, Maps API...) Compose equivalent commands for:
 Command-line tools (Google Cloud SDK)
 RESTful API Dashboard for monitoring all resources on Google Cloud Platform Cloud Developer Console
  • 8.
    Google Cloud Platform Install/uninstall/upgradeall command-line tools related to Google Cloud Platform Notification for new release of any Cloud SDK component Automatization Google Cloud SDK
  • 9.
    Google Cloud Platform Storage StorageServices in Google Cloud Platform
  • 10.
    Google Cloud Platform It'sMySQL, but managed by Google Relational Data Storage on Google Cloud Use Cases + LAMP Applications + Google App Engine Cloud SQL
  • 11.
    Google Cloud Platform Non-relationaldatabase (NoSQL) Schema-less data Use Cases + Highly scalable application Cloud Datastore
  • 12.
    Google Cloud Platform Protected
 Yourdata is protected at multiple physical locations Strong, configurable security
 OAuth or simple access control on your data Multiple usages + Serve static objects directly + Use with other Google Cloud products (Bridge) Cloud Storage
  • 13.
    Google Cloud Platform GoogleCompute Engine Infrastructure-as-a-Service in Google Cloud Platform
  • 14.
    Google Cloud Platform Googlehas resources + CPU Cores + Memory + Networking + Persistency (Disks, Snapshot, Cloud Storage...) + Well-trained engineering monkeys You have business and be busy Infrastucture-as-a-Service
  • 15.
    Google Cloud Platform High-performancevirtual machines
 from micro-VM to large instance Powered by Google's global network
 you could build a large cluster with strong and consistent bandwidth, provided by Google Load Balancing
 spread incoming traffic across instances Fast Bullet Reloading
 quick deployment of large VMs
 command-line interface
 web-based console Highly secured
 All data written to disk in Compute Engine will be encrypted by high-class encryption algorithm Google Compute Engine
  • 16.
    Google Cloud Platform KVM-basedVirtual machines Fast booting time
 routinely takes less than 30 secs Various OS support Various machine types Instances on GCE http://gce-demos.appspot.com
  • 17.
  • 18.
  • 19.
    Google Cloud Platform OperatingSystems Limited Preview
  • 20.
    Google Cloud Platform OperatingSystems Limited Preview
  • 21.
    Google Cloud Platform aunit of CPU capacity used to describe the compute power of instance types 2.75 GCEUs = 1 minimum power of 1 logical core on Sandy Bridge platform Google Compute Engine Units (GCEUs) =
  • 22.
    Google Cloud Platform MachineTypes (Shared-Core) f1-micro Shared Core 0.6 GB Memory g1-small 1 Core 1.7 GB Memory 1.38 GCEUs
  • 23.
    Google Cloud Platform MachineTypes (Standard) n1-standard-n Starts from 1 Core Start from 3.75 GB Memory n Virtual CPUs Memory GCEUs 1 1 3.75 GB 2.75 2 2 7.50 GB 5.50 4 4 15 GB 11 8 8 30 GB 30 16 16 60 GB 60
  • 24.
    Google Cloud Platform MachineTypes (High Memory) n1-highmem-n Starts from 2 Core Start from 13 GB Memory n Virtual CPUs Memory GCEUs 2 2 13 GB 5.50 4 4 26 GB 11 8 8 52 GB 22 16 16 104 GB 44
  • 25.
    Google Cloud Platform MachineTypes (High CPU) n1-highcpu-n Starts from 2 Core Start from 1.8 GB Memory n Virtual CPUs Memory GCEUs 2 2 1.8 GB 5.50 4 4 3.6 GB 11 8 8 7.2 GB 22 16 16 14.4 GB 44
  • 26.
    Google Cloud Platform Regions& Zones us-central1-a
 us-central1-b europe-west1-a
 europe-west1-b
  • 27.
    Google Cloud Platform Regions& Zones us-central1-a
 us-central1-b europe-west1-a
 europe-west1-b Singapore? asia-east-a
 asia-east-b
  • 28.
    Google Cloud Platform TransparentMaintenance Auto restart instances shutdown by system events During transparent maintenance, you could set GCE to handle your instance in two ways: + Live migrate
 affect performance in some degree
 but remain your instances online (no downtime) + Terminate and reboot Live Migration
  • 29.
    Google Cloud Platform VirtualSCSI device Block Storage Persistent until deleted Hot-plug to GCE instances (attach/deattach) Persistent Disk
  • 30.
    Google Cloud Platform PrimaryDisk: OS boot volume Persistent Disk Mode GCE Virtual Machine Root Stateful Root Volume
  • 31.
    Google Cloud Platform AdditionalDisk: Read/Write Mode for user managed data volume Persistent Disk Mode GCE Virtual Machine Root Stateful Root Volume RW Data Stateful Data Volume
  • 32.
    Google Cloud Platform DistributionDisk: Instant distribution of static content Persistent Disk Mode GCE Virtual Machine RO Data Read-Only Data Volume GCE Virtual MachineGCE Virtual Machine
  • 33.
    Google Cloud Platform TargetPools Health Checking Forwarding Rules
 iptables for target pools Load Balancing
  • 34.
    Google Cloud Platform CGEreserved IP for instance, won't change with the reboot of VMs You can promote ephemeral IP to persistent IP no DNS changing anymore Persistent IP Addresses
  • 35.
    Google Cloud Platform Networkingis first-class object on GCE
 which means you could apply/unapply it anytime easily pre-defined networks before the first instance started Integrated Networking
  • 36.
    Google Cloud Platform Thoseresources are global resources + Images (OS Images) + Snapshots + Network + Firewalls + Routes And they're also first-class object in GCE Multi-Region Resources
  • 37.
    Google Cloud Platform Scalr RightScale Services Host GCE
  • 38.
    Google Cloud Platform Benchmark HowGoogle Compute Engine performs?
  • 39.
    Google Cloud Platform Benchmarks- Sequential I/O w/ a well-known and you-know competitor http://github.com/Scalr/perf-benchmarks
  • 40.
    Google Cloud Platform VolumeI/O GCE EC2 Writes on ephemeral 175 MB/s 38-45 MB/s Reads on ephemeral 93.3 MB/s 100-110 MB/s Writes on persistent 84.5 MB/s 35-45 MB/s Reads on persistent 98.9 MB/s 80-100 MB/s http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/ w/ a well-known and you-know competitor
  • 41.
    Google Cloud Platform FastBooting Time http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/ w/ a well-known and you-know competitor
  • 42.
    Google Cloud Platform NetworkBandwidth & Latency http://gigaom.com/2013/03/15/by-the-numbers-how-google-compute-engine-stacks-up-to-amazon-ec2/ w/ a well-known and you-know competitor
  • 43.
    Google Cloud Platform MachineTypes (Shared-Core) & Pricing
  • 44.
    Google Cloud Platform MachineTypes (Standard) & Pricing
  • 45.
    Google Cloud Platform MachineTypes (High Memory) & Pricing
  • 46.
    Google Cloud Platform MachineTypes (High CPU) & Pricing
  • 47.
    Google Cloud Platform OtherPricing https://developers.google.com/compute/pricing
  • 48.
    Google Cloud Platform LimitedPreview Projects Sealed Projects with Google Compute Engine
  • 49.
    Google Cloud Platform Createand manage a large number of homogeneous resources Set up health checking to ensure you will have certain number of heathy instance to serve requests config-based tool Replica Pool Limited Preview
  • 50.
    Google Cloud Platform ReplicaPool Limited Preview Pool Resource GCE Virtual Machine GCE Virtual MachineGCE Virtual Machine Replica Resource Replica Resource Replica Resource
  • 51.
    Google Cloud Platform ReplicaPool Configuration Limited Preview {! "name": POOLNAME,! "type": "SMART_VM",! "initialNumReplicas": "3",! "template": {! "vmParams": {! "machineType": "n1-standard-1",! "baseInstanceName": "my-replica",! "disksToCreate": [{! "boot": "true",! "mode": "READ_WRITE",! "initializeParams": {! "sourceImage": IMAGE_URI,! "diskSizeGb": "100"! }! }],! "networkInterfaces": [{! "network": "default",! "accessConfigs": [{! "type": "ONE_TO_ONE_NAT",! "name": "External NAT"! }]! }]! }! }! }!
  • 52.
    Google Cloud Platform UsefulTemplate Settings Limited Preview "action": {! "name": "install-apache",! "commands": [! "sudo apt-get update"! "sudo apt-get install apache"! ...! ],! "envVariables: [! ...! ]! }! "template.action": specify Linux command that will run on your instances after deployed
  • 53.
    Google Cloud Platform UsefulTemplate Settings Limited Preview "baseInstanceName": "my-vm-replicas"! "template.vmParams.baseInstanceName": The base instance name to use for these replicas
  • 54.
    Google Cloud Platform UsefulTemplate Settings Limited Preview "disksToAttach": [{! "source": "full-uri-to-disk",! "mode": "read-only",! "type": "PERSISTENT",! }! ]! "template.vmParams.disksToAttach[]": Attaches persistent disks to your replicas
  • 55.
    Google Cloud Platform HealthChecking Limited Preview "healthChecks": [{! "name": "testhealth",! "path": "localhost/healthCheck"! }]! Make sure all instance are healthy, if not, Pool will create more instances until it satisfies
  • 56.
    Google Cloud Platform HealthChecking Options Limited Preview checkIntervalSec
 Determines how often, in seconds, to make HTTP requests for the health check. healthyThreshold
 Sets the number of consecutive health check requests that must succeed before the replica is considered healthy. The default is 2 successful consecutive health checks. timeoutSec
 How long to wait in seconds before claiming failures for a health check. unhealthyThreshold
 The number of consecutive health check requests that need to fail to consider the replica unhealthy. Only a HTTP 2xx response is considered successful.
  • 57.
    Google Cloud Platform WindowsServer Images
 https://developers.google.com/compute/docs/premium-operating-systems SSD Persistent Disks
 https://developers.google.com/compute/docs/disks#typeofdisks Advanced Routing
 https://developers.google.com/compute/docs/networking#routing Push-to-deploy
 https://developers.google.com/appengine/docs/push-to-deploy Other Limited Preview Projects
  • 58.
    Google Cloud Platform TechnicalDetail of Google Compute Engine
 http://commondatastorage.googleapis.com/io2012/presentations/live%20to%20website/313.pdf Github Google Cloud Platform Team
 http://googlecloudplatform.github.io/ Resources
  • 59.
    Google Cloud Platform EOF 
 ThanksFor Listening
 +GDGTaipei
  • 60.
  • 61.
    Google Cloud Platform Interested? Search"google cloud starter pack", use promo code: gcpteam-in