+ All Categories
Home > Documents > Planning Warehouse Storage

Planning Warehouse Storage

Date post: 31-Dec-2015
Category:
Upload: jorden-guzman
View: 20 times
Download: 1 times
Share this document with a friend
Description:
Planning Warehouse Storage. Chapter 9. Data Partitioning. Ease of: - Restructuring - Reorganization - Removal - Recovery - Monitoring - Management - Archiving - Indexing. Breaking up a data into separate physical units that can be handled - PowerPoint PPT Presentation
Popular Tags:
21
Planning Warehouse Storage Chapter 9
Transcript
Page 1: Planning Warehouse Storage

Planning Warehouse Storage

Chapter 9

Page 2: Planning Warehouse Storage

Data Partitioning

Breaking up a data into separate physical units that can be handled independently

Ease of: - Restructuring - Reorganization - Removal - Recovery - Monitoring - Management - Archiving - Indexing

Order table Order table

Drop

Other data is not affected

Add

Page 3: Planning Warehouse Storage

Objects to Partition

Tables: - Fact - DimensionIndexes

Page 4: Planning Warehouse Storage

Horizontal Partitioning

Table and index data are split by: - Time - Sales region or person - Geography - Organization - Line of businessCandidate columns appear in WHERE clauseAnalysis determines requirement

Page 5: Planning Warehouse Storage

Vertical Partitioning

You may use vertical partitioning when:Speed of query and update actions is

improved by itUsers require access to specific columnsSome data is changed infrequentlyDescriptive dimension text may be

better moved away from the dimension itself

Page 6: Planning Warehouse Storage

Partitioning Methods

Range partitioning (Oracle8 and Oracle8i)Hash partitioning (Oracle8i)Composite partitioning (Oracle8i)

Page 7: Planning Warehouse Storage

Star Query Optimization

Optimum performance with star schema models

1. Dimensions are queried to create a 2. Cartesian product, computed against3. Smaller reference table.4. The result is joined to5. A fact table to produce a query result.

Page 8: Planning Warehouse Storage

Star Transformation

Key 1 Key2 Key 3 Dollars1001 1002 1003 60002001 2002 2003 100003001 3002 3003 152004001 4002 4003 9526

Key 2 Stat1002 SF

Key 3 Year Month1003 1998 March

Key 1 Brand1001 ABC

Time_Table

Fact_Table

Product_Table

Market_Table

Page 9: Planning Warehouse Storage

Indexing

Indexing is used because:It is huge cost saving, greatly

improving performance and scalabilityCan replace a full table scan by a

quick read of the index followed by a read of only those disk blocks that contain the rows needed

Page 10: Planning Warehouse Storage

B-Tree Index

Most common type of indexingUsed for high cardinality columnsDesigned for few rows returned

Page 11: Planning Warehouse Storage

Bitmap Indexes

Provide performance benefits and storage savings

Store values as 1s and 0sUse instead of B-tree indexes when: - Tables are large - Columns have relatively low

cardinality

Page 12: Planning Warehouse Storage

Oracle8 and Oracle8i Index Enhancements

Oracle8 index enhancements: - Partitioned index

- Index-organized tablesOracle8i index enhancements: - Function-based index - New bitmap index improvements - Online index build and rebuild - Descending index - Statistics can be collected when an index is created

Page 13: Planning Warehouse Storage

Protecting the Database

RAID is essential with large databasesRAID improves: - Reliability - Storage managementThere are different levels of RAIDYou can eliminate disk contention with

disk striping

Page 14: Planning Warehouse Storage

RAID 0: Striping

The file is written to a four-drive disk array:Block 1 on Drive 1Block 2 on Drive 2…Block 5 in another sector on Drive 1

File A (a)File A (e)

File A (b)File A (f)

File A (c ) File A (d)

Disk array controller

Page 15: Planning Warehouse Storage

RAID 0: Striping

Benefits: - Good for simultaneous reads and writes

- No redundancy - ScalableLimitations: - Not recommended for mission-critical systems - No recovery from data loss - One bad sector affects entire disk of data

Page 16: Planning Warehouse Storage

RAID 1: Mirrored Disk

File A (a)File A (b)

File A (a)File A (b)

File B (c )File B (d)File B (e)

File B (c )File B (d)File B (e)

Disk array controller

Disk 1Disk 1Mirror

Disk 2Disk 2Mirror

Copy of files stored on mirror disk

Page 17: Planning Warehouse Storage

RAID 1: Mirrored Disk

Benefits: - Complete data redundancy - No performance penalty - Improves reads - ScalabilityLimitations: - Highest cost of all RAID configurations

Page 18: Planning Warehouse Storage

RAID 5: Independent Disk Array

File C (a)File C (d)File (h)P (i, j)

File C (b)File C (e)P(d,e,f,g,h)

File C (c )File C (f)File C (i)

P (a, b,c)File C (g)File C (j)

Disk array controller

Disk 1 Disk 2 Disk 3 Disk 4

Data striped with parity across array

Page 19: Planning Warehouse Storage

RAID 5: Independent Disk Array

Benefits: - Efficient data integrity - Data reconstruction - Multiple concurrent seeks across array - ScalableLimitations: - Disk overhead - Data write rate

Page 20: Planning Warehouse Storage

BackupPlan at the design stageUse hot backups for VLDBsBack up necessary components:

- Fact and dimension data - Warehouse schema - Metadata schema - MetadataExport/Import utility - Disk space - Time

Page 21: Planning Warehouse Storage

Summary

This lesson discussed the following topics:Explaining vertical partitioning and

horizontal partitioningDistinguishing the different types of

partitioning methodsDistinguishing between B-tree index and

bitmap indexUnderstanding why warehouse typically

uses RAID 0, or 5 to protect the database


Recommended