Skip to main content

Posts

Showing posts from October, 2016

Understanding File System Superblock in Linux

Extended Filesystem being the default file system in Linux, we will be focusing ext file system in this article to understand super blocks . Before we get to understanding Super blocks in a file system, let’s understand some common terminologies and building blocks of a file system.   Blocks in File System When a partition or disk is formatted, the sectors in the hardisk is first divided into small groups. This groups of sectors is called as blocks. The block size is something that can be specified when a user formats a partition using the command line parameters available. 1 mkfs -t ext3 -b 4096 /dev/sda1 In the above command we have specified block size while formatting /dev/sda1 partition. The size specified is in bytes. So basically one block will be of 4096 bytes. Block Size for Ext2 can be 1Kb, 2Kb, 4Kb, 8Kb Block Size for Ext3 can be 1Kb, 2Kb, 4Kb, 8Kb Block Size for Ext4 can be 1Kb to 64Kb The block size you select will impa