When Zero-Copy Isn't Zero: The Hidden Copies in Your "Efficient" Code

A file sits on disk. Your application reads it and sends it over the network. Simple enough—but behind this mundane operation hides one of computing’s most persistent performance bottlenecks. In a traditional I/O path, that single file traverses through four distinct memory copies before reaching the network interface. The kernel reads data from disk into a kernel buffer via DMA. The read() system call copies it to user space. The write() system call copies it back to a kernel socket buffer. Finally, DMA transfers it to the NIC. Each copy consumes CPU cycles, memory bandwidth, and cache space. ...

8 min · 1585 words

How Docker Actually Works: Namespaces, Cgroups, and the Linux Kernel Features That Make Containers Possible

In March 2013, Solomon Hykes demonstrated a new tool at PyCon that would fundamentally change how software gets deployed. He ran a simple command: docker run -i -t ubuntu /bin/bash. Within seconds, a complete Ubuntu environment appeared, ready to accept commands. The audience saw what looked like a lightweight virtual machine. What they were actually witnessing was something far more elegant: a single Linux process, wrapped in kernel features that had been maturing for over a decade. ...

14 min · 2962 words