What are different types of file organisations used in contemporary file systems in modern-day operating system? Explain with examples.

File organization defines however records in an exceedingly file area unit associated with each other. totally different file organizations area unit designed to optimize performance for one or each file access ways. There area unit many common file organizations. They are:

(a) SEQUENTIAL FILE: Here records area unit organized in an exceedingly sequence adjacent to 1 another. Records area unit accessed consecutive. To browse a file record, the records ranging from 1st record forwards is browse (or from current record onward is read) till the required record is found.

(b) RELATIVE OR DIRECT FILE: Here record occurrences area unit physically situated at Associate in Nursing address that's calculated from its primary key field. The calculation of the address from the key field is termed hashing. therefore record occurrences area unit scattered on the memory device rather than being organized next to 1 another. Records are often retrieved chop-chop applying the hashing formula to the first key field of the required record. Relative files area unit excellent for things wherever fast access to tiny low proportion of records in an exceedingly file area unit required by programs.

INDEXED FILES: Here records area unit pointed to by indexes. the benefits of Associate in Nursing index is that it's comparatively tiny and straightforward to update. At a most, the file can have one index per primary key. This index purpose to the precise location wherever knowledge (record) is hold on. If not maintained properly, indexes will become corrupt and need reconstruction.

INDEXED SEQUENTIAL FILE: this can be a special variation on the indexed file conception. Records area unit physically organized in sequence to permit consecutive access, in contiguous locations or employing a joined list or each. These file conjointly contain Associate in Nursing index of record keys and their physical addresses that may be accustomed give semi direct access to records at intervals the consecutive file. every program determines however it wish to access the records, whether or not consecutive or via the index.

Post a Comment