Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 2. (20 points)Consider a database buffer manager that uses 1GB of main memory and keeps data on a hard drive which reads 100MB per

Problem 2. (20 points)Consider a database buffer manager that uses 1GB of main memory and keeps data on a hard drive which reads 100MB per second and takes 10 milliseconds per disk seek.

(a) (10 points) Assume that (1) the size of each disk block is 10KB and (2) for each block kept in the buffer, the probability that the buffer manager can handle the next data request using that block (i.e., the probability that the block contains the requested data) is 5*10^6 . In this case, calculate the expected data access time (i.e., how much time the buffer manager on average would spend to provide a requested disk block). For this calculation, assume that (1) the buffer manager runs the algorithm explained in Section 13.5.1 of the textbook, (2) the buffer is already full (i.e., the entirety of the 1GB buffer space is already used to hold 105 disk blocks), and (3) no disk blocks are updated (i.e., no need to write dirty blocks back to the hard drive). Also, ignore the time spent for reading/writing data in the main memory.

(b) (10 points) Assume that (1) the size of each disk block is 100KB and (2) for each block kept in the buffer, the probability that the buffer manager can handle the next data request using that block (i.e., the probability that the block contains the requested data) is 10^5 . Calculate the expected data access time as in (a). Also, based on the above calculations, explain whether it is more advantageous to use 10KB disk blocks or 100KB disk blocks.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL/PHP Database Applications

Authors: Brad Bulger, Jay Greenspan, David Wall

2nd Edition

ISBN: 0764549634, 9780764549632

More Books

Students also viewed these Databases questions

Question

1300

Answered: 1 week ago

Question

5-8 What are the advantages and disadvantages of the BYOD movement?

Answered: 1 week ago