Computer Science, asked by solmanrajuroyals143, 1 year ago

6. a) Briefly explain about single-level, two-level and Tree-Structured directories. [6M]
b) Consider a disk queue with following requests for I/O to blocks on cylinders
30,70,115,130.110,80,20,25 (Assume disk head is at 90)
Draw FCFS and SSTF scheduling and also determine how many times the disk
head changes its direction for each of the above mentioned scheduling techniques.

Answers

Answered by adityakumar122
0

Answer:

A directory is a container that is used to contain folders and file. It organizes files and folders into a hierarchical manner.

There are several logical structures of a directory, these are given below.

Single-level directory –

Single level directory is simplest directory structure.In it all files are contained in same directory which make it easy to support and understand.

A single level directory has a significant limitation, however, when the number of files increases or when the system has more than one user. Since all the files are in the same directory, they must have the unique name . if two users call their dataset test, then the unique name rule violated.

Advantages:

Since it is a single directory, so its implementation is very easy.

If files are smaller in size, searching will faster.

The operations like file creation, searching, deletion, updating are very easy in such a directory structure.

Disadvantages:

There may chance of name collision because two files can not have the same name.

Searching will become time taking if directory will large.

In this can not group the same type of files together.

Two-level directory –

As we have seen, a single level directory often leads to confusion of files names among different users. the solution to this problem is to create a separate directory for each user.

In the two-level directory structure, each user has there own user files directory (UFD). The UFDs has similar structures, but each lists only the files of a single user. system’s master file directory (MFD) is searches whenever a new user id=s logged in. The MFD is indexed by username or account number, and each entry points to the UFD for that user.

Similar questions