File system-I/O-protection

Question 1

The index node (inode) of a Unix-like file system has 12 direct, one single-indirect and one double-indirect pointers. The disk block size is 4 kB, and the disk block address is 32-bits long. The maximum possible file size is (rounded off to 1 decimal place) ______ GB.

A
7.0
B
9.0
C
2.0
D
4.0
Question 1 Explanation: 
No. of Disk block pointers = 4kB/32bits = 1k
Max. file size
= (12 × 1k + 1k × 1k) × 4kB
≈ (1024 × 12 + 1024 × 1024) × 4 × 1024 bytes
≈ 4GB
Question 2
Which of the file directory structures support effective sharing of files?
A
Two-level directories
B
Three-structured directories
C
acyclic graph directories
D
single –level directories
Question 3
Consider a file currently consisting of 50 blocks. Assume that the file control block and the index block is already in memory. If a block is added at the end (and the block information to be added is stored in memory), then how many disk I/O operations are required for indexed (single-level) allocation strategy?
A
1
B
101
C
27
D
0
Question 3 Explanation: 
Given data,
-- Up time=75%
-- Down time=25%
-- How many times does this file server have to be replicated to give an Availability of at least 99% is=?
Option-A: Here 2 replications, it means down time is 25% equivalent 0.25.
According to 2 replications we have to multiply with 0.25*0.25=0.0625
Availability= 100-6.25%
= 93%
Option-B: Here 4 replications, it means down time is 25% equivalent 0.25.
According to 4 replications we have to multiply with 0.25*0.25*0.25*0.25
= 0.00390625
Availability= 100-0.0390625%
= 99.9609375%
Option-C: Here 8 replications, it means down time is 25% equivalent 0.25.
According to 8 replications we have to multiply with
= 0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25
= 0.0000152587890625
Availability= 100-0.00152587890625%
= 99.99847412109375%
Option-D: Here 16 replications, it means down time is 25% equivalent 0.25.
According to 16 replications we have to multiply with
= 0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25*0.25
= 0.00000000023283064365386962890625
Availability= 100-0.000000023283064365386962890625%
= 99.999999976716935634613037109375%
Hence, option-B is most suitable answer.
Question 4

Consider the Unix i-node which uses 12 direct DBAs, 1 single indirect, 1 double indirect, 1 triple indirect. The disk block address requires 32 bits and disk block size is 1 KB. What is the maximum file size?

A
32 GB
B
64 GB
C
16 GB
D
8 GB
Question 4 Explanation: 
Disk block address size = 32 bits = 32/8 B = 4B
No. of addresses that can fit in one block = size of block/size of address = 210B/22B = 28
∴ The maximum file size,
= (Direct address + 1 single indirect + 1 double indirect + 1 triple indirect) × Block size
= (12 + 28 + 28 × 28 + 28 × 28 × 28) × 210
≌ 234 = 16GB
Question 5
Which of the following is an auxiliary storage device?
A
Tape
B
Disk
C
Pen Drive (Memory Stick)
D
All the above
Question 5 Explanation: 
Auxiliary storage is any storage that is made available to the system through input/output channels. This term refers to any addressable storage that is not within the system memory (RAM). These storage devices hold data and programs for future use and are considered nonvolatile storage that retains information even when power is not available. They trade slower read/write rates for increased storage capacity.
Auxiliary storage may also be referred to as secondary storage.
So all the given options are auxiliary memory.
There are 5 questions to complete.

Access quiz wise question and answers by becoming as a solutions adda PRO SUBSCRIBER with Ad-Free content

Register Now

If you have registered and made your payment please contact solutionsadda.in@gmail.com to get access