Docsity

Need for Speed, Parallelism - Data Warehousing - Lecture Slides, Slides of Data Warehousing

Partial preview of the text

Download Need for Speed, Parallelism - Data Warehousing - Lecture Slides and more Slides Data Warehousing in PDF only on Docsity!

1

Data Warehousing

Lecture-

Need for Speed: Parallelism

2

Background

4

Are you ready to parallelize?

Parallelism can be exploited, if there is…

Symmetric multi-processors (SMP), clusters, or Massively Parallel (MPP) systems AND

Sufficient I/O bandwidth AND

Underutilized or intermittently used CPUs (for example, systems where CPU usage is typically less than 30%) AND

Sufficient memory to support additional memory-intensive processes such as sorts, hashing, and I/O buffers

Word of caution

Parallelism can reduce system performance on over-utilized systems or systems with small I/O bandwidth.

5

Scalability – Size is NOT everything

Number of Concurrent Users

  • Simple table retrieval
  • Moderate complexity Join
  • Propensity analysis
  • Clustering

Complexity of Technique

  • Hash based
  • B-Tree
  • Multiple
  • Bitmapped

Index usage

Amount of detailed data

Complexity of Data Model

7

Quantifying Speed-up

Sequential Execution Ideal Parallel Execution

18 time units (^) 6 time units

Task-1 Task-2 Task-

Control work (“overhead”)

Speedup = 18 = 300% 6

Ts: Time on serial processor

Tm: Time on multiple processors

Speedup =

Ts Tm

Task-1 Task-2^ Task-

8

Speed-Up & Amdahl’s Law

Reveals maximum expected speedup from parallel

algorithms given the proportion of task that must be

computed sequentially. It gives the speedup S as

f is the fraction of the problem that must be computed sequentially N is the number of processors

As f approaches 0, S approaches N

Example-1: f = 5% and N = 100 then S = 16. Example-2: f = 10% and N = 200 then S = 9.

Not 1: Ratio

Only formula and explanation will go to graphics

10

Parallelization OLTP Vs. DSS

There is a big difference.

DSS Parallelization of a SINGLE query

OLTP Parallelization of MULTIPLE queries Or Batch updates in parallel

11

Brief Intro to Parallel Processing

Parallel Hardware ArchitecturesSymmetric Multi Processing (SMP)Distributed Memory or Massively Parallel Processing (MPP)Non-uniform Memory Access (NUMA)

Parallel Software ArchitecturesShared MemoryShard DiskShared Nothing

Types of parallelismData ParallelismSpatial Parallelism

Shared Everything

13

Composed of a number of self-contained, self-controlled nodes connected through a network interface.

Each node contains its own CPU, processor, memory and I/O.

Architecture better known as Massively Parallel Processing (MPP) or cluster computing.

Memory is distributed across all nodes.

Distributed Memory Machines

Bus, Switch or Network

I/O P Memory

I/O P Memory

I/O P Memory

 Network has the tendency to become the bottleneck.

 Issues fundamentally different from those in SMP. Yellow will not go to graphics

Node

14

A little bit of both worlds!

Distributed Shared Memory Machines

Interconnection

Network

Main Memory

I/O I/O I/O P1 P2 P3 P

Main Memory

I/O I/O I/O P1 P2 P3 P

Main Memory

I/O I/O I/O P1 P2 P3 P

Main Memory

I/O I/O I/O P1 P2 P3 P

16

Shared Nothing RDBMS Architecture

Clients/Users

Adv Data ownership changes infrequently

There is no locking

Dis Adv Data availability low on failure

Very careful with data distribution

Redistribution is expensive

Yellow ill not go to graphics

17

Shared disk Vs. Shared Nothing RDBMS

 Important note: Do not confuse RDBMS

architecture with hardware architecture.

 Shared nothing databases can run on shared

everything (SMP or NUMA) hardware.

 Shared disk databases can run on shared

nothing (MPP) hardware.

This slide will not go to graphics