Question
Consider a disk with block size = 4096 bytes. A block pointer is 6 bytes and a record pointer is 8 bytes long. A file
Consider a disk with block size = 4096 bytes. A block pointer is 6 bytes and a record pointer is 8 bytes long. A file has 10,000 records of fixed length. Each record has the following fields and byte size: Name (30), ID (9), Dept (9), Address (40), Phone (10), Bdate (8), Sex (1), Job (4) and Salary (4). An additional byte is used as a deletion marked.
a. Calculate the record size R in bytes
b. Calculate the blocking factor and the number of file blocks needed to store the data, assuming an unspanned organization.
Assume the file is ordered by the unique field ID. You want to use the static hash function h(k) = k mod 10, with collisions going to overflow buckets, not the adjacent bucket. Each bucket holds up to 10 values.
c. Assume the worst case where all the data is hashed to the same bucket. How many overflow buckets are needed?
d. Assume the best case where all the data is evenly hashed among all buckets. How many overflow buckets are needed?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started