CS FundamentalsHardGATE CS
An 8 MB file uses linked indexed allocation: each 4 KB index block holds 1024 four-byte pointers, of which the last is reserved as the link to the next index block. Data blocks are 4 KB. How many index blocks are needed?
- A. 2
- B. 3
- C. 1
- D. 4
Correct answer: B. 3
The file has 8 MB / 4 KB = 2048 data blocks. Each index block lists only 1023 data pointers (one slot is the link), so 2048 / 1023 rounds up to 3 index blocks. Forgetting the link slot gives 2.
More Operating Systems questions
- Processes (arrival, burst) are P1 (0, 8), P2 (1, 4), P3 (2, 9), P4 (3, 5) and P5 (6, 2). What is the average waiting time under preemptive…
- Round Robin with quantum 2 runs A (arrival 0, burst 5), B (1, 3), C (2, 6) and D (4, 2). A newly arrived process joins the ready queue…
- At time 10 the CPU becomes free and four jobs wait: J1 (arrived 2, burst 6), J2 (arrived 5, burst 2), J3 (arrived 1, burst 10), J4…
- With 3 frames, initially empty, the reference string 4, 7, 0, 7, 1, 0, 1, 2, 1, 2, 7, 1, 2, 0, 4, 7 is run under FIFO, LRU and Optimal…
- A clock (second-chance) algorithm has frames f0–f4 holding P3 (R = 1), P8 (R = 0), P5 (R = 1), P1 (R = 1) and P6 (R = 0). The hand points…
- A system has a TLB lookup of 20 ns, memory access of 100 ns, single-level paging and a TLB hit ratio of 90%, so a reference costs 130 ns…