What’s an inode and what’s inside of one? (Linux First Principles)

Connor Brereton
3 min readApr 7, 2020
inode architecture — Source

Before I get into a bunch of technical details I want to touch on one thing that is instrumental to know before diving deep: in Linux, everything is a file — you heard that right — everything is a file.

But what about sockets you might say? What about a hard link? These are all files. Simple as that.

The important thing to know is that while everything is a file there are different types of files! This is crucial to know as we build upon our knowledge.

Now that you know that everything is a file it’s important to know that Linux uses something called the VFS — virtual file system. In this VFS there are four main abstractions that we use:

  1. Files (regular, special, etc.)
  2. Directory entries (aka dentry)
  3. Inodes
  4. Mount points

This diagram below will help you see the big picture of what a file system in a UNIX system is really composed of at a “big picture” level:

You see the hard disk itself is the actual hardware cylinder. That’s what memory is in computers. Each…