132
1 SDDS-2000 : A SDDS-2000 : A Prototype System for Prototype System for Scalable Distributed Scalable Distributed Data Structures on Data Structures on Windows 2000 Windows 2000 Witold Litwin Witold Litwin [email protected] [email protected]

1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

Embed Size (px)

Citation preview

Page 1: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

1

SDDS-2000 : A Prototype System SDDS-2000 : A Prototype System for Scalable Distributed Data for Scalable Distributed Data Structures on Windows 2000Structures on Windows 2000

Witold LitwinWitold Litwin

[email protected]@dauphine.fr

Page 2: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

2

PlanPlanPlanPlan

What are SDDSs ?What are SDDSs ? Where are we in 200Where are we in 20022 ? ?

– LH* : Scalable Distributed Hash Partitioning LH* : Scalable Distributed Hash Partitioning – Scalable Distributed Range Partitioning RP*Scalable Distributed Range Partitioning RP*– High-Availability : LH*High-Availability : LH*RS RS & RP*& RP*RSRS

– DBMS coupling : AMOS-SDDS & SD-AMOSDBMS coupling : AMOS-SDDS & SD-AMOS Architecture of SDDS-2000Architecture of SDDS-2000 Experimental performance resultsExperimental performance results ConclusionConclusion

– Future workFuture work

Page 3: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

3

What is an SDDSWhat is an SDDSWhat is an SDDSWhat is an SDDS

A new type of data structureA new type of data structure– Specifically for Specifically for multicomputersmulticomputers

Designed for Designed for data intensivedata intensive files : files :– horizontalhorizontal scalability to very large sizes scalability to very large sizes

» larger than any single-site filelarger than any single-site file

– parallel and distributed processing parallel and distributed processing » especially in (distributed) RAMespecially in (distributed) RAM

– Record access time better than for any disk fileRecord access time better than for any disk file– 100-300 100-300 s usually under Win 2000 (100 Mb/s net, 700 s usually under Win 2000 (100 Mb/s net, 700

MHZ CPU, 100B – 1 KB records)MHZ CPU, 100B – 1 KB records)

– access by multiple autonomous clientsaccess by multiple autonomous clients

Page 4: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

4

Killer appsKiller appsKiller appsKiller apps Any traditional application using a large hash or B-Any traditional application using a large hash or B-

tree or k-d filetree or k-d file– Access time to an RAM SDDS record is 100 faster than to Access time to an RAM SDDS record is 100 faster than to

a disk record a disk record

Network storage servers (SNA and NAS) Network storage servers (SNA and NAS) DBMSsDBMSs WEB serversWEB servers Video serversVideo servers Real-time systemsReal-time systems High Perf. Comp.High Perf. Comp.

Page 5: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

5

MulticomputersMulticomputersMulticomputersMulticomputers A collection of loosely coupled computersA collection of loosely coupled computers

– common and/or preexisting hardwarecommon and/or preexisting hardware– share nothing architectureshare nothing architecture– message passing through message passing through high-speedhigh-speed net ( net (Mb/s)Mb/s)

Network Network multicomputersmulticomputers– use general purpose netsuse general purpose nets

» LANs: Ethernet, Token Ring, Fast Ethernet, SCI, FDDI...LANs: Ethernet, Token Ring, Fast Ethernet, SCI, FDDI...» WANs: ATM...WANs: ATM...

SwitchedSwitched multicomputers multicomputers– use a bus, or a switchuse a bus, or a switch

» e.g., IBM-SP2, Parsytece.g., IBM-SP2, Parsytec

Page 6: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

6

Client

Server

Typical Network Multicomputer

Network segments

Page 7: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

7

Why multicomputers ?Why multicomputers ?Why multicomputers ?Why multicomputers ? Potentially unbeatable price-performance ratioPotentially unbeatable price-performance ratio

– Much cheaper and more powerful than supercomputersMuch cheaper and more powerful than supercomputers» 1500 WSs at HPL with 500+ GB of RAM & TBs of disks1500 WSs at HPL with 500+ GB of RAM & TBs of disks

Potential computing powerPotential computing power– file sizefile size– access and processing timeaccess and processing time– throughputthroughput

For more pro & cons :For more pro & cons :– Bill Gates at Microsoft Scalability DayBill Gates at Microsoft Scalability Day– NOW project (UC Berkeley)NOW project (UC Berkeley)– Tanenbaum: "Distributed Operating Systems", Prentice Hall, 1995Tanenbaum: "Distributed Operating Systems", Prentice Hall, 1995– www.microoft.com White Papers from Business Syst. Div. www.microoft.com White Papers from Business Syst. Div.

Page 8: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

8

Why SDDSsWhy SDDSsWhy SDDSsWhy SDDSs

Multicomputers need data structures and file Multicomputers need data structures and file systemssystems

Trivial extensions of traditional structures are Trivial extensions of traditional structures are not bestnot best

hot-spotshot-spots scalabilityscalability parallel queriesparallel queries distributed and autonomous clientsdistributed and autonomous clients distributed RAM & distance to datadistributed RAM & distance to data

Page 9: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

9

Distance to dataDistance to data(Jim Gray)(Jim Gray)

Distance to dataDistance to data(Jim Gray)(Jim Gray)

100 ns

1 sec

10 msec

RAM

distant RAM(gigabit net)

local disk

100 sec distant RAM(Ethernet)

Page 10: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

10

Distance to DataDistance to Data(Jim Gray)(Jim Gray)

Distance to DataDistance to Data(Jim Gray)(Jim Gray)

1 s

10 s

10 ms

RAM

distant RAM(gigabit net)

100 s distant RAM(Ethernet)

1 m

10 m

2 h

8 d

Moon

local disk

Page 11: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

11

Scalability Dimensions Scalability Dimensions (Client view)(Client view)

Data size# servers and # clients

Operation time (distant RAM)

# operation / s

Scale-up

Linear (idéal)

Sub-linear (usuel)

Page 12: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

12

Scalability Dimensions Scalability Dimensions (Client view, SDDS specific)(Client view, SDDS specific)

Data size

Multicomputer & SDDS

Scale-up

Linear

Sub-linear (usuel)

Disk & Cache

Tapes, juke-box…

Cache & Disk

Operation time

Single comp.Local RAM

Cluster- Computer

Cluster-Computer- = fix # of servers

Page 13: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

13

Scalability Dimensions Scalability Dimensions (Client view)(Client view)

# servers

# operations/ s

Speed-upLinear (ideal)

Sub-linear (usuel)

Page 14: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

14

What is an SDDS ?What is an SDDS ?

Queries come from multiple autonomous Queries come from multiple autonomous clientsclients

Data are on Data are on serversservers Data are Data are structuredstructured

records with keys records with keys objects with OIDs objects with OIDs more semantics than in Unix flat-file modelmore semantics than in Unix flat-file model abstraction most popular with applicationsabstraction most popular with applications parallel scans & function shippingparallel scans & function shipping

OverflowingOverflowing servers servers splitsplit into new servers into new servers

Page 15: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

15

An SDDSAn SDDSAn SDDSAn SDDS

Clients

growth through splits under inserts

Servers

Page 16: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

16

An SDDSAn SDDSAn SDDSAn SDDS

Clients

growth through splits under inserts

Servers

Page 17: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

17

An SDDSAn SDDSAn SDDSAn SDDS

Clients

growth through splits under inserts

Servers

Page 18: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

18

An SDDSAn SDDSAn SDDSAn SDDS

Clients

growth through splits under inserts

Servers

Page 19: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

19

SDDS SDDS : Addressing Principles : Addressing Principles

SDDS ClientsSDDS Clients Are notAre not informed about the splits. informed about the splits. Do notDo not access any access any centralizedcentralized directory for record address directory for record address

computationscomputations HaveHave each a less or more adequate private each a less or more adequate private imageimage of the actual of the actual

file structurefile structure Can makeCan make addressing errorsaddressing errors

Sending queries or records to Sending queries or records to incorrectincorrect server serverss Searching for a record that was moved elsewhere by splitsSearching for a record that was moved elsewhere by splits Sending a record that should be elsewhere for the same Sending a record that should be elsewhere for the same

reasonreason

Page 20: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

20

Servers are able to Servers are able to forwardforward the queries to the the queries to the correct addresscorrect address

– perhaps in several messagesperhaps in several messages

Servers may send Servers may send Image Adjustment Image Adjustment MessagesMessages

» Clients do not make same error twiceClients do not make same error twice Servers supports parallel scansServers supports parallel scans

Sent out by Sent out by multicastmulticast or or unicastunicastWith With deterministicdeterministic or or probabilisticprobabilistic termination termination

See the SDDS talk & papers for more See the SDDS talk & papers for more – ceria.dauphine.fr/witold.htmlceria.dauphine.fr/witold.html

Or the LH* ACM-TODS paper (Dec. 96)Or the LH* ACM-TODS paper (Dec. 96)

What is an SDDS ?What is an SDDS ?SDDS : Addressing Principles

Page 21: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

21

An SDDSAn SDDSClient AccessClient Access

Clients

Page 22: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

22

Clients

An SDDSClient Access

Page 23: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

23

Clients

IAM

An SDDSAn SDDSClient AccessClient Access

Page 24: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

24

Clients

An SDDSAn SDDSClient AccessClient Access

Page 25: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

25

Clients

An SDDSAn SDDSClient AccessClient Access

Page 26: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

26

Known SDDSsKnown SDDSsKnown SDDSsKnown SDDSs

Hash

SDDS(1993)

1-d tree LH* DDH

Breitbart & alRP*

Kroll & WidmayerBreitbart & Vingralek

m-d trees

DS

Classics

LH*s

k-RP*dPi-tree

Nardelli-tree

s-availabilityLH*SA

LH*RS http://ceria.dauphine/SDDS-bibliograhie.html

SDLSA

Disk

LH*m, LH*gSecurity

Page 27: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

27

LH* LH* (A classic)(A classic)LH* LH* (A classic)(A classic) Scalable distributed hash partitioningScalable distributed hash partitioning

– Transparent for the applicationsTransparent for the applications» Unlike the current static schemes (i.e. DB2)Unlike the current static schemes (i.e. DB2)

– Generalizes the LH addressing schemaGeneralizes the LH addressing schema» used in used in many productsmany products

– SQL-Server, SQL-Server, IIS, MsExchangeIIS, MsExchange,, Frontpage Frontpage, , Netscape Netscape suitessuites,, Berkeley DB LibraryBerkeley DB Library,, LH-Server, Unify... LH-Server, Unify...

Typical load factor 70 - 90 %Typical load factor 70 - 90 % In practice, at most 2 forwarding messagesIn practice, at most 2 forwarding messages

– regardless of the size of the fileregardless of the size of the file In general, 1 In general, 1 message/insert and 2 messages/search on the message/insert and 2 messages/search on the

averageaverage 4 messages in the worst case4 messages in the worst case Several variants are knownSeveral variants are known

– LH*LH*LHLH is most studied is most studied

Page 28: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

28

Overview of LHOverview of LHOverview of LHOverview of LH Extensible hash algorithmExtensible hash algorithm

– Widely Widely used, e.g., used, e.g., » Netscape browser (100M copies)Netscape browser (100M copies)» LH-Server by AR (700K copies sold)LH-Server by AR (700K copies sold)» MS Frontpage, Exchange, IIS MS Frontpage, Exchange, IIS

– tought in most DB and DS classestought in most DB and DS classes– address space expandsaddress space expands

» to avoid overflows & access performance to avoid overflows & access performance deterioration deterioration

the file has buckets with capacity the file has buckets with capacity bb >> 1 >> 1 Hash by division Hash by division hhii : c -> c : c -> c mod 2 mod 2i i NN provides the address provides the address

h (c)h (c) of key of key cc.. Buckets split through the replacement of hBuckets split through the replacement of hii with with h h ii+1 +1 ; ; i = i =

0,1,..0,1,.. On the average, On the average, b/2 b/2 keys move towards new bucketkeys move towards new bucket

Page 29: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

29

Overview of LHOverview of LHOverview of LHOverview of LH

Basically, a split occurs when some bucket Basically, a split occurs when some bucket m m overflowsoverflows

One splits bucket One splits bucket n, n, pointed by pointer pointed by pointer nn..– usually usually m m nn

n n évolue : 0, 0,1, 0,1,..,2, 0,1..,3, 0,..,7, 0,..,2évolue : 0, 0,1, 0,1,..,2, 0,1..,3, 0,..,7, 0,..,2i i NN, 0.., 0.. One consequence => no index One consequence => no index

– characteristic of other EH schemescharacteristic of other EH schemes

Page 30: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

30

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

351271524

h0 ; n = 0

N = 1b = 4i = 0

hh00 : c -> : c -> 2200

0

Page 31: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

31

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

351271524

h1 ; n = 0

N = 1b = 4i = 0

hh11 : c -> : c -> 2211

0

Page 32: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

32

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

1224

h1 ; n = 0

N = 1b = 4i = 1

hh11 : c -> : c -> 2211

0

35715

1

Page 33: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

33

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

32581224

N = 1b = 4i = 1

hh11 : c -> : c -> 2211

0

211135715

1

hh11 hh11

Page 34: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

34

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

321224

N = 1b = 4i = 1

hh22 : c -> : c -> 2222

0

211135715

1

58

2

hh22 hh11 hh22

Page 35: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

35

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

321224

N = 1b = 4i = 1

hh22 : c -> : c -> 2222

0

33211135715

1

58

2

hh22 hh11 hh22

Page 36: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

36

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

321224

N = 1b = 4i = 1

hh22 : c -> : c -> 2222

0

3321

1

58

2

hh22 hh22 hh22

1135715

3

hh22

Page 37: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

37

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

321224

N = 1b = 4i = 2

hh22 : c -> : c -> 2222

0

3321

1

58

2

hh22 hh22 hh22

1135715

3

hh22

Page 38: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

38

LH File EvolutionLH File EvolutionLH File EvolutionLH File Evolution

EtcEtc– One starts One starts hh3 3 then then hh4 4 ......

The file can expand as much as needed The file can expand as much as needed

– without too many overflows everwithout too many overflows ever

Page 39: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

39

Addressing AlgorithmAddressing AlgorithmAddressing AlgorithmAddressing Algorithm

a <- h (i, c) a <- h (i, c)

if if n n = 0 then exit = 0 then exit

elseelse

if a < n then a <- h (i+1, c) ;if a < n then a <- h (i+1, c) ;

endend

Page 40: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

40

LH*LH*LH*LH*

Property of LH :Property of LH :– Given Given j = i j = i or or j = i j = i + 1, key + 1, key c c is in bucket is in bucket m m iffiff

hhj j ((cc) = ) = m ; j = i m ; j = i oror j = i j = i + 1+ 1» Verify yourselfVerify yourself

Ideas for LH* :Ideas for LH* :– LH addresing rule = global rule for LH* fileLH addresing rule = global rule for LH* file– every bucket at a serverevery bucket at a server– bucket level bucket level j j in the header in the header – Check the LH property when the key comes form a Check the LH property when the key comes form a

clientclient

Page 41: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

41

LH* : file structure LH* : file structure LH* : file structure LH* : file structure

j = 4

0

j = 4

1

j = 3

2

j = 3

7

j = 4

8

j = 4

9

n = 2 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

Page 42: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

42

LH* : file structureLH* : file structureLH* : file structureLH* : file structure

j = 4

0

j = 4

1

j = 3

2

j = 3

7

j = 4

8

j = 4

9

n = 2 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

Page 43: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

43

LH* : splitLH* : splitLH* : splitLH* : split

j = 4

0

j = 4

1

j = 3

2

j = 3

7

j = 4

8

j = 4

9

n = 2 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

Page 44: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

44

LH* : splitLH* : splitLH* : splitLH* : split

j = 4

0

j = 4

1

j = 3

2

j = 3

7

j = 4

8

j = 4

9

n = 2 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

Page 45: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

45

LH* : splitLH* : splitLH* : splitLH* : split

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

Page 46: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

46

LH* Addressing SchemaLH* Addressing SchemaLH* Addressing SchemaLH* Addressing Schema

Client Client – computes the LH address computes the LH address m m of of c c using its image, using its image, – send send c c to bucket to bucket mm

ServerServer– Server Server a a getting key getting key cc, , a a = = m m in particular,in particular, computes :computes :

a' := ha' := hjj (c) ; (c) ;

if if a' = a a' = a thenthen accept accept c ; c ;

else else a'' := ha'' := hj - j - 11 (c) ;(c) ;

if if a'' > a a'' > a and and a'' a'' < < a' a' then then a' a' := := a'' ; a'' ; send send c c to bucket to bucket a' ;a' ;

Page 47: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

47

LH* Addressing SchemaLH* Addressing SchemaLH* Addressing SchemaLH* Addressing Schema Client Client

– computes the LH address computes the LH address m m of of c c using its image, using its image, – send send c c to bucket to bucket mm

ServerServer– Server Server a a getting key getting key cc, , a a = = m m in particular,in particular, computes :computes :

a' := ha' := hjj (c) ; (c) ;

if if a' = a a' = a thenthen accept accept c ; c ;

else else a'' := ha'' := hj - j - 11 (c) ;(c) ;

if if a'' > a a'' > a and and a'' a'' < < a' a' then then a' a' := := a'' ; a'' ; send send c c to bucket to bucket a' ;a' ;

See [LNS93] for the (long) proof

Simple ?

Page 48: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

48

Client Image AdjustementClient Image AdjustementClient Image AdjustementClient Image Adjustement The IAM consists of address The IAM consists of address a a where the client sent where the client sent c c and and

of of j j ((aa))– i' i' is presumed is presumed i i in client's in client's image.image.– n' n' is preumed value of pointer is preumed value of pointer n n in client's in client's image.image.– initially, initially, i' i' = = n' n' = 0.= 0.

if if j j > > i' i' then then i' i' := := j - j - 1, 1, n' n' := := a +a +1 ; 1 ;

if if n' n' 2^2^i' i' then then n' n' = 0, = 0, i' i' := := i' i' +1 ;+1 ;

The algo. garantees that client image is within the file The algo. garantees that client image is within the file [LNS93][LNS93]– if there is no file contractions (merge)if there is no file contractions (merge)

Page 49: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

49

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

15

Page 50: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

50

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

15

Page 51: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

51

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 1, i' = 3 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

15

j = 4

Page 52: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

52

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

9

Page 53: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

53

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

9

Page 54: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

54

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 0, i' = 0 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

9

Page 55: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

55

LH* : addressingLH* : addressingLH* : addressingLH* : addressing

j = 4

0

j = 4

1

j = 4

2

j = 3

7

j = 4

8

j = 4

9

n = 3 ; i = 3

n' = 1, i' = 3 n' = 3, i' = 2 Coordinator

Client Client

servers

j = 4

10

9

j = 4

Page 56: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

56

ResultResultResultResult

The distributed file can grow to even whole The distributed file can grow to even whole Internet so that :Internet so that :– every insert and search are done in four every insert and search are done in four

messages (IAM included)messages (IAM included)– in general an insert is done in one message in general an insert is done in one message

and search in two messagesand search in two messages– proof in [LNS 93]proof in [LNS 93]

Page 57: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

57

10,000 inserts

Global cost

Client's cost

Page 58: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

58

Page 59: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

59

Page 60: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

60

Inserts by two clients

Page 61: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

61

Parallel QueriesParallel QueriesParallel QueriesParallel Queries A query A query QQ for all buckets of file for all buckets of file FF with independent local with independent local

executionsexecutions– everyevery buckets should get buckets should get Q Q exactly once exactly once

The basis for function shippingThe basis for function shipping– fundamental for high-perf. DBMS appl.fundamental for high-perf. DBMS appl.

Send Mode :Send Mode :– multicastmulticast

» not always possible or convenientnot always possible or convenient– unicastunicast

» client may not know all the serversclient may not know all the servers» severs have to forward the querysevers have to forward the query

– how ??how ??Image

File

Q

Page 62: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

62

LH* Algorithm for LH* Algorithm for Parallel QueriesParallel Queries(unicast)(unicast)

LH* Algorithm for LH* Algorithm for Parallel QueriesParallel Queries(unicast)(unicast)

Client sends Client sends Q Q to every bucket to every bucket a a in the imagein the image The message with The message with QQ has the has the message level message level jj' :' :

– initialy initialy j' =j' = i' i' if if n' n' i'i' elseelse j' = j' = i' + i' + 11

– bucket bucket a a (of level (of level j j ) copies ) copies Q Q to all its children using to all its children using the alg. :the alg. :

while while j' j' < < j j dodo

j' j' := := j' j' + 1+ 1

forward (forward (QQ, , j' j' ) to bucket ) to bucket a a + 2 + 2 j' - j' - 1 1 ; ;

endwhileendwhile Prove it !Prove it !

Page 63: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

63

Termination of Termination of Parallel QueryParallel Query (multicast or unicast)(multicast or unicast)

Termination of Termination of Parallel QueryParallel Query (multicast or unicast)(multicast or unicast)

How client How client C C knows that last reply came ?knows that last reply came ? Deterministic Solution (expensive)Deterministic Solution (expensive)

– Every bucket sends its Every bucket sends its j, m j, m and selected records if anyand selected records if any

» m m is its (logical) addressis its (logical) address

– The client terminates when it has every The client terminates when it has every m m fullfiling the fullfiling the condition ;condition ;

» m = m = 0,1..., 2 0,1..., 2 i i + n + n wherewhere– i i = min (= min (jj)) and and n n = min (= min (mm) where ) where j = i j = i

i+1 i i+1n

Page 64: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

64

Termination of Termination of Parallel QueryParallel Query (multicast or unicast)(multicast or unicast)

Termination of Termination of Parallel QueryParallel Query (multicast or unicast)(multicast or unicast)

Probabilistic Termination ( may need less messaging)Probabilistic Termination ( may need less messaging)– all and only buckets with selected records replyall and only buckets with selected records reply– after each reply after each reply C C reinitialises a time-out reinitialises a time-out TT– C C terminates when terminates when T T expiresexpires

Practical choice of Practical choice of T is T is network and query dependentnetwork and query dependent– ex. 5 times Ethernet everage retry timeex. 5 times Ethernet everage retry time

» 1-2 msec ?1-2 msec ?– experiments neededexperiments needed

Which termination is finally more useful in practice ?Which termination is finally more useful in practice ?– an open probleman open problem

Page 65: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

65

LH* variantsLH* variantsLH* variantsLH* variants With/without load (factor) controlWith/without load (factor) control With/without the (split) coordinatorWith/without the (split) coordinator

– the former one was discussedthe former one was discussed

– the latter one is a token-passing schemathe latter one is a token-passing schema

» bucket with the token is next to splitbucket with the token is next to split– if an insert occurs, and file overload is guessedif an insert occurs, and file overload is guessed

– several algs. for the decisionseveral algs. for the decision

– use cascading splitsuse cascading splits

See the talk on LH* at See the talk on LH* at http://http://ceriaceria.dauphine..dauphine.frfr//

Page 66: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

66

RP* schemesRP* schemesRP* schemesRP* schemes

Produce scalable distributed 1-d ordered filesProduce scalable distributed 1-d ordered files– for range searchfor range search

Each bucket (server) has the unique rEach bucket (server) has the unique r ange ange of keys it may containof keys it may contain

Ranges partition the key spaceRanges partition the key space Ranges evolve dynamically through splitsRanges evolve dynamically through splits

– Transparently for the application Transparently for the application Use RAM m-ary trees at each serverUse RAM m-ary trees at each server

– Like B-treesLike B-trees– Optimized for the RP* split efficiencyOptimized for the RP* split efficiency

Page 67: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

67

Current PDBMS technologyCurrent PDBMS technology (Ex. Non-Stop SQL) (Ex. Non-Stop SQL)

Current PDBMS technologyCurrent PDBMS technology (Ex. Non-Stop SQL) (Ex. Non-Stop SQL)

Static Range PartitioningStatic Range Partitioning Done manually by DBADone manually by DBA Requires goods skillsRequires goods skills Not scalableNot scalable

Page 68: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

68

Fig. 1 RP* design trade-offs

RP*N

RP*C

RP*S

No index all multicast

+ client index limited multicast

+ servers index optional multicast

RP* schemesRP* schemesRP* schemesRP* schemes

Page 69: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

69

High-availability SDDS schemesHigh-availability SDDS schemesHigh-availability SDDS schemesHigh-availability SDDS schemes Data remain available despite :Data remain available despite :

– any single server failure & most of two server failuresany single server failure & most of two server failures– or any up to or any up to n-n-serverserver failurefailure– and some catastrophic failuresand some catastrophic failures

n n scales with the file sizescales with the file size– To offset the reliability decline which would otherwise To offset the reliability decline which would otherwise

occuroccur Three principles for high-availability SDDS Three principles for high-availability SDDS

schemes are currently knownschemes are currently known– mirroring (LH*m)mirroring (LH*m)– striping (LH*s)striping (LH*s)– grouping (LH*g, LH*sa, LH*rs, RP* rs)grouping (LH*g, LH*sa, LH*rs, RP* rs)

Realize different performance trade-offsRealize different performance trade-offs

Page 70: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

70

LH*LH*RS RS : Record Groups : Record GroupsLH*LH*RS RS : Record Groups : Record Groups

LH*LH*RSRS records records– LH* LH* datadata records & records & parityparity records records

Records with same Records with same rank rrank r in the bucket group form a in the bucket group form a record record groupgroup

Each record group gets Each record group gets n parityn parity records records– Computed using Reed-Salomon erasure correction codesComputed using Reed-Salomon erasure correction codes

» Additions ans multiplications in Galois FieldsAdditions ans multiplications in Galois Fields» See the Sigmod 2000 paper on the Web site for detailsSee the Sigmod 2000 paper on the Web site for details

r r is the common key of these recordsis the common key of these records Each group supports unavailability of up to Each group supports unavailability of up to n n of its of its

membersmembers

Page 71: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

71

LH*LH*RSRS Record Groups Record Groups LH*LH*RSRS Record Groups Record Groups

Data records Parity records

Page 72: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

72

LH*LH*RS RS : Parity Management : Parity ManagementLH*LH*RS RS : Parity Management : Parity Management

An insert of data record with rank An insert of data record with rank r r creates or, creates or, usually, updates parity records usually, updates parity records rr

An update of data record with rank An update of data record with rank r r updates updates parity records parity records rr

A split recreates parity recordsA split recreates parity records– Data record usually change the rank after the splitData record usually change the rank after the split

Page 73: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

73

LH*LH*RS RS Scalable availabilityScalable availabilityLH*LH*RS RS Scalable availabilityScalable availability

Create 1 parity bucket per group until Create 1 parity bucket per group until M = M = 22ii11 bucketsbuckets

Then, aThen, at each split, t each split, – add 2add 2nd nd parity bucket to each existing group parity bucket to each existing group

– create 2 parity buckets for new groups until 2create 2 parity buckets for new groups until 2ii22 bucketsbuckets

etc.etc.

Page 74: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

74

LH*LH*RS RS Scalable availabilityScalable availabilityLH*LH*RS RS Scalable availabilityScalable availability

Page 75: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

75

LH*LH*RS RS Scalable availabilityScalable availability

Page 76: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

76

LH*LH*RS RS Scalable availabilityScalable availability

Page 77: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

77

LH*LH*RS RS Scalable availabilityScalable availability

Page 78: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

78

LH*LH*RS RS Scalable availabilityScalable availability

Page 79: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

79

SDDS-2000 : global architectureSDDS-2000 : global architecture

Page 80: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

80

SDDS-2000 : global architectureSDDS-2000 : global architecture

Applications ApplicationsApplications etc

SDDS Data server

SDDS Data server

SDDS Data server

SDDS-2000 Server SDDS-2000 Server SDDS-2000 Server

SDDS-2000 Client SDDS-2000 Client SDDS-2000 Client SDDS-2000 Client

NetworkUDP & TCP

Page 81: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

81

SDDS-2000: Client Architecture SDDS-2000: Client Architecture (RP*c)(RP*c)

SDDS-2000: Client Architecture SDDS-2000: Client Architecture (RP*c)(RP*c)

Receive Module Send Module

. . .

Requests Journal

Update

Return Response

Get Request

Client

Application 1

IP Add.

Request

Images

Response

Network (TCP/ IP, UDP)

Send Request

Receive Response

Server

Key IP Add. … …

SDDS Applications Interface

Analyze Response

Id_Req Id_App … …

Client Flow control

Manager

Application N . . .

Server

1 4 …

2 Modules2 Modules

Send ModuleSend Module

Receive Receive ModuleModule

Multithread Multithread ArchitectureArchitecture

SendRequestSendRequest

ReceiveRequesReceiveRequestt

AnalyzeResponAnalyzeResponse1..4se1..4

GetRequestGetRequest

ReturnResponsReturnResponsee

Synchronization Synchronization Queues Queues

Client ImagesClient Images

Flow controlFlow control

Page 82: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

82

SDDS-2000: Server Architecture SDDS-2000: Server Architecture (RP*c)(RP*c)

SDDS-2000: Server Architecture SDDS-2000: Server Architecture (RP*c)(RP*c)

. . .

Response

Results Results

Execution

Main memory Server

RP* Buckets

Network (TCP/ IP, UDP)

Response

W.Thread 1

W.Thread N

ListenThread

Client

. . .

RP* Functions : Insert, Search, Update, Delete, Forward, Splite.

. . .

Request Analyze

BAT

SendAck

Requests queue

Ack queue

Client

Multithread Multithread architecturearchitecture

Synchronization Synchronization queues queues

Listen Thread for Listen Thread for incoming requestsincoming requests

SendAck Thread for SendAck Thread for flow control flow control

Work Threads for Work Threads for

request request processing processing

response sendoutresponse sendout

request request forwardingforwarding

UDP for shorter UDP for shorter messages messages (< 64K)(< 64K)

TCP/IP for longer TCP/IP for longer data exchangesdata exchanges

Several buckets of Several buckets of different SDDS filesdifferent SDDS files

Page 83: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

83

AMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS Architecture

For database queriesFor database queries– Especially parallel scansEspecially parallel scans

Couples SDDS-2000 and Amos II :Couples SDDS-2000 and Amos II :– RAM OR-DBMS. RAM OR-DBMS. – AMOSQL declarative query language AMOSQL declarative query language

» can be embedded into C and Lisp. can be embedded into C and Lisp.

– call-level interfacecall-level interface ( (callin ) callin ) – external procedures (functions) (callout) external procedures (functions) (callout)

See the AMOS-II talk & papers for more See the AMOS-II talk & papers for more

http://www.dis.uu.se/~udbl/http://www.dis.uu.se/~udbl/

Page 84: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

84

AMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS Architecture SDDS is used as the distributed RAM storage manager. SDDS is used as the distributed RAM storage manager.

– RP* scheme for the scalable distributed range RP* scheme for the scalable distributed range partitioning. partitioning.

– Like in a B-tree, records are lexicographically Like in a B-tree, records are lexicographically ordered according to their keys. ordered according to their keys.

– Supports efficiently the range queries. Supports efficiently the range queries. Amos II provide a fast SDDS-based RAM OR-DBMS.Amos II provide a fast SDDS-based RAM OR-DBMS. The callout capability realizes the AMOSQLThe callout capability realizes the AMOSQL object-object-

relational capability usually called relational capability usually called external external or or foreign foreign functions. functions.

Page 85: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

85

AMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS Architecture

AMOS-SDDS Architecture

Network

AMOS-SDDS Server

AMOS-SDDS Client

AMOS II

SDDS Client SDDS Server

AMOS II

Callout Callout

Callin

AMOS-SDDS Server

SDDS Server

AMOS II

Callout

Callin

AMOS-SDDS Application

SDDS Application

Page 86: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

86

AMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS ArchitectureAMOS-SDDS Architecture

AMOS-SDDS scalable distributed query processing

Network

AMOS-SDDS Server AMOS-SDDS Client

SDDS Client

Client AMOS II Server AMOS II process-AMOS(query)

Ship(query) Results

Send-AMOS(query)

Send-AMOS(Buffer)

Receive-AMOS(query)

SDDS Server

Results(scan)

external functions

SDDS bucket

Send-SDDS(query) Process-SDDS(query)

Send-SDDS(Buffer)

Receive-AMOS(Buffer)

Receive-SDDS(Buffer)

Receive-SDDS(query)

Page 87: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

87

AMOS-SDDS AMOS-SDDS Server Query ProcessingServer Query Processing

AMOS-SDDS AMOS-SDDS Server Query ProcessingServer Query Processing

E-strategy E-strategy – Data stay external to AMOSData stay external to AMOS

» within the SDDS bucket within the SDDS bucket

– Custom foreign functions perform the queryCustom foreign functions perform the query I-strategy I-strategy

– Data are on-the-fly imported into AMOS-IIData are on-the-fly imported into AMOS-II» Perhaps with the local index creationPerhaps with the local index creation

– Good for joinsGood for joins

– AMOS performs the queryAMOS performs the query Which strategy is preferable ?Which strategy is preferable ?

– Good questionGood question

Page 88: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

88

SD-AMOSSD-AMOSSD-AMOSSD-AMOS

Server storage manager is a full scale DBMSServer storage manager is a full scale DBMS– AMOS-II in our case since it is a RAM DBMSAMOS-II in our case since it is a RAM DBMS

– Could be any DBMSCould be any DBMS

SDDS-2000 provides the scalable distributed SDDS-2000 provides the scalable distributed partitioning schemapartitioning schema

Server DBMS performs the splitsServer DBMS performs the splits– When et How ???When et How ???

Client manages scalable query decomposition & Client manages scalable query decomposition & executionexecution– Easier said than doneEasier said than done

The whole system generalizes the PDBMS technologyThe whole system generalizes the PDBMS technology– Static partitioning onlyStatic partitioning only

Page 89: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

89

Scalability AnalysisScalability AnalysisScalability AnalysisScalability Analysis

Theoretical Theoretical – To validate an SDDSTo validate an SDDS

» See the papersSee the papers

– To get an idea of system performanceTo get an idea of system performance» Limited validityLimited validity

ExperimentalExperimental– More accurate validation of design issuesMore accurate validation of design issues– Practical necessity Practical necessity – Costs orders of magnitude more of time and Costs orders of magnitude more of time and

money money

Page 90: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

90

ExperimentalExperimental Configuration ConfigurationExperimentalExperimental Configuration Configuration

6 machines : 700 Mhz P36 machines : 700 Mhz P3 100 Mb/s Ethernet100 Mb/s Ethernet 150 byte records 150 byte records

Page 91: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

91

LH* file creationLH* file creationLH* file creationLH* file creation

0

2

4

6

8

0 5000 10000 15000 20000Taille du fichier (enregistrements)

Tem

ps

(s)

sans éclatement avec éclatement

Ph. D Thesis of F. Bennour, 2000

00,1

0,20,3

0,40,5

0 5000 10000 15000 20000Taille du fichier (enregistrements)

Tem

ps

(ms)

sans éclatements avec éclatements012345678

0 1 2 3 4 5 6Nombre de case

Tem

ps

(s)

Bucket size b = 5.000

Flow control On

# of buckets

# of inserts

# of inserts

with splits w / splits

with splits w / splits

Tim

e (m

s)T

ime

(ms)

Tim

e (m

s)

LH* Scalability is confirmed

Performance bound by the client processing speed

Page 92: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

92

LH* Key searchLH* Key searchLH* Key searchLH* Key search

0,1

0,2

0,3

0,4

0,5

0 5000 10000 15000 20000Taille du fichier (enregistrements)

Tem

ps

(ms)

image client actualisée image client non-actualisée

File Size in records and # servers

Tim

e (m

s)

Actual client image New client image & IAMs

Performance bound by the client processing speed

2 3 4 5

Page 93: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

93

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

0,0000

0,5000

1,0000

1,5000

2,0000

2,5000

Nbre d'enregistrements insérés

Te

mp

s d

'inse

rtio

n d

'un

e

nre

g

k = 0 k = 1k = 2

Insert time during the file creationInsert time during the file creation(moving average)(moving average)

Number of records

Tim

e (m

s)

Page 94: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

94

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

File Creation Time File Creation Time

0,000

5,000

10,000

15,000

20,000

25,000

30,000

2500 5000 7500 10000 12500 15000 17500 20000 22500 25000

Nbre d'enregistrements insérés

Te

mp

s d

'inse

rtio

n

k = 0 k = 1 k = 2

Number of records

Tim

e (s

)

Page 95: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

95

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

Normal key searchNormal key search– Unaffected by the parity calculusUnaffected by the parity calculus

» 0.3 ms per key search0.3 ms per key search

Degraded key searchDegraded key search– About 2 ms for the application About 2 ms for the application

» 1.1 ms (k =4) for the record recovery 1.1 ms (k =4) for the record recovery

» 1 ms for the client time-out and the coordinator action1 ms for the client time-out and the coordinator action

Bucket recovery at the spareBucket recovery at the spare– 0.3 ms per record (k =4)0.3 ms per record (k =4)

Page 96: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

96

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

0,0000

0,5000

1,0000

1,5000

2,0000

2,5000

Nbre d'enregistrements insérés

Te

mp

s d

'inse

rtio

n d

'un

e

nre

g

k = 0 k = 1k = 2

Insert time during the file creationInsert time during the file creation(moving average)(moving average)

Number of records

Tim

e (m

s)

Page 97: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

97

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

File Creation Time File Creation Time

0,000

5,000

10,000

15,000

20,000

25,000

30,000

2500 5000 7500 10000 12500 15000 17500 20000 22500 25000

Nbre d'enregistrements insérés

Te

mp

s d

'inse

rtio

n

k = 0 k = 1 k = 2

Number of records

Tim

e (s

)

Page 98: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

98

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

LH*LH*RS RS Experimental PerformanceExperimental Performance(Preliminary results)(Preliminary results)

Normal key searchNormal key search– Unaffected by the parity calculusUnaffected by the parity calculus

» 0.3 ms per key search0.3 ms per key search

Degraded key searchDegraded key search– About 2 ms for the application About 2 ms for the application

» 1.1 ms (k =4) for the record recovery 1.1 ms (k =4) for the record recovery

» 1 ms for the client time-out and the coordinator action1 ms for the client time-out and the coordinator action

Bucket recovery at the spareBucket recovery at the spare– 0.3 ms per record (k =4)0.3 ms per record (k =4)

Page 99: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

99

Performance Analysis (RP*)Performance Analysis (RP*)Performance Analysis (RP*)Performance Analysis (RP*)

Experimental EnvironmentExperimental Environment SSix Pentium III 700 MHz ix Pentium III 700 MHz o Windows 2000Windows 2000– 128 MB RAM extended later to 256 MB RAM128 MB RAM extended later to 256 MB RAM– 100 Mb/s Ethernet100 Mb/s Ethernet

MessagesMessages– 180 bytes : 80 for the header, 100 for the record180 bytes : 80 for the header, 100 for the record– Keys are random integers within some intervalKeys are random integers within some interval– Flow Control sliding window of 10 messages Flow Control sliding window of 10 messages

IndexIndex–Capacity of an internal node : 80 index elementsCapacity of an internal node : 80 index elements–Capacity of a leaf : 100 recordsCapacity of a leaf : 100 records

Page 100: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

100

Performance Performance AnalysisAnalysisPerformance Performance AnalysisAnalysisFile CreationFile Creation

Bucket capacity : 50.000 recordsBucket capacity : 50.000 records150.000 random inserts by a single client 150.000 random inserts by a single client

With flow control (FC) or withoutWith flow control (FC) or without

0

10000

20000

30000

40000

50000

60000

70000

80000

0 50000 100000 150000Number of records

Tim

e (m

s)

Rp*c/ Without FC RP*c/ With FC

RP*n/ With FC RP*n/ Without FC

0.0000.1000.2000.3000.4000.500

0.6000.7000.8000.9001.000

0 50000 100000 150000Number of records

Tim

e (

ms)

RP*c without FC RP*c with FC

RP*n with FC RP*n without FC

File creation timeFile creation time Average insert timeAverage insert time

Page 101: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

101

DiscussionDiscussionDiscussionDiscussion

Creation time is Creation time is almost linearly scalablealmost linearly scalable Flow control is quite expensiveFlow control is quite expensive

– Losses without were negligibleLosses without were negligible

Both schemes perform almost equally wellBoth schemes perform almost equally well– RP*RP*C C slightly better slightly better

» As one could expectAs one could expect

Insert time Insert time 30 faster than for a disk file30 faster than for a disk file Insert time appears bound by the client speedInsert time appears bound by the client speed

Page 102: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

102

Performance AnalysisPerformance AnalysisFile CreationFile Creation

Performance AnalysisPerformance AnalysisFile CreationFile Creation

FFile created by 120.000 random inserts by 2 clientsile created by 120.000 random inserts by 2 clientsWithout flow controlWithout flow control

0

5000

10000

15000

20000

25000

30000

35000

40000

45000

0 50000 100000 150000

Number of records

Tim

e (m

s)

0.000

0.050

0.100

0.150

0.200

0.250

0.300

0.350

0.400

0.450

RP*c to. time / 2 clients

RP*n to. time / 2 clients

RP*c / Time per record

RP*n/ Time per record

0

10000

20000

30000

40000

50000

60000

0 50000 100000 150000 200000

Number of serversT

ime

(m

s)

RP*c / 1 client

RP*n / 1 client

RP*c to. time / 2 clients

RP*n to. time / 2 clients

File creation by two clients : total File creation by two clients : total time and per inserttime and per insert

Comparative fileComparative file creation time by creation time by one or two clients one or two clients

Page 103: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

103

DiscussionDiscussionDiscussionDiscussion

Performance improvesPerformance improves Insert times appear bound by a server speedInsert times appear bound by a server speed More clients would not improve More clients would not improve

performance of a serverperformance of a server

Page 104: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

104

Performance AnalysisPerformance AnalysisSplit TimeSplit Time

Performance AnalysisPerformance AnalysisSplit TimeSplit Time

0

500

1000

1500

2000

2500

3000

3500

4000

10

00

0

20

00

0

30

00

0

40

00

0

50

00

0

60

00

0

70

00

0

80

00

0

90

00

0

10

00

0

Bucket size

Sp

lit

tim

e (

ms)

0

0.02

0.04

0.06

0.08

0.1

0.12

0.14

0.16

Split time Time per Record

b Time Time/ Record 10000 1372 0.137 20000 1763 0.088 30000 1952 0.065 40000 2294 0.057 50000 2594 0.052 60000 2824 0.047 70000 3165 0.045 80000 3465 0.043 90000 3595 0.040

100000 3666 0.037

Split times versus bucket capacitySplit times versus bucket capacity

Page 105: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

105

DiscusionDiscusionDiscusionDiscusion

About linear scalability in function of About linear scalability in function of bucket sizebucket size

Larger buckets are more efficientLarger buckets are more efficient Splitting is very efficientSplitting is very efficient

– Reaching as little as 40 Reaching as little as 40 s per records per record

Page 106: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

107

Performance AnalysisPerformance AnalysisKey SearchKey Search

Performance AnalysisPerformance AnalysisKey SearchKey Search

0

500010000

15000

20000

2500030000

35000

40000

0 1 2 3 4 5

Number of servers

Tim

e (

ms)

RP*c/ With FC RP*c/ Without FC

RP*n/ With FC RP*n/ Without FC

00.050.1

0.150.2

0.250.3

0.350.4

0 1 2 3 4 5

Number of servers

Tim

e (

ms)

RP*c/ With FC RP*c/ Without FC

RP*n/ With FC RP*n/ Without FC

Total search time Total search time Search time per record Search time per record

A single A single client sends 100.000client sends 100.000 successful random successful random search requestssearch requests

FlowFlow control control : the: the client client sends at mostsends at most 10 10 requests requests without replywithout reply

Page 107: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

108

DiscussionDiscussionDiscussionDiscussion

Single search time Single search time about 30 times faster about 30 times faster than for a disk filethan for a disk file– 350 350 s per searchs per search

Search throughput more than Search throughput more than 65 times 65 times faster than that of a disk filefaster than that of a disk file– 145 145 s per searchs per search

RP*RP*NN appears again surprisingly efficient with appears again surprisingly efficient with respect RP*c for more bucketsrespect RP*c for more buckets

Page 108: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

109

Performance AnalysisPerformance AnalysisPerformance AnalysisPerformance AnalysisRange QueryRange Query

Deterministic termination Deterministic termination

Parallel scan of the entire file with all the 100.000 records Parallel scan of the entire file with all the 100.000 records sent to the clientsent to the client

0

500

1000

1500

2000

2500

3000

3500

4000

0 1 2 3 4 5

Number of servers

Tim

e (

ms)

0

0.005

0.01

0.015

0.02

0.025

0.03

0.035

0.04

0 1 2 3 4 5

Number of servers

Tim

e (

ms)

Range query total time Range query total time Range query time per record Range query time per record

Page 109: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

110

DiscussionDiscussionDiscussionDiscussion

Range search appears also very efficientRange search appears also very efficient– Reaching 10 Reaching 10 s per record delivereds per record delivered

More servers should further improve the More servers should further improve the efficiencyefficiency– Curves do not become flat yetCurves do not become flat yet

Page 110: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

111

Range Query Parallel Execution StrategiesRange Query Parallel Execution StrategiesRange Query Parallel Execution StrategiesRange Query Parallel Execution Strategies

0

1000

2000

3000

4000

5000

6000

1 10 20 30 40 50 60 70 80 90 100 120 140

Nombre de serveurs

Te

mp

s d

e r

ép

on

se

(m

s)

Scénario 1Scénario 2Scénario 3

Study of MM. Tsangou (Master Th.) & Prof. Samba (U. Dakar)

# servers

Res

pons

e T

ime

(ms)

Sc. 3 ; 1 server at the time Sc. 1,2 ; all servers together

Sc. 1 ; single connection request per server

Page 111: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

112

File Size LimitsFile Size LimitsFile Size LimitsFile Size Limits Bucket capacity : 751K records, 196 MBBucket capacity : 751K records, 196 MB Number of inserts : 3MNumber of inserts : 3M Flow control (FC) is necessary to limit the input queue at Flow control (FC) is necessary to limit the input queue at

each servereach server

File creation by a single client - file size : 3,000,000 records

0

200000

400000

600000

800000

1000000

1200000

1400000

1600000

0 500000 1000000 1500000 2000000 2500000 3000000 3500000

Number of records

Tim

e (m

s)

RP*c/ With FC

RP*n/ With FC

Page 112: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

113

File Size LimitsFile Size LimitsFile Size LimitsFile Size Limits

Bucket capacity : 751K records, 196 MBBucket capacity : 751K records, 196 MB Number of inserts : 3MNumber of inserts : 3M GA : Global Average; MA : Moving AverageGA : Global Average; MA : Moving Average

Insert time by a single client - file size : 3,000,000 records

0

0,1

0,2

0,3

0,4

0,5

0,6

0,7

0,8

0 500000 1000000 1500000 2000000 2500000 3000000 3500000

Number of records

Tim

e (m

s) RP*c with FC / GA

RP*c with FC / MA

RP*n with FC / GA

RP*n with FC / MA

Page 113: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

115

AMOS-SDDSAMOS-SDDSAMOS-SDDSAMOS-SDDS Benchmark dataBenchmark data

– Table Pers (SS#, Name, City)Table Pers (SS#, Name, City)– Size 20.000 to 300.000 tuplesSize 20.000 to 300.000 tuples– 50 Cities50 Cities– Random distributionRandom distribution

Benchmark queriesBenchmark queries– Join : SS# and Name of persons in the same cityJoin : SS# and Name of persons in the same city

» Nested loop or Local indexNested loop or Local index

– Count & Join : Count couples in the same cityCount & Join : Count couples in the same city» To determine the result transfer time to the clientTo determine the result transfer time to the client

– Count (*) Pers, Max (SS#) from PersCount (*) Pers, Max (SS#) from Pers MeasuresMeasures

– Scale-up & Speed-upScale-up & Speed-up– Comparison to AMOS-II aloneComparison to AMOS-II alone

Page 114: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

116

Join : best time per tupleJoin : best time per tupleJoin : best time per tupleJoin : best time per tuple

0

20

40

60

80

1 2 3 4 5

Number of servers

Ela

pse

d t

ime(i

n m

s)

E-Strategy I-Strategy without indexI-Strategy with index

20.000 tuples in Pers

14.4

2.4

1.6

AMOS-II alone 13.5 Nested loop 2.25 Index lookup3,990,070 tuples produced

Page 115: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

117

Join & Count: best time per tupleJoin & Count: best time per tupleI-strategyI-strategy

Join & Count: best time per tupleJoin & Count: best time per tupleI-strategyI-strategy

20.000 tuples in Pers AMOS-II alone 13.5 Nested loop 2.25 Index lookup3,990,070 tuples produced

0

2

4

6

8

1 2 3 4 5

Number of servers

Ela

pse

d t

ime(i

n m

s)

Query2 without indexQuery2 with index

1.8

1.0

Page 116: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

118

Join : Speed-upJoin : Speed-upI-strategyI-strategy

Join : Speed-upJoin : Speed-upI-strategyI-strategy

20.000 tuples in Pers AMOS-II alone 13.5 Nested loop 2.25 Index lookup3,990,070 tuples produced

020406080

100120140

1 2 3 4 5 10 15

Number of servers

Ela

pse

d t

ime (

in s

)

00.0010.0020.0030.0040.0050.0060.007

Tim

e p

er

tup

le (

in s

)

Without index

Extrapolationwithout index

With index

Extrapolationwith index

Page 117: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

119

Count : Speed-upCount : Speed-upCount : Speed-upCount : Speed-up

100.000 tuples in Pers

0

500

1000

1500

2000

1 2 3 4 5

Number of servers

Ela

pse

d t

ime(i

n m

s)

024681012

Count withimportation (lefttimescale)

External count (righttimescale)

E-strategy wins

AMOS-II alone: 280 ms

341

Page 118: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

120

Join Scale-up PerformanceJoin Scale-up PerformanceJoin Scale-up PerformanceJoin Scale-up Performance

The file scales to 300.000 tuplesThe file scales to 300.000 tuples Spreading from 1 to 15 AMOS-SDDS Servers Spreading from 1 to 15 AMOS-SDDS Servers

– Transparently for the application !Transparently for the application ! 3 servers per machine3 servers per machine

– The poor men configuration has only 5 server The poor men configuration has only 5 server machinesmachines

Results are extrapolated to 1 server per Results are extrapolated to 1 server per machinemachine– Basically, the CPU component of the elapsed time Basically, the CPU component of the elapsed time

time is divided by 3time is divided by 3

Page 119: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

121

Join : Elapsed Time Scale-upJoin : Elapsed Time Scale-upJoin : Elapsed Time Scale-upJoin : Elapsed Time Scale-up

0

2000

4000

6000

8000

10000

12000

20 000 60 000 100 000 160 000 200 000 240 000 300 000

1 3 5 8 10 12 15

File size: # tuples#AMOS-SDDS servers

Ela

pse

d t

ime

(s)

AMOS-IIAMOS-SDDS joinAMOS-SDDS join w. count

AMOS-SDDS: I-Strategy with Index Lookup Join

Page 120: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

122

File size 20 000 60 000 100 000 160 000 200 000 240 000 300 000

# SDDS servers 1 3 5 8 10 12 15

Result size 3 990 070 35 970 600 99 951 670 255 924 270 399 906 670 575 889 600 899 865 000

Actual Join Time (s) 61 301 684 1817 2555 3901 5564

Join & Count (s) 51 185 335 986 1270 2022 2624

Join w. extrp. (s) 61 301 684 1324 1920 2553 3815

Join & Count.w. extrp. (s)51 185 335 498 640 681 881

AMOS-II (s) 46 430 1201 3106 4824 6979 10 933

Index creation

time (s)

3 29 87 230 360 520 819

Join : Elapsed Time Scale-upJoin : Elapsed Time Scale-upJoin : Elapsed Time Scale-upJoin : Elapsed Time Scale-up

Page 121: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

123

Join : Time per Tuple Scale-upJoin : Time per Tuple Scale-upJoin : Time per Tuple Scale-upJoin : Time per Tuple Scale-up

05

10152025303540

20 000 60 000 100 000 160 000 200 000 240 000 300 000

1 3 5 8 10 12 15

File size: # tuples#AMOS-SDDS servers

Tim

e p

er t

up

le (

ms)

AMOS-IIAMOS-SDDS joinAMOS-SDDS join w. count

Join w. Count flat !Better scalability than any Better scalability than any current P-DBMS could providecurrent P-DBMS could provide

Page 122: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

124

SD-AMOS : File CreationSD-AMOS : File CreationSD-AMOS : File CreationSD-AMOS : File Creation

0.00

0.05

0.10

0.15

0.20

1 2 2 3 4 4 4 5

2000 4000 6000 8000 10000 12000 14000 15800

# serveurs#enreg.

Tem

ps

moye

n(m

s)

MG

MC

Flat & unexpectedly fast insert time

Global Avg.

Moving Avg.

Inse

rt T

ime

(ms)

# servers

# inserts

b = 4.000

Page 123: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

125

SD-AMOS : Large File CreationSD-AMOS : Large File CreationSD-AMOS : Large File CreationSD-AMOS : Large File Creation

Flat & fast insert time remains

0.00

0.05

0.10

0.15

0.20

1 2 2 3 4 4 4 5

20000 40000 60000 80000 100000 120000 140000 159000# serveurs# enreg.

Tem

ps

moye

n(m

s)

MG

MC

Inse

rt T

ime

(ms)

Global Avg.

Moving Avg.# servers

# inserts

b = 40.000

Page 124: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

126

SD-AMOS : Large File SearchSD-AMOS : Large File Search(time per record)(time per record)

SD-AMOS : Large File SearchSD-AMOS : Large File Search(time per record)(time per record)

File of 300K Records

0.00

0.05

0.10

0.15

0.20

1 2 3 4 5

#serveurs

Tim

e (

ms)

Range query

Bulk search

Individual search

Client max process. speed is reached

Page 125: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

127

SD-AMOS : Very Large File CreationSD-AMOS : Very Large File CreationSD-AMOS : Very Large File CreationSD-AMOS : Very Large File Creation

0.000.200.400.600.801.001.20

1 1 1 1 1 1 1 2 2 2 2 2 2 3 3 4 4 4 4 4 4 4 4 4 4 4 4 4 4 5

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30

# servers# tuples x 100K

Tim

es (

ms)

G.A.TM.A.T

Bucket size 750 K recordsMax file size 3M recordsRecord size : 100 B

Page 126: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

128

ConclusionConclusionConclusionConclusion

SDDS-2000SDDS-2000 : : a prototype a prototype SDDS SDDS manager manager for Windowsfor Windows mmulticomputer ulticomputer

Several variants of LH* and RP*Several variants of LH* and RP*

High-availabilityHigh-availability

Scalable distributed database query Scalable distributed database query processingprocessing

AMOS-SDDS & SD-AMOSAMOS-SDDS & SD-AMOS

Page 127: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

129

ConclusionConclusionConclusionConclusionExperimental performance of Experimental performance of SDDS SDDS

schemes appears in line with the schemes appears in line with the

expectationsexpectations Record search & insert timesRecord search & insert times in the in the range of a fraction of a millisecondrange of a fraction of a millisecond

About 30 to 100 times faster than a About 30 to 100 times faster than a disk file access performancedisk file access performance

About ideal (linear) scalabilityAbout ideal (linear) scalability

Including the query processingIncluding the query processing

Results prove the overall efficiency of Results prove the overall efficiency of SDDS-2000 systemSDDS-2000 system

Page 128: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

130

Current & Future WorkCurrent & Future WorkCurrent & Future WorkCurrent & Future Work SDDS-2000 ImplementationSDDS-2000 Implementation High-Availability through RS-CodesHigh-Availability through RS-Codes

– CERIA & U. Santa Clara (Prof. Th. Schwarz)CERIA & U. Santa Clara (Prof. Th. Schwarz) Disk-based High-Availability SDDSsDisk-based High-Availability SDDSs

– CERIA & IBM-Almaden (J. Menon)CERIA & IBM-Almaden (J. Menon) Parallel QueriesParallel Queries

– U. Dakar (Prof. S. Ndiaye) & CERIAU. Dakar (Prof. S. Ndiaye) & CERIA Concurrency & TransactionsConcurrency & Transactions

– U. Dakar (Prof. T. Seck)U. Dakar (Prof. T. Seck) Overall Performance AnalysisOverall Performance Analysis SD-AMOS & SD-DBMS in generalSD-AMOS & SD-DBMS in general

– CERIA & U. Uppsala (Prof. T. Risch) & U. DakarCERIA & U. Uppsala (Prof. T. Risch) & U. Dakar SD-SQL-Server ?SD-SQL-Server ? Extent dependent basically on available fundingExtent dependent basically on available funding

Page 129: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

131

CreditsCreditsCreditsCredits

SDDS-2000 ImplementationSDDS-2000 Implementation– CERIA Ph. D Students CERIA Ph. D Students

» F. Bennour (Now Post-Doc) (SDDS-2000 ; LH*)F. Bennour (Now Post-Doc) (SDDS-2000 ; LH*)

» A. Wan Diene, Y. Ndiaye (SDDS-2000 RP* & AMOS-SDDS & A. Wan Diene, Y. Ndiaye (SDDS-2000 RP* & AMOS-SDDS & SD-AMOS)SD-AMOS)

» R. Moussa (RS-Parity Subsystem)R. Moussa (RS-Parity Subsystem)

– Master Student ThesisMaster Student Thesis» At CERIA and coop. Universities At CERIA and coop. Universities

– See Ceria Web page ceria.dauphine.frSee Ceria Web page ceria.dauphine.fr

Partial Support for SDDS-2000 researchPartial Support for SDDS-2000 research– HPL, IBM Research, HPL, IBM Research, Microsoft Research Microsoft Research

Page 130: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

132

Problems & ExercicesProblems & ExercicesProblems & ExercicesProblems & Exercices Install SDDS-2000 and experiment with the interactive appl. Comment the experience Install SDDS-2000 and experiment with the interactive appl. Comment the experience

on a few pages.on a few pages. Create your favorite appl. Using the .h interfaces provided with the package.Create your favorite appl. Using the .h interfaces provided with the package. Comment on on a few pages on LH*rs goal and way to work, on the basis of the Comment on on a few pages on LH*rs goal and way to work, on the basis of the

Sigmod paper and the WDAS-2002 paper by Rim Moussa.Sigmod paper and the WDAS-2002 paper by Rim Moussa. Comment on a few pages on the strategies for a scalable distributed hash joins Comment on a few pages on the strategies for a scalable distributed hash joins

according to D. Schneider & al paper. Your own ?according to D. Schneider & al paper. Your own ? Can you propose how to deal with Theta-joins ?Can you propose how to deal with Theta-joins ? You should split a table under one SQL Server into two tables on two SQL Servers. You You should split a table under one SQL Server into two tables on two SQL Servers. You

wish to generate RP* like range partitioning on the key attribute(s). You wish to use as wish to generate RP* like range partitioning on the key attribute(s). You wish to use as much as possible standard SQL queriesmuch as possible standard SQL queries

– How can you find the record with median (middle) key ?How can you find the record with median (middle) key ?– What are the catalog tables where you can find the table size, the associated check constraints, What are the catalog tables where you can find the table size, the associated check constraints,

indexes, triggers, stored procedures… to move to the new nodeindexes, triggers, stored procedures… to move to the new node– How will you move the records that should leave to the new node.How will you move the records that should leave to the new node.

Idem for a stored funciton under Amos Idem for a stored funciton under Amos Idem for OracleIdem for Oracle Idem for DB2 Idem for DB2

Page 131: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

133

ENDENDENDEND

Thank you for your attentionThank you for your attention

Witold [email protected]@cs.berkeley.edu

Page 132: 1 SDDS-2000 : A Prototype System for Scalable Distributed Data Structures on Windows 2000 SDDS-2000 : A Prototype System for Scalable Distributed Data

134