OS-Contiguous Allocation

In contiguous allocation, files are assigned to contiguous areas of secondary storage. A user specifies in advance the size of the area needed to hold a file is to be created. If the desired amount of contiguous space is not available the file cannot be created.

One advantage of contiguous allocation is that successive logical records are normally physically adjacent to one another. This speed access compared to systems in which successive logical records are dispersed throughout the disk.

The file directories in contiguous allocation systems are relatively straightforward to implement. For each file it is necessary to retain the address of the start of the file and the file’s length.

Disadvantage of contiguous allocation is as files are deleted, the space they occupied on secondary storage is reclaimed. This space becomes available for allocation of new files, but these new files must fit in the available holes. Thus contiguous allocation schemes exhibit the same types of fragmentation problems inherent in variable partition multiprogramming systems – adjacent secondary storage holes must be coalesced, and periodic compaction may need to be performed to reclaim storage areas large enough to hold new files.
Share this article :
Copyright © 2012. Best Online Tutorials | Source codes | Programming Languages - All Rights Reserved