Suppose a Linux file system has a block size of 2K bytes, a disk address is 32 bits, and an i-node contains the disk addresses of the first 12 direct blocks of a file, one single-indirect block, and one double-indirect block. Approximately, what is the largest file that can be represented by an i-node?
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: B. 513 Mbytes
Explanation
A disk address (pointer) is 32 bits = 4 bytes, so each 2 KB (2048-byte) block holds 2048/4 = 512 pointers. The 12 direct blocks contribute 12 × 2048 ≈ 24 KB. The single-indirect block contributes 512 × 2048 = 1,048,576 bytes = 1 MB. The double-indirect block contributes 512 × 512 × 2048 = 536,870,912 bytes = 512 MB. Summing 24 KB + 1 MB + 512 MB ≈ 513 MB, matching option (ii).More Database Management Systems questions
- Consider a disk system having 60 cylinders. Disk requests are received by the disk drive for cylinders 10, 22, 20, 2, 40, 6, and 38, in tha…
- A disk queue has requests for I/O on cylinders 98, 183, 37, 122, 14, 124, 65, 67, with the disk head currently at cylinder 53. Using the sh…
- Consider the following statements about UNIX file permissions: (A) UNIX provides three permission types — Read, Write and Execute. (B) UNIX…
- In the ________ disk scheduling algorithm, the disk head moves from one end of the disk to the other, servicing requests along the way. Whe…
- Suppose there are six files F1, F2, F3, F4, F5, F6 with corresponding sizes 150 KB, 225 KB, 75 KB, 60 KB, 275 KB and 65 KB respectively. Th…
- Match the following for the UNIX file system: List I: (A) Boot block (B) Super block (C) Inode block (D) Data block List II: (I) Contains i…