Home / Companies / Replit / Blog / Post Details
Content Deep Dive

Killing Containers at Scale

Blog post from Replit

Post Details
Company
Date Published
Author
Connor Brewster
Word Count
1,761
Company Posts That Month
4
Language
English
Hacker News Points
-
Post removed?
No
Summary

To make it so that anyone with a web browser can code on Replit, our backend infrastructures runs on preemptible VMs. These machines can shutdown at any time, but we've optimized the process to reconnect quickly. However, some users were experiencing stuck repls due to slow container shutdowns. We investigated and found that Docker was taking an excessively long time to kill containers, causing them to be inaccessible for up to a minute. After digging into Docker's source code, we discovered that the issue was with netlink operations releasing network resources. To bypass this bottleneck, we killed the container's pid directly instead of relying on Docker's cleanup process. This change significantly improved our session connection error rate and reduced boot times from 2 minutes to just 15 seconds. By circumventing Docker's slow shutdown process, we've created a smoother experience for Replit users.

Trends Found in this Post

No tracked trend matches for this post yet.

Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.