Architecture, Implementation and Administration from Kernel Internals to Cloud-Native Systems
- About This Book
- Introduction: The Abstraction That Makes Linux Possible
- What Is a Virtual Filesystem?
- The Scale of the Problem
- Why VFS Matters to You
- How This Book Is Organized
Chapter 1: Historical Evolution and Design Philosophy
- Pre-VFS Unix Filesystem Landscape
- Birth of VFS in Linux 1.3.x
- Design Principles: Abstraction, Extensibility, Minimalism
- The VFS as a Kernel Subsystem
- Lessons from Other Operating Systems
Chapter 2: Core VFS Objects: The Building Blocks
- The Superblock: Filesystem-Wide State
- The Inode: Metadata Without a Name
- The Dentry: Naming and Caching
- The File Object: Open File Description
- The Mount Structure: Binding Filesystems to Directories
- How the Objects Fit Together
Chapter 3: Pathname Resolution and Caching Mechanisms
- The Lookup Algorithm: Walking a Path Component by Component
- The Dentry Cache (dcache): Structure and Hash Table Design
- Negative Dentries and Caching Nonexistence
- Inode Caching and the Icache
- Follow Symlinks, Bind Mounts and Special Cases
- Performance Characteristics: When Path Resolution Becomes a Bottleneck
Chapter 4: System Calls and the VFS Interface
- The Syscall Entry Path: From User Space to VFS Dispatch
- File Operations Vector (
struct file_operations) - Inode Operations Vector (
struct inode_operations) - Superblock Operations Vector (
struct super_operations) - Dentry Operations Vector (
struct dentry_operations) - Key System Calls Walked Through
Chapter 5: Security Model and Permissions
- Discretionary Access Control: Traditional Unix Permissions
- The Permission Checking Path in VFS
- Linux Security Modules (LSM) Hooks in VFS
- Capabilities and Fine-Grained Privilege Management
- Extended Attributes, ACLs and Security Labels
- SELinux, AppArmor and Smack Integration with VFS
Chapter 6: Pseudo-Filesystems I: /proc, /sys, tmpfs and devtmpfs
- What Makes a Filesystem “Pseudo”?
- /proc: The Process Information Filesystem
- /sys: The Sysfs Hierarchy
- tmpfs: Memory-Backed RAM Filesystem
- devtmpfs: Automatic Device Node Management
Chapter 7: Pseudo-Filesystems II: cgroupfs, debugfs, tracefs, securityfs, configfs
- cgroupfs: Control Groups Filesystem
- debugfs: Kernel Debugging Interface
- tracefs: Tracing Infrastructure Filesystem
- securityfs: LSM Configuration Interface
- configfs: Dynamic Object Configuration
Chapter 8: Advanced Virtual Filesystems: overlayfs and FUSE
- overlayfs: Union Mount Architecture
- overlayfs Implementation Details
- FUSE: User-Space Filesystem Framework
- FUSE Performance and Limitations
- overlayfs Versus btrfs Subvolumes: A Structured Comparison
- Real-World Case Studies
Chapter 9: Namespaces, Mounts and Containerization
- Mount Namespaces: Isolating the View of the Filesystem Hierarchy
- Private, Shared, Slave and Unbindable Mount Propagation
- Bind Mounts and Their Role in Container Storage
- The Mount Tree Data Structure
- Containers and VFS: Docker, Podman and Kubernetes Perspectives
- Container Storage Driver Comparison
- Overlayfs as the Default Container Storage Driver
Chapter 10: Performance, Scalability and Optimization
- The Page Cache: Where Most File I/O Actually Happens
- Read-Ahead Algorithms and Prefetching Strategies
- Writeback and the Dirty Page Management Subsystem
- Direct I/O and Bypassing VFS Caching (O_DIRECT, io_uring)
- Scalability Challenges: Large Directories, Namespace Storms, Lock Contention
- Tuning Parameters and Performance Diagnostics
Chapter 11: Troubleshooting, Debugging, Tracing and Monitoring
- Syscall Tracing with strace and Performance Analysis with perf
- Kernel Tracing: ftrace, tracefs and Built-In VFS Traces
- eBPF for VFS Diagnostics (kprobes, tracepoints, BCC tools)
- Common Failure Patterns
- Mount Options for Debugging
- Monitoring Filesystem Health and Performance in Production
Chapter 12: Cloud-Native Use Cases and Virtualization
- Container Storage Orchestration: CSI, Persistent Volumes and VFS
- Network Filesystems Through the VFS Lens
- Virtualization Filesystem Backends (virtiofs, 9p, VMware vmhgfs)
- Ephemeral Storage Patterns in Kubernetes and Serverless
- Cloud Provider Filesystems: EBS, GCE Persistent Disks, Azure Files
- Distributed Filesystem Challenges at Scale
Chapter 13: Recent Kernel Developments and Future Directions
- The New Mount API: fs_context, fs_parameter, open_tree, move_mount
- io_uring and Asynchronous File I/O Through VFS
- Landlock: Unprivileged Process Sandboxing via Pathnames
- statx and Extended File Attributes
- BPF Filesystem Hooks and Runtime Security
- Where VFS Is Heading: Trends, Open Questions and Community Directions
