Chapter 3 Data Storage and Access Methods Title: Operating System Support for Database Management...
-
Upload
corey-davidson -
Category
Documents
-
view
215 -
download
0
Transcript of Chapter 3 Data Storage and Access Methods Title: Operating System Support for Database Management...
Chapter 3Chapter 3Data Storage and Access Data Storage and Access
MethodsMethods
Title: Operating System Support for Database Title: Operating System Support for Database ManagementManagementAuthor: Michael StonebrakerAuthor: Michael StonebrakerPages: 217—223 Pages: 217—223
Problem DefinitionProblem Definition Apparent disconnect between DBMS performance Apparent disconnect between DBMS performance
goals and operating system design and goals and operating system design and implementation.implementation.
Services provided by OS are inadequate and sub-Services provided by OS are inadequate and sub-optimal.optimal.
Paper evaluates the following services:Paper evaluates the following services:• Buffer pool managementBuffer pool management• File systemFile system• Interprocess communicationInterprocess communication• Consistency controlConsistency control• Paged virtual memoryPaged virtual memory
ContributionsContributions
Demonstrates OS services are too Demonstrates OS services are too slow or inappropriate for DBMS tasks.slow or inappropriate for DBMS tasks.
Attempts to make OS designers Attempts to make OS designers aware of and more sensitive to DBMS aware of and more sensitive to DBMS needs.needs.
Key ConceptsKey Concepts
Buffer Pool ManagementBuffer Pool Management• OS has a fixed buffer pool that handles all I/OOS has a fixed buffer pool that handles all I/O• UNIX uses LRU replacement strategy, which UNIX uses LRU replacement strategy, which
may not be ideal for a DBMSmay not be ideal for a DBMS• Large performance overhead to pull a block Large performance overhead to pull a block
into the buffer. Approx. 5000 instructions for into the buffer. Approx. 5000 instructions for 512 bytes512 bytes
• No good prefetch strategy.No good prefetch strategy.• UNIX does not implement a selected force out UNIX does not implement a selected force out
buffer manager where the DBMS can dictate buffer manager where the DBMS can dictate the order of the commitsthe order of the commits
Key ConceptsKey Concepts
The File SystemThe File System• UNIX implements its file system as character UNIX implements its file system as character
arrays and forces the DBMS to implement its arrays and forces the DBMS to implement its own higher level objects.own higher level objects.
• Tree Structured File SystemsTree Structured File Systems UNIX implements 2 service using treesUNIX implements 2 service using trees
• Keeping track of blocks in a given fileKeeping track of blocks in a given file• Hierarchical directory structureHierarchical directory structure
DBMS adds a third tree to support keyed accessDBMS adds a third tree to support keyed access One tree with all 3 kinds of information is more One tree with all 3 kinds of information is more
efficient.efficient.
Key ConceptsKey Concepts Scheduling Process Management and Scheduling Process Management and
Interprocess CommunicationInterprocess Communication• PerformancePerformance
Task switches are inevitableTask switches are inevitable Processes have a great deal of state information Processes have a great deal of state information
making task switches expensivemaking task switches expensive• Critical SectionsCritical Sections
Buffer pool is a shared data segment.Buffer pool is a shared data segment. Problems arise if OS deschedules a DB process Problems arise if OS deschedules a DB process
holding a lock on the buffer pool.holding a lock on the buffer pool.• Server modelServer model
OS needs to provide a message facility for multiple OS needs to provide a message facility for multiple processes to message a single process.processes to message a single process.
Server must do its own scheduling and multitasking.Server must do its own scheduling and multitasking.
Key ConceptsKey Concepts Consistency ControlConsistency Control
• Many Operating Systems can only place locks Many Operating Systems can only place locks at the file level.at the file level.
• DBMS prefer finer granularity.DBMS prefer finer granularity.• When DBMS implement its own buffer pool, When DBMS implement its own buffer pool,
crash recovery by the operating system would crash recovery by the operating system would be impossible.be impossible.
Paged Virtual MemoryPaged Virtual Memory• Large files may not be able to be stored in Large files may not be able to be stored in
memorymemory• Binding chunks of the file into user space may Binding chunks of the file into user space may
incur a performance loss.incur a performance loss.
ValidationValidation Content is mostly informational.Content is mostly informational.
Based off previous papers and existing Based off previous papers and existing implementations of current systems.implementations of current systems.
Examples are cited primarily from the Examples are cited primarily from the UNIX OS and the Ingres DBMS.UNIX OS and the Ingres DBMS.
Issues could be biased and may not be Issues could be biased and may not be common or applicable to all OS and DBMS common or applicable to all OS and DBMS combinations.combinations.
AssumptionsAssumptions
Presents the topic as one that is applicable Presents the topic as one that is applicable to across a number of DBMS and OSto across a number of DBMS and OS
Author constrains his examples to UNIX Author constrains his examples to UNIX and Ingres.and Ingres.
Paper was written in 1981. Operating Paper was written in 1981. Operating Systems have advanced considerably Systems have advanced considerably since then. His points may no longer be since then. His points may no longer be applicable.applicable.
Changes if Rewritten TodayChanges if Rewritten Today
Increase the diversity of operating Increase the diversity of operating systems and DBMSsystems and DBMS
Add industry perspective. Are the Add industry perspective. Are the problems Stonebraker presents really a problems Stonebraker presents really a problem for DBMS designers?problem for DBMS designers?
Quantify claims by providing statistical Quantify claims by providing statistical analysis of performance hits.analysis of performance hits.