Unix filesystems

EXT and More

What is a filesystem?

Blocks and sectors

See this page.

What is a ‘BLOCK’?

What is a ‘BLOCK’?

Bad Blocks ?


Files and Inodes

Files :

Files and Inodes

If I were to access a file called f1.txt, the operating system would look up the corresponding i-node (which could in-turn lookup related inodes that are part of the file)

Inode tables

The operating system maintains a table of inodes.

Viewing inodes

More testing with inodes

Other inode implications

One more piece of information

When you create a hard link, it just created a new name in the table, along with the inode, without moving the file. When you move a file (or rename it), you don’t copy the data. That would be Slow. You just create the (name,inode) entry in a new directory, and delete the old entry in the table inside the old directory entry. In other words, moving a gigabyte file takes very little time. In the same way, you can move/rename directories very easily. That’s why “mv /usr /Old_usr” is so fast, even though “/usr” may contain (for example) 57981 files.

But what if I move across partitions?

Inode Examples

Inode Examples

Finding with inodes.

Inodes viewing

Special Inode note

Data block map

Data block map

See the page here


Unix filesystems


Contains information about the filesystem as a whole such as:

Superblock Viewage

Superblock Importance

Last word on Superblocks (for today)


The EXT filesystem tools

EXT4 is the most common linux filesystem in use.

How to use mount command


File system size terminology

Computation Example

df vs partition size

Why am I getting different results?

What is a journal


Try this one more time