Fresh Info Box - The World of Information

The World Of Information That You Must Read

Full width home advertisement

Entertainment Trends

Post Page Advertisement [Top]

File System
In a computer, a file system (sometimes written filesystem) is the way in which files are named and where they are placed logically for storage and retrieval.

Alternatively referred to as file management and sometimes abbreviated as FS, a file system is a method of organizing and retrieving files from a storage medium, such as a hard drive. File systems usually consist of files separated into groups called directories. Directories can contain files or additional directories. Today, the most commonly used file system with Windows is NTFS.

Without a file management, all files would have no organization and it would be impossible for a file with the same name to exist. Typically, files are managed in a hierarchy, which allows you to view files in the current directory and then navigate into any subdirectories.

File Access Mechanisms

File access mechanism refers to the manner in which the records of a file may be accessed. There are several ways to access files −
  1. Sequential access
  2. Direct/Random access
  3. Indexed sequential access

Sequential access

A sequential access is that in which the records are accessed in some sequence, i.e., the information in the file is processed in order, one record after the other. This access method is the most primitive one. Example: Compilers usually access files in this fashion.

Direct/Random access

  1. Random access file organization provides, accessing the records directly.
  2. Each record has its own address on the file with by the help of which it can be directly accessed for reading or writing.
  3. The records need not be in any sequence within the file and they need not be in adjacent locations on the storage medium.

Indexed sequential access

  1. This mechanism is built up on base of sequential access.
  2. An index is created for each file which contains pointers to various blocks.
  3. Index is searched sequentially and its pointer is used to access the file directly.

Space Allocation

Files are allocated disk spaces by operating system. Operating systems deploy following three main ways to allocate disk space to files.
  1. Contiguous Allocation
  2. Linked AllocationA
  3. Indexed Allocation

Contiguous Allocation

  1. Each file occupies a contiguous address space on disk.
  2. Assigned disk address is in linear order.
  3. Easy to implement.
  4. External fragmentation is a major issue with this type of allocation technique.

Linked Allocation

  1. Each file carries a list of links to disk blocks.
  2. Directory contains link / pointer to first block of a file.
  3. No external fragmentation
  4. Effectively used in sequential access file.
  5. Inefficient in case of direct access file.

Indexed Allocation

  1. Provides solutions to problems of contiguous and linked allocation.
  2. A index block is created having all pointers to files.
  3. Each file has its own index block which stores the addresses of disk space occupied by the file.
  4. Directory contains the addresses of index blocks of files.

Examples of file systems

  • FAT (e.g., FAT16 and FAT32) (File Allocation Table)
  • GFS (Global File System)
  • HFS (Hirarchical File System)
  • NTFS (New Technology File System)
  • UDF (Universal Data Format)

No comments:

Post a Comment

Bottom Ad [Post Page]