beginnerImages, Layers, Caching & Container Lifecycle
What is copy-up, and why does it matter for performance?
Copy-up is the overlay2 behavior where, the first time a container modifies a file that exists in a lower read-only layer, the entire file is copied into the writable layer before the modification is applied. For large files, this makes the first write unexpectedly slow, which is one reason write-heavy data (like a database's data directory) belongs in a volume, not the container's own filesystem.
Ready to master this question?
Generate a complete walkthrough — background, the full answer in plain language, a working code example explained line by line, a real-world scenario, common mistakes, and how this same question gets asked in different ways.
Sign in to generate a response