Question

11. Consider a file system that uses a structure similar to an i-node with the following differences. If the file size is less than 100 bytes, the data is stored directly in the i-node. If it is larger, there are 6 direct links (point to a data block), 1 single-indirect links, 2-double indirect links and 1 triple indirect link. (a) What is the largest file size that can be indexed in this system? Assume the block size is 512 bytes. (3 points) (b) How many blocks (including index blocks) are needed to address a file of size 50 bytes, 500 bytes, 50Kbytes, and 5Mbytes? (4 points)

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Solution:

If the disk address is 16 bits and the block size is given as 512 byte

Number of entries = 512/16 bits = 512/2 byte = 256 entries

direct links = 6=> 6*512 = 3 KB

single indirect link = 256 * 512 = 128 KB

double indirect link = 256 * 256 * 512 = 32*2 = 64 MB

triple indirect link = 256 *256 *256 * 512 = 8 GB

Maximum file size = 8 GB

b)

If the block size is 50 bytes

It requires only 1 direct block

If the block size is 500 bytes

It requires only 1 direct block, since the block size is 512 bytes

If the block size is 500 Kbytes

It requires only 6 direct block, and 92 sigle indirect

If the block size is 5 Mbytes

It requires only 5 * 2^20/512=> 10240

6 direct, rest are single indirect addressing.

I hope this helps if you find any problem. Please comment below. Don't forget to give a thumbs up if you liked it. :)

Add a comment
Know the answer?
Add Answer to:
11. Consider a file system that uses a structure similar to an i-node with the following...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT