byzantine fault tolerant cloud storage for storing sensor data

95
Cloud Storage for storing sensor data Jos van der Til Byzantine fault tolerant

Upload: jvandertil

Post on 05-Dec-2014

277 views

Category:

Technology


1 download

DESCRIPTION

My presentation for attaining my Master's Degree in Computing Science. Thesis links: http://irs.ub.rug.nl/dbi/522047fa91559 http://www.cs.rug.nl/~aiellom/tesi/vdtil.pdf

TRANSCRIPT

Page 1: Byzantine fault tolerant Cloud Storage for storing sensor data

Cloud Storagefor storing sensor data

Jos van der Til

Byzantine fault tolerant

Page 2: Byzantine fault tolerant Cloud Storage for storing sensor data

WHAT WAS THAT FIRST SLIDE?

Page 3: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!SENSOR DATA

Page 4: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!SENSOR DATAVARIES BY MEASUREMENT INTERVAL

Page 5: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!SENSOR DATAVARIES BY MEASUREMENT INTERVAL

VARIES BY DIMENSIONALITY

Page 6: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!SENSOR DATAVARIES BY MEASUREMENT INTERVAL

VARIES BY DIMENSIONALITY

VARIES BY SIZE

Page 7: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!SENSOR DATAVARIES BY MEASUREMENT INTERVAL

VARIES BY DIMENSIONALITY

VARIES BY SIZE

IMPORTANT: IMAGES AND VIDEO ARE ALSO SENSOR DATA!

Page 8: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATA

Page 9: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATA

Page 10: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATAUNLIMITED STORAGE

Page 11: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATA

ACCESSIBLE FROM ANYWHERE

UNLIMITED STORAGE

Page 12: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATA

ACCESSIBLE FROM ANYWHERE

ACCESSIBLE ANYTIME

UNLIMITED STORAGE

Page 13: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGESENSOR DATA

ACCESSIBLE FROM ANYWHERE

ACCESSIBLE ANYTIME

UNLIMITED STORAGE

PAY FOR WHAT YOU USE!

Page 14: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGEFAULT TOLERANT

SENSOR DATA

Page 15: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGEFAULT TOLERANT

SENSOR DATAPROCESSES ONLY CRASH

Page 16: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGEFAULT TOLERANT

SENSOR DATAPROCESSES ONLY CRASH…RIGHT?

Page 17: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGEFAULT TOLERANT

HOW BAD CAN IT GET? SENSOR DATA

Page 18: Byzantine fault tolerant Cloud Storage for storing sensor data

I KNOW SOME OF THESE WORDS!

CLOUD STORAGEFAULT TOLERANT

BYZANTINE

SENSOR DATA

Page 19: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?

Page 20: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?

Page 21: Byzantine fault tolerant Cloud Storage for storing sensor data

Fail stop Crash

HOW DO PROCESSES FAIL?

Page 22: Byzantine fault tolerant Cloud Storage for storing sensor data

Fail stop Crash

Send OmissionReceive

Omission

General

Omission

HOW DO PROCESSES FAIL?

Page 23: Byzantine fault tolerant Cloud Storage for storing sensor data

Fail stop Crash

Send OmissionReceive

Omission

General

Omission

Arbitrary failures

with message

authentication

HOW DO PROCESSES FAIL?

Page 24: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?

Fail stop Crash

Send OmissionReceive

Omission

General

Omission

Arbitrary failures

with message

authentication

Arbitrary

(Byzantine)

failures

Page 25: Byzantine fault tolerant Cloud Storage for storing sensor data

Storage clouds

Sensor Network

Measurements

Sensor server

Sto

rage

Lib

Measurements

Storage Lib

Processing server

Writer

Reader

Page 26: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?

Page 27: Byzantine fault tolerant Cloud Storage for storing sensor data

READERS ARE PROCESSES

HOW DO PROCESSES FAIL?

Page 28: Byzantine fault tolerant Cloud Storage for storing sensor data

READERS ARE PROCESSES

HOW DO PROCESSES FAIL?

WRITERS ARE PROCESSES

Page 29: Byzantine fault tolerant Cloud Storage for storing sensor data

READERS ARE PROCESSES

HOW DO PROCESSES FAIL?

WRITERS ARE PROCESSESbut they are cool.

Page 30: Byzantine fault tolerant Cloud Storage for storing sensor data

READERS ARE PROCESSES

HOW DO PROCESSES FAIL?

WRITERS ARE PROCESSESbut they are cool.

can fail without causing damage.

are only expected to fail by crashing.

Page 31: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

Page 32: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

Page 33: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

can leak your data

Page 34: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

can corrupt your data

Page 35: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

can delete your data

Page 36: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

can stop responding to your requests

Page 37: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW DO PROCESSES FAIL?CLOUD PROVIDERS ARE PROCESSES

but they are NOT cool.

HAS FULL CONTROL OVER YOUR DATA BUT BEHAVES BYZANTINE

Page 38: Byzantine fault tolerant Cloud Storage for storing sensor data

YOUR DATA IS STORED

IN A PROCESS THAT CAN FAIL

BYZANTINE

Page 39: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW TO ACHIEVE

BYZANTINE FAULT TOLERANCE?

Page 40: Byzantine fault tolerant Cloud Storage for storing sensor data

DO NOT TRUST A SINGLE CLOUD!

Page 41: Byzantine fault tolerant Cloud Storage for storing sensor data

DO TRUST MULTIPLE CLOUDS!

Page 42: Byzantine fault tolerant Cloud Storage for storing sensor data

UPLOAD DATA TO ALL THE CLOUDS!

Page 43: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW MANY CLOUDS DO WE NEED?

𝑛 ≥ 3𝑓 + 1

Page 44: Byzantine fault tolerant Cloud Storage for storing sensor data

HOW IS DATA STORED?

Page 45: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

Page 46: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

DATA CAN NOT BE RETRIEVED BY LESS THAN f+1 PROVIDERS

Page 47: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

DATA CAN NOT BE RETRIEVED BY LESS THAN f+1 PROVIDERS

ENCRYPTION

SECRET SHARING

Page 48: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

DATA CAN NOT BE RETRIEVED BY LESS THAN f+1 PROVIDERS

SHOULD NOT REQUIRE n TIMES THE STORAGE SPACE

Page 49: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

DATA CAN NOT BE RETRIEVED BY LESS THAN f+1 PROVIDERS

SHOULD NOT REQUIRE n TIMES THE STORAGE SPACE

ERASURE CODING

Page 50: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS STORED IN A QUORUM OF CLOUD PROVIDERSQUORUM OF 2f+1 PROVIDERS TO BE EXACT

DATA CAN NOT BE RETRIEVED BY LESS THAN f+1 PROVIDERS

SHOULD NOT REQUIRE n TIMES THE STORAGE SPACE

ERASURE CODING𝑛

𝑓 + 1

−1

=𝑓 + 1

𝑛

lim𝑓→∞

𝑓 + 1

𝑛=

𝑓 + 1

3𝑓 + 1=1

3

SPACE EFFICIENCY

MAXIMUM SPACE EFFICIENCY

lim𝑓→∞

1

𝑛= 0NOT BAD COMPARED TO

Page 51: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

Page 52: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

I WANT TO READ THIS BLOCK

Page 53: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

I WANT TO ENCRYPT THIS BLOCK

Page 54: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

I WANT TO HASH THIS BLOCK

Page 55: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

I WANT TO UPLOAD THIS BLOCK

Page 56: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

I WANT TO DOWNLOAD THIS BLOCK

Page 57: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

BLOCK DOES NOT FIT IN MEMORY

Page 58: Byzantine fault tolerant Cloud Storage for storing sensor data

TRADITIONAL APPROACHDATA IS A BLOCK!

BLOCK DOES NOT FIT IN MEMORY

:(

Page 59: Byzantine fault tolerant Cloud Storage for storing sensor data

NOW WHAT?

Page 60: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHDATA IS A STREAM!

Page 61: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHDATA IS A STREAM…of blocks!

Page 62: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHDATA IS A STREAM…of blocks!

Every block should fit into memory

Page 63: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHDATA IS A STREAM…of blocks!

Every block should fit into memory

Every block is processed independent

Page 64: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHDATA IS A STREAM…of blocks!

Every block should fit into memory

Every block is processed independent

Every block has a checksum (think BitTorrent)

Page 65: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHHAS MORE OVERHEAD IN MEMORY AND STORAGE

Page 66: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHHAS MORE OVERHEAD IN MEMORY AND STORAGE

Page 67: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHHAS MORE OVERHEAD IN MEMORY AND STORAGE

REQUIRES LESS MEMORY FOR PROCESSING

Page 68: Byzantine fault tolerant Cloud Storage for storing sensor data

MY APPROACHHAS MORE OVERHEAD IN MEMORY AND STORAGE

REQUIRES LESS MEMORY FOR PROCESSING

CAN FAIL FASTER, SAVING BANDWIDTH

Page 69: Byzantine fault tolerant Cloud Storage for storing sensor data

WHEN IS THIS USED?

Page 70: Byzantine fault tolerant Cloud Storage for storing sensor data

WHEN IS THIS USED?

DATA IS PETABYTE SCALE

Page 71: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS PETABYTE SCALE

…OR ATLEAST A COUPLE OF 100 TERABYTES A YEAR

WHEN IS THIS USED?

Page 72: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS PETABYTE SCALE

…OR ATLEAST A COUPLE OF 100 TERABYTES A YEAR

DATA IS CONTINOUSLY ADDED

WHEN IS THIS USED?

Page 73: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS PETABYTE SCALE

…OR ATLEAST A COUPLE OF 100 TERABYTES A YEAR

DATA IS CONTINOUSLY ADDED

TIME BETWEEN BATCHES IS TOO LONG

WHEN IS THIS USED?

Page 74: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS PETABYTE SCALE

…OR ATLEAST A COUPLE OF 100 TERABYTES A YEAR

DATA IS CONTINOUSLY ADDEDTIME BETWEEN BATCHES IS TOO LONG

KEEPING THOUSANDS OF MACHINES RUNNING IS EXPENSIVE

WHEN IS THIS USED?

Page 75: Byzantine fault tolerant Cloud Storage for storing sensor data

DATA IS PETABYTE SCALE

…OR ATLEAST A COUPLE OF 100 TERABYTES A YEAR

DATA IS CONTINOUSLY ADDEDTIME BETWEEN BATCHES IS TOO LONG

KEEPING THOUSANDS OF MACHINES RUNNING IS EXPENSIVE

WHAT IF MY HADOOP CLUSTER IS DESTROYED?

WHEN IS THIS USED?

Page 76: Byzantine fault tolerant Cloud Storage for storing sensor data

New Data

All data

Streaming cluster

Batch cluster Batch view

Realtime view

ClientQuery

Query

Page 77: Byzantine fault tolerant Cloud Storage for storing sensor data

WHY NOT HADOOP?

Page 78: Byzantine fault tolerant Cloud Storage for storing sensor data

WHY NOT HADOOP?

HADOOP STILL HAS ITS PLACE

Page 79: Byzantine fault tolerant Cloud Storage for storing sensor data

WHY NOT HADOOP?

HADOOP STILL HAS ITS PLACE

JUST NOT FOR STORAGE

Page 80: Byzantine fault tolerant Cloud Storage for storing sensor data

New Data

All data

Streaming cluster

Batch cluster Batch view

Realtime view

ClientQuery

Query

Page 81: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?

Page 82: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?BATCH LAYER IS AN EXCELLENT PLACE FOR HADOOP PROCESSING

Page 83: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?BATCH LAYER IS AN EXCELLENT PLACE FOR HADOOP PROCESSING

BUT HADOOP STORAGE IS EXPENSIVE!

Page 84: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?BATCH LAYER IS AN EXCELLENT PLACE FOR HADOOP PROCESSING

BUT HADOOP STORAGE REQUIRES MAINTENANCE!

Page 85: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?BATCH LAYER IS AN EXCELLENT PLACE FOR HADOOP PROCESSING

BUT HADOOP STORAGE IS ONLINE EVEN WHEN IDLE!

Page 86: Byzantine fault tolerant Cloud Storage for storing sensor data

OK…WHY NOT HADOOP STORAGE?BATCH LAYER IS AN EXCELLENT PLACE FOR HADOOP PROCESSING

BUT HADOOP STORAGE CONSUMES LOTS OF ENERGY!

Page 87: Byzantine fault tolerant Cloud Storage for storing sensor data

DOES THIS WORK?

Page 88: Byzantine fault tolerant Cloud Storage for storing sensor data

PERFORMANCE

Requests done by 16 threads concurrently

Page 89: Byzantine fault tolerant Cloud Storage for storing sensor data

PERFORMANCE

Requests done by 16 threads concurrently

8 core virtual machine

at least 4 GB RAM (but often > 16GB)

Page 90: Byzantine fault tolerant Cloud Storage for storing sensor data

PERFORMANCE

Requests done by 16 threads concurrently

8 core virtual machine

At least 4 GB RAM (but often > 16GB)

f = 1, thus n = 4

Page 91: Byzantine fault tolerant Cloud Storage for storing sensor data

PERFORMANCE

Requests done by 16 threads concurrently

8 core virtual machine

At least 4 GB RAM (but often > 16GB)

f = 1, thus n = 4

Two implementations:

Streaming DepSky-A

Streaming DepSky-CA

Page 92: Byzantine fault tolerant Cloud Storage for storing sensor data

PERFORMANCE

Throughput downstream (per thread):

Filesize 4MB, 750 KB/second (90th percentile)

Filesize 8MB, 1 MB/second (90th percentile)

Throughput upstream (per thread):

Filesize 4MB, 1.2 MB/second (90th percentile)

Filesize 8MB, 1.7 MB/second (90th percentile)

Page 93: Byzantine fault tolerant Cloud Storage for storing sensor data

0.9997

0.9998

0.9999

1.0000

0 5 10 15 20 25

log2(Filesize (b))

Success r

ate

HTTP Verb

GET

PUT

DELETE

LIST

Streaming DepSky-A

0.994

0.996

0.998

1.000

0 5 10 15 20 25

log2(Filesize (b))

Success r

ate

HTTP Verb

GET

PUT

DELETE

LIST

Streaming DepSky-CA

AVAILABILITY

Page 94: Byzantine fault tolerant Cloud Storage for storing sensor data

thanks!

Page 95: Byzantine fault tolerant Cloud Storage for storing sensor data

Thesis available at:

http://www.cs.rug.nl/~aiellom/tesi/vdtil.pdf