Masters of Computer Science Open Source Technology

File Structure and Hierarchy in Linux

File Structure and Hierarchy in Linux

File Structure and Hierarchy

  • File system is a collection of files in a structure on disk or partition
  • When memory is segmented and it contains data, it is a partion
  • In normal, every partition has file system.
  • To store the data systematically, we need a location. Folowing are reasons why we should have file system
    • RAM is volatile, where computer stores data primarily
    • Storage of data in hard drive is preferred, which is non volatile memory.

Linux File System

  • It is built in layer of Linux OS, which is used to handle data, and manage the storage
  • Arranges file in disk storage.
  • File name, size, creation date etc are managed here

Linux File system contains

  • Root directory (/)
  • Specific storage format (EXT, XFS etc)
  • Partition (Logical Volume) with particular file system

Structure of Linux File System

  • Has hierarchical file system, containing root and its subdirectories
  • From root director, all the directories can be accessed easily.
  • File system is designed to manage and provide space for non volatile storage.
  • All file system has namespace – naming and organizational methodology. It gives process for naming, file name length etc
  • Logical structure of file on memory is also defined here.
  • After defining namespace, meta data is also described.

Types of Linux File System

After linux OS is installed, there are file systems such as

  • Ext
  • Ext2
  • Ext 3
  • Ext 4
  • JFS
  • ReiserFS
  • XFS
  • Btrfs
  • Swap

Ext File System

  • Extended File System.
  • Primarily developed for MINIX OS
  • Older one, no useful at this time


  • First file systm in linux which allows management of terabytes of data

Ext 3

  • Developed and upgraded through ext 2 which contains backward compatibility
  • Disadvantage: Doesn’t support servers and file recovery

Ext 4

  • Fastest of all Ext
  • Default file system in Linux
  • Compatible for SSD


  • Journal Filed System
  • For AIX Unix, IBM developed JFS
  • Can be used as replacement for Ext 4
  • If power of CPU is limited, it is handy file system
  • More stable with less resource

ReiserFS File System

  • Alternative of Ext 3
  • Has advanced features and improved performance
  • Used to be default file system in SUSE Linux but due to some policy changes, SUSE used Ext 3
  • Dynamically supports file extension

XFS File System

  • Higher speed JFS
  • Parallel I/O processing is supported
  • NASA uses XFS

Btrfs File System

  • B tree Fi;e System
  • For system repair, fault tolerance, fun administration, extensive storage configuration, Btrfs file system is used.
  • Not suitable for production system
  • Copy – on – write file system
  • Announced by Oracle in 2007
  • Published under GNU GPL

Swap File System

  • Memory paging in Linux is done by swap file system during system hibernation
  • If system never goes hibernation, swap space should be equal to its RAM size
About Author

ICT Byte