21,397 views
49 49 votes

The data blocks of a very large file in the Unix file system are allocated using

  1. continuous allocation
  2. linked allocation
  3. indexed allocation
  4. an extension of indexed allocation

5 Answers

Best answer
61 61 votes

The data blocks of a very large file in the unix file system are allocated using an extension of indexed allocation or $\textsf{EXT2}$ file system. Hence, option (D) is the right answer.

• edited by
30 30 votes
ans D

The Unix file system uses an extension of indexed allocation. It uses direct blocks, single indirect blocks, double indirect blocks and triple indirect blocks
1 1 vote

The correct answer is:

D. an extension of indexed allocation

The Unix File System (UFS) uses a variant of indexed allocation for managing data blocks. Specifically, it starts with:

  • Indexed allocation via the inode structure (which acts like an index block).
  • For large files, this is extended using:
    • Single indirect
    • Double indirect
    • Triple indirect block pointers

This approach extends the capacity of indexed allocation, allowing the system to manage very large files efficiently without needing contiguous or purely linked allocation methods.

Why not the others?

  • A. Continuous allocation: Not used in Unix due to fragmentation and difficulty in growing files.
  • B. Linked allocation: Not used because it is inefficient for random access.
  • C. Indexed allocation: Only partially true; Unix goes beyond simple indexed allocation with multiple levels of indirection.

So, D is the most accurate.

0 0 votes

1️⃣ Why not continuous allocation?

  • Requires contiguous disk blocks

  • Causes external fragmentation

  • Not practical for very large or growing files

❌ Hence, not used.


2️⃣ Why not linked allocation?

  • Each block points to the next block

  • Problems:

    • No direct access (must traverse block by block)

    • Pointer overhead

    • Poor performance for large files

❌ Inefficient for very large files.


3️⃣ Why indexed allocation alone is not enough?

  • Indexed allocation uses one index block to store addresses

  • Index block size is limited

  • For very large files, a single index block cannot store all block addresses

❌ Plain indexed allocation has a size limit.


4️⃣ ✅ Why extension of indexed allocation is correct

Unix uses an extended indexed allocation scheme via inodes, which include:

  • Direct pointers

  • Single indirect pointer

  • Double indirect pointer

  • Triple indirect pointer

This allows:

  • Efficient access for small files

  • Massive scalability for very large files

✔ Supports extremely large file sizes
✔ Combines performance + scalability

0 0 votes

The Unix File System (UFS) uses an inode structure to manage file allocations efficiently across varying file sizes.

For small files, the inode contains direct pointers that reference data blocks directly on the disk to optimize access speeds.

To handle very large files that exceed the storage capacity of these basic direct pointers, Unix implements a multi-level scheme consisting of single, double, and triple indirect pointers.

This multi-level indirect scheme functions as an extension of the basic indexed allocation method, dynamically increasing the number of addressable data blocks as the file grows.

Answer:
Position:
Show:

Related questions

74 74 votes
4 answers 4 answers
36.3k
36.3k views
Kathleen asked Sep 12, 2014
36,264 views
Which of the following are NOT true in a pipelined processor?Bypassing can handle all RAW hazardsRegister renaming can eliminate all register carried WAR hazardsControl h...
480 480 votes
20 answers 20 answers
122k
122k views
Kathleen asked Sep 12, 2014
122,146 views
A processor uses $36$ bit physical address and $32$ bit virtual addresses, with a page frame size of $4$ Kbytes. Each page table entry is of size $4$ bytes. A three level...
44 44 votes
5 answers 5 answers
23.9k
23.9k views
Kathleen asked Sep 12, 2014
23,871 views
A process executes the following codefor(i=0; i<n; i++) fork();The total number of child processes created is$n$$2^n-1$$2^n$$2^{n+1} - 1$
102 102 votes
10 answers 10 answers
37.3k
37.3k views
Kathleen asked Sep 12, 2014
37,293 views
The $P$ and $V$ operations on counting semaphores, where s is a counting semaphore, are defined as follows:$P(s):$$s=s-1;$If $s < 0$ then wait;$V(s):$$s=s+1;$If $s \leq0$...