03 / A systems publication

Under the Hood.

Why is the mount stuck? Where did the packet wait? What is using the GPU memory? Start with the symptom, then follow the system underneath.

Start here / Storage systems

Follow a directory listing from userspace to VFS, the NFS client, RPC, and the server—and learn why a slow listing is not automatically a slow READDIR.

Read the article →

4 min read / 4 references

One command, several boundaries
  1. 01ls / userspace
  2. 02VFS & client caches
  3. 03NFS / RPC / XDR
  4. 04TCP & the server
A conceptual path. Cache hits can avoid RPCs.
Read, investigate, reproduce

The reading room.

24 articles / 7 categories

C++ Systems Engineering

A Bounded Blocking Queue in C++: Predicates, Backpressure, and Shutdown

Build a small C++ integer queue with explicit capacity, condition-variable predicates, graceful close, and defined producer/consumer behavior. Understand what the example leaves out.

C++ConcurrencyQueues
Networking

Linux Conntrack and NAT: Following Original and Reply Tuples

Understand how Linux connection tracking records flows, how NAT chooses and reuses mappings, and how to diagnose state without confusing it with firewall policy.

ConntrackNATNetfilter
Distributed Systems

Consistent Hashing: Virtual Nodes, Key Movement, and Failure

Learn how consistent hashing assigns keys, why virtual nodes improve distribution, and what happens on node failure. Explore placement in a deterministic hash-ring lab.

Consistent hashingReplicationPlacement
AI Infrastructure

Continuous Batching: LLM Throughput, Queueing, and Tail Latency

Learn how iteration-level scheduling admits and retires LLM requests, why token budgets matter, and how to measure throughput without sacrificing first-token or streaming latency.

BatchingSchedulingInference
C++ Systems Engineering

C++ Atomics and Memory Ordering: Publish Data, Not Just a Flag

Understand atomicity, release/acquire publication, relaxed counters, and object lifetime. Use a complete one-shot example without mistaking atomics for a general lock-free design.

C++AtomicsMemory ordering
Linux Internals

epoll Explained: Readiness, Edge Triggers, and Backpressure

Understand Linux epoll readiness semantics, level- versus edge-triggered handling, EAGAIN, writable interest, and connection lifetime pitfalls in event-driven servers.

LinuxepollSockets
Storage Systems

Debugging a Hung NFS Mount: Timeouts, Retries, and D-State Waits

Diagnose a stuck Linux NFS operation without unsafe remount advice. Separate process waits, RPC recovery, network reachability, server health, and mount semantics.

NFSTroubleshootingTimeouts
AI Infrastructure

KV Cache Memory Explained: Bytes per Token and GPU Budget

Calculate KV cache bytes per token from layers, KV heads, precision, and context. Account for concurrency and block allocation without confusing estimates with GPU measurements.

KV cacheMemoryInference
Networking

A packet's journey through the Linux kernel

Trace a conventional receive path from NIC queues and DMA through NAPI, IP, TCP, and the application—with execution context and observation points at every stage.

LinuxNetworkingNAPI
Storage Systems

What actually happens when you run ls on an NFS mount?

Follow a directory listing from userspace to VFS, the NFS client, RPC, and the server—and learn why a slow listing is not automatically a slow READDIR.

NFSLinuxVFS
Linux Internals

Linux Memory Reclaim and the OOM Killer: Diagnose the Right Limit

Distinguish reclaim, cache eviction, swapping, cgroup limits, and OOM kills. Use memory and pressure observations without treating low free memory as a diagnosis.

LinuxMemoryReclaim
Storage Systems

Linux NFS Client Caching: Attributes, Data, and Close-to-Open Semantics

Separate NFS directory, attribute, and data caching. Understand close-to-open behavior, rsize/wsize, writeback, and what caching changes mean for correctness and performance.

NFSCachingConsistency
Storage Systems

NFSv3 Under the Hood: RPC, XDR, File Handles, and Statelessness

Understand the NFSv3 mount and request path, XDR encoding, file handles, stable writes, and the limits of statelessness. Compare the right boundaries with NFSv4.

NFSv3RPCXDR
Performance Engineering

NUMA-Aware Networking: Align NIC, CPU, and Memory—Then Measure

Distinguish NIC locality, IRQ affinity, process affinity, and memory placement. Design a controlled NUMA networking comparison without inventing universal latency penalties.

NUMANetworkingPerformance
Networking

Diagnosing Linux Packet Drops and TCP Retransmissions

Locate packet loss across NIC, kernel, TCP, and application layers using counter deltas and scoped observations. Avoid confusing retransmissions with proof of NIC drops.

NetworkingTroubleshootingTCP
Linux Internals

Linux Page Cache and Writeback: When Does a Write Reach Storage?

Follow buffered reads and writes through the Linux page cache, dirty-page accounting, writeback, and synchronization. Measure useful work without confusing RAM speed with durability.

LinuxPage cacheWriteback
AI Infrastructure

PagedAttention Explained: KV Blocks, Allocation, and Sharing

Understand how PagedAttention separates logical token order from physical KV storage, reduces allocation waste, and enables sharing without making attention cost disappear.

PagedAttentionKV cacheInference
AI Infrastructure

Prefill vs Decode: Why LLM Inference Has Different Bottlenecks

Separate prompt prefill from autoregressive decode, time to first token from inter-token latency, and compute-bound work from memory and communication limits.

InferenceGPUPrefill
AI Infrastructure

LLM Prefix Caching: What Can Be Reused and What Cannot

Understand token-prefix identity, reusable KV blocks, cache-key compatibility, and prefix-cache measurement. Learn why a cache hit mainly changes prefill, not future decode work.

Prefix cachingKV cacheInference
Distributed Systems

Quorums and Stale Reads: What R + W > N Really Guarantees

Understand replica-set intersection, asynchronous replication, failed writes, and the limits of quorum arithmetic. Explore stale reads in a deterministic single-writer lab.

QuorumsReplicationConsistency
Distributed Systems

Retry Storms and Backpressure: Keep Overload from Feeding Itself

Design retries with deadlines, jitter, idempotency, and budgets. Combine bounded queues and load shedding to prevent transient failures from becoming sustained overload.

RetriesBackpressureReliability
Networking

RSS vs RPS vs RFS vs XPS

Separate hardware queue selection, software CPU steering, application locality, and transmit queue selection before deciding what to tune.

RSSRPSRFS
Performance Engineering

Latency Percentiles: p50, p95, p99, and the Limits of Averages

Understand nearest-rank latency percentiles, sample-size limits, coordinated omission, and benchmark methodology. Analyze a concrete sample in the browser.

LatencyPercentilesBenchmarking
Networking

Linux TCP Buffer Tuning: rmem, wmem, Autotuning, and BDP

Diagnose TCP window limits using bandwidth-delay product and socket observations. Understand Linux buffer controls without applying universal sysctl values.

TCPBuffersAutotuning
Go beyond the page

Try the idea yourself.

Change a cache policy, move a key around the ring, or calculate the cost of a longer context. The labs keep their assumptions next to the controls.

Open the systems lab →
Stay in the loop

New articles, in your reader.

The RSS feed includes every published article. No signup or tracking required.

Subscribe via RSS ↗

Search the notebook

Search articles, projects, and experiments. Everything stays on your device.

palash / notebook

A small doorway into the site. No shell, no remote execution.

Welcome. Type help to find your way around.

lab →experience →contact →Ctrl / Cmd + K