relational cloud: a database-as-a-service for the cloud

13
Relational Cloud: A Database-as-a-Service for the Cloud Carlo Curino, Evan Jones, Raluca Ada Popa, Nirmesh Malaviya, Eugene Wu, Sam Madden, Hari Balakrishnan, Nickolai Zeldovich Presented by Arka Bhattacharya (for CS 294,Berkeley) (some slides are taken from the CIDR ‘11 talk)

Upload: sammy

Post on 23-Mar-2016

64 views

Category:

Documents


2 download

DESCRIPTION

Relational Cloud: A Database-as-a-Service for the Cloud. Carlo Curino , Evan Jones, Raluca Ada Popa , Nirmesh Malaviya , Eugene Wu, Sam Madden, Hari Balakrishnan , Nickolai Zeldovich. Presented by Arka Bhattacharya (for CS 294,Berkeley) (some slides are taken from the CIDR ‘11 talk). - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Relational Cloud:  A Database-as-a-Service for the Cloud

Relational Cloud: A Database-as-a-Service for the Cloud

Carlo Curino, Evan Jones, Raluca Ada Popa, Nirmesh Malaviya, Eugene Wu, Sam Madden, Hari Balakrishnan,

Nickolai Zeldovich

Presented byArka Bhattacharya (for CS 294,Berkeley)

(some slides are taken from the CIDR ‘11 talk)

Page 2: Relational Cloud:  A Database-as-a-Service for the Cloud

THE STARTUP STORY

Page 3: Relational Cloud:  A Database-as-a-Service for the Cloud

Motivation

Why move to the cloud ? Economies of scale (hw & licensing costs) Pay per use & lower administrative costs

Present players : Amazon RDS (MySQL on EC2) Microsoft SQL Azure

Page 4: Relational Cloud:  A Database-as-a-Service for the Cloud

Problems !

Problems arising : Efficient Multi-tenancy (Provider) Elastic scalability (Provider) Privacy (User)

Note : Relational Cloud is mainly for OLTP workloads & DAS architectures , consistency guarantees

Page 5: Relational Cloud:  A Database-as-a-Service for the Cloud

1. Efficient Multi-tenancy – Placement & Migrations

Problem : Consolidate databases into smallest number of servers, balancing load and without affecting performance

Solution : Kairos , SIGMOD ’11 Upto 17:1 consolidation

Key insight : Single database server per machine + logical databases ; (as opposed to DB in VM , or multiple DB servers per machine ) Reduces redundant work, group commits, lower RAM

wastage, code sharing, cheaper context switches

Page 6: Relational Cloud:  A Database-as-a-Service for the Cloud

Kairos ….cntd Measure RAM,CPU & Disk usage of a database, and estimate

combined load RAM : Probe table to gauge working set size ; additive Disk : Deduce model by testing DBMS with different write rates

& working set size & measuring amount of IO CPU : additive

Frame optimization problem (non-linear programming) Solving takes time After lots of heuristics, optimization solutions terminate in 8

minutes for 20 servers & 100 workloads !

Page 7: Relational Cloud:  A Database-as-a-Service for the Cloud

2. Elastic ScalabilityDatabase Partitioning

Problem : Partition an OLTP database into N chunks so as to maximize performance

Solution : Schism , VLDB 2010 Close to optimal

Key insight : Minimize number of distributed transactions Advantage over Hashing, round-robin

Use workload trace to find good partitions

Page 8: Relational Cloud:  A Database-as-a-Service for the Cloud

Schism …cntd

Page 9: Relational Cloud:  A Database-as-a-Service for the Cloud

Schism …. cntd Use a classifier to capture partitioning in compact

form , for efficient query routing

Lots of heuristics to choose good workload sample Sampling , blanket state filtering, etc

Graph Partitioning in fast ( < 40 sec )

Achieves almost linear scalability !

Page 10: Relational Cloud:  A Database-as-a-Service for the Cloud

3. Privacy Problem :

Prevent DBA from snooping on data ensure data security during application and DBMS

server compromise

Solution : CryptDB , SOSP 2011 Low overhead ~ 22.5%

Key insight : Adjustable security

Page 11: Relational Cloud:  A Database-as-a-Service for the Cloud

CrpytDB …Onions

Any value

DET : equality join

DET : equality selection

RND

Any value

OPE-inequality join

OPE : inequality select

RND

int value

HOM

Onion 1 Onion 2 Onion 3

Page 12: Relational Cloud:  A Database-as-a-Service for the Cloud

Overall architecture

DB stats

Partitions & placements

Page 13: Relational Cloud:  A Database-as-a-Service for the Cloud

Relational Cloud Advantages :

Unmodified DB backends Workload-aware consolidation Workload-aware sharding High availability via replication of front-end servers SQL over encrypted data