{"id":5308,"date":"2025-03-18T04:22:29","date_gmt":"2025-03-18T04:22:29","guid":{"rendered":"https:\/\/www.liainfraservices.com\/blog\/?p=5308"},"modified":"2025-04-05T11:23:50","modified_gmt":"2025-04-05T11:23:50","slug":"how-docker-managed-its-image-layers","status":"publish","type":"post","link":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/","title":{"rendered":"How docker manages its image layers?"},"content":{"rendered":"<span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\"><\/span> <span class=\"rt-time\"> 5<\/span> <span class=\"rt-label rt-postfix\">min read<\/span><\/span><div class='epvc-post-count'><span class='epvc-eye'><\/span>  <span class=\"epvc-count\"> 2,342<\/span><\/div>\n<p class=\"wp-block-paragraph\"><strong>Docker Layered Filesystem<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Why do we complicate the simple things so much and then find it super difficult to understand and use in the real tech world?<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Lets bake a pan cake and understand one of the most important concepts in Docker and it is related to its file system called Docker Layered File System.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What is Docker?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">By now, I am sure, we all know what is docker, if still it needs more understanding, then here we go.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Imagine you are baking a cake. You need a recipe (lets call it a <strong>Dockerfile<\/strong>) that tells you step by step what to do. Docker is like your super smart kitchen helper that follows the recipe and builds the cake for you. But instead of a cake, Docker builds something called a <strong>container<\/strong>, which is like a tiny, self contained computer that runs an app.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What\u2019s a Layered Filesystem?<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"952\" src=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/docker-layered-filesystem-1024x952.png\" alt=\"\" class=\"wp-image-5310\" srcset=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/docker-layered-filesystem-1024x952.png 1024w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/docker-layered-filesystem-300x279.png 300w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/docker-layered-filesystem-768x714.png 768w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/docker-layered-filesystem.png 1165w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Now, that\u2019s the real thing, in our Linux host we deal with file system like NTFS, XFS, EXT4 etc, but do we use the same layer of file system in docker as well? lets talk about the <strong>layered filesystem<\/strong>. Think of it like a stack of pancakes. Each pancake is a <strong>layer<\/strong>, and when you stack them up, you get a delicious stack of pancakes. Similarly, Docker uses layers to build its containers. Each layer is like a step in the recipe, and when you stack them up, you get a complete container.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"173\" src=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.50.39-PM-1024x173.png\" alt=\"\" class=\"wp-image-5313\" srcset=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.50.39-PM-1024x173.png 1024w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.50.39-PM-300x51.png 300w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.50.39-PM-768x129.png 768w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.50.39-PM.png 1068w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Example: Building a Cake (or a Container.)<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Lets say your recipe (Dockerfile) looks like this:<\/p>\n\n\n\n<ol start=\"1\" class=\"wp-block-list\">\n<li><strong>Start with a plate<\/strong> (this is like the base layer, <code>FROM ubuntu<\/code>).<\/li>\n\n\n\n<li><strong>Add a pancake<\/strong> (this is like installing something, <code>RUN apt update<\/code>).<\/li>\n\n\n\n<li><strong>Add some syrup<\/strong> (this is like adding more stuff, <code>RUN apt install nginx<\/code>).<\/li>\n\n\n\n<li><strong>Top it with whipped cream<\/strong> (this is like the final touch, <code>CMD [\"nginx\", \"-g\", \"daemon off;\"<\/code>]).<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Btw<\/strong>, in Dockerfile the 1<sup>st<\/sup> part is called the Instruction and the 2<sup>nd<\/sup> part is called as the Arguments to that instruction.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here, each step adds a new layer to your stack. Docker does the same thing when building a container and so these each layers are stored as a separate file or folder ( <code>\/var\/lib\/docker\/overlay2<\/code>)<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Or it can be other storage driver, get to know about storage driver from <code>docker info<\/code> command.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Why Use Layers?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now, the question is, why do we need to use Layered File System and what benefit does it provide.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Layers are super cool because they save time and space. Let me explain:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>1. Its Reusable<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Imagine you have a stack of pancakes, and you want to make another stack. Instead of making all the pancakes from scratch, you can reuse the ones you already have. Docker does the same thing. If two containers need the same base layer (like ubuntu), Docker reuses it instead of making a new one. This saves a lot of time and space.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>2. Its Read Only<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Once a pancake is made, you can\u2019t change it. It\u2019s <strong>read only<\/strong>. If you want to add more syrup or whipped cream, you just add a new pancake on top. Docker works the same way. The layers in an image are read only, so if a container needs to change something, it adds a new <strong>writable layer<\/strong> on top.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>What\u2019s a Writable Layer?<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">But, if docker each layer is only Read Only, the how can we use that for container, as in the container there are configuration files, log files and many other files, which needs to have write access to do some modification. Lets get the concept here as the container adds a writable layer above the read only layer of docker image and that\u2019s how we get the container super flexible to run an application on that.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Copy-on-Write (CoW)<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Lets say we need a layer file to be used to write for a specific container, For that, we make a copy of that layer and then assign that to that container(process) and it can be used to do any modification on that layer without disturbing the original layer, in that case, we call that layer as a Copy on Write.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>How Does Docker Store Layers?<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"215\" src=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.45.29-PM-1-1024x215.png\" alt=\"\" class=\"wp-image-5314\" srcset=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.45.29-PM-1-1024x215.png 1024w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.45.29-PM-1-300x63.png 300w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.45.29-PM-1-768x161.png 768w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-4.45.29-PM-1.png 1248w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">Docker stores layers as special files and folders on host(Linux). It uses something called a <strong>storage driver<\/strong> (overlay2) to manage these layers. Think of the storage driver as a librarian who organizes all the books (layers) in a library (your computer).<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>The librarian knows where each book is stored.<\/li>\n\n\n\n<li>When you need a book, the librarian finds it and gives it to you.<\/li>\n\n\n\n<li>If you want to write in a book, the librarian gives you a copy instead of the original.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Now, we know that each Read Only layers are an individual files\/folders as mentioned above, so they should have a specific size and to see those layers size, we can use <code>docker history &lt;image_id><\/code><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"205\" src=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM-1024x205.png\" alt=\"\" class=\"wp-image-5315\" srcset=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM-1024x205.png 1024w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM-300x60.png 300w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM-768x153.png 768w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM-1536x307.png 1536w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Screenshot-2025-03-17-at-5.06.05-PM.png 1742w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Lets understand all agin with an example of Building a LEGO Castle<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Lets use LEGO blocks to explain Docker\u2019s layered filesystem:<\/p>\n\n\n\n<ol start=\"1\" class=\"wp-block-list\">\n<li><strong>Base Plate<\/strong>: This is like the base layer (FROM ubuntu). Its the foundation of the LEGO castle.<\/li>\n\n\n\n<li><strong>First Layer<\/strong>: Add walls and doors (RUN apt update). This is the second layer.<\/li>\n\n\n\n<li><strong>Second Layer<\/strong>: Add windows and a roof (RUN apt install nginx). This is the third layer.<\/li>\n\n\n\n<li><strong>Final Touch<\/strong>:Add flags and decorations (CMD [&#8220;nginx&#8221;, &#8220;-g&#8221;, &#8220;daemon off;&#8221;]). This is the top layer.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">Now, we have a complete LEGO castle (Docker image). If we want to play with the castle (run a container), we can add a new layer of LEGO blocks (the writable layer) on the top of that caste to make any changes without breaking the original castle.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Why Is This Cool?<\/strong><\/p>\n\n\n\n<ol start=\"1\" class=\"wp-block-list\">\n<li><strong>Efficiency<\/strong>: Docker reuses layers, so it does not have to build everything from scratch every time. This saves time and space.<\/li>\n\n\n\n<li><strong>Isolation<\/strong>: Each container has its own writable layer, so changes in one container dont affect others. Its like having separate LEGO sets for different castles.<\/li>\n\n\n\n<li><strong>Consistency<\/strong>: Since the layers are read only, the base image stays the same no matter how many containers you run. This makes apps run reliably.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">If this makes it easy to understand, write your comments and I will break down complex concepts like this to make it easy to understand, which would ease the work with this technology, and if any issue comes we know exactly where to look for the issue.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"1024\" src=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you-1024x1024.png\" alt=\"\" class=\"wp-image-5316\" srcset=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you-1024x1024.png 1024w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you-300x300.png 300w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you-150x150.png 150w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you-768x768.png 768w, https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/Thank-you.png 1080w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n","protected":false},"excerpt":{"rendered":"<p><span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\"><\/span> <span class=\"rt-time\"> 5<\/span> <span class=\"rt-label rt-postfix\">min read<\/span><\/span>2,342 Docker Layered Filesystem Why do we complicate the simple things so much and then find it super difficult to understand and use in the real tech world? Lets bake<\/p>\n","protected":false},"author":1,"featured_media":5318,"comment_status":"open","ping_status":"open","sticky":true,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"footnotes":""},"categories":[974],"tags":[],"class_list":["post-5308","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-docker"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How docker manages its image layers? - Blog | Liainfraservices<\/title>\n<meta name=\"description\" content=\"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How docker manages its image layers? - Blog | Liainfraservices\" \/>\n<meta property=\"og:description\" content=\"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog | Liainfraservices\" \/>\n<meta property=\"article:published_time\" content=\"2025-03-18T04:22:29+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-04-05T11:23:50+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg\" \/>\n\t<meta property=\"og:image:width\" content=\"1600\" \/>\n\t<meta property=\"og:image:height\" content=\"900\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Partho\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Partho\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/\"},\"author\":{\"name\":\"Partho\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#\\\/schema\\\/person\\\/b5a729cb152dd3bc7f07550ca9d223e4\"},\"headline\":\"How docker manages its image layers?\",\"datePublished\":\"2025-03-18T04:22:29+00:00\",\"dateModified\":\"2025-04-05T11:23:50+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/\"},\"wordCount\":1053,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/feature-image.jpeg\",\"articleSection\":[\"Docker\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/\",\"url\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/\",\"name\":\"How docker manages its image layers? - Blog | Liainfraservices\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/feature-image.jpeg\",\"datePublished\":\"2025-03-18T04:22:29+00:00\",\"dateModified\":\"2025-04-05T11:23:50+00:00\",\"description\":\"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/feature-image.jpeg\",\"contentUrl\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/feature-image.jpeg\",\"width\":1600,\"height\":900},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/how-docker-managed-its-image-layers\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Docker\",\"item\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/category\\\/docker\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"How docker manages its image layers?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/\",\"name\":\"Blog | Liainfraservices\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#organization\",\"name\":\"Blog | Liainfraservices\",\"url\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2021\\\/10\\\/lia-logo-b-e1635340384244.png\",\"contentUrl\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/wp-content\\\/uploads\\\/2021\\\/10\\\/lia-logo-b-e1635340384244.png\",\"width\":308,\"height\":96,\"caption\":\"Blog | Liainfraservices\"},\"image\":{\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.liainfraservices.com\\\/blog\\\/#\\\/schema\\\/person\\\/b5a729cb152dd3bc7f07550ca9d223e4\",\"name\":\"Partho\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g\",\"caption\":\"Partho\"},\"description\":\"Partho Das, founder of Lia Infraservices, has 15+ years of expertise in cloud solutions, DevOps, and infrastructure security. He provides consultation on architecture planning, DevOps setup, Kubernetes, and cloud migrations. Partho holds multiple AWS and Azure certifications, along with CISCO CCNA &amp; CCNP. Connect on LinkedIn\",\"sameAs\":[\"https:\\\/\\\/www.linkedin.com\\\/in\\\/partho-dev\\\/\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How docker manages its image layers? - Blog | Liainfraservices","description":"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/","og_locale":"en_US","og_type":"article","og_title":"How docker manages its image layers? - Blog | Liainfraservices","og_description":"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers","og_url":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/","og_site_name":"Blog | Liainfraservices","article_published_time":"2025-03-18T04:22:29+00:00","article_modified_time":"2025-04-05T11:23:50+00:00","og_image":[{"width":1600,"height":900,"url":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg","type":"image\/jpeg"}],"author":"Partho","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Partho","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#article","isPartOf":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/"},"author":{"name":"Partho","@id":"https:\/\/www.liainfraservices.com\/blog\/#\/schema\/person\/b5a729cb152dd3bc7f07550ca9d223e4"},"headline":"How docker manages its image layers?","datePublished":"2025-03-18T04:22:29+00:00","dateModified":"2025-04-05T11:23:50+00:00","mainEntityOfPage":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/"},"wordCount":1053,"commentCount":0,"publisher":{"@id":"https:\/\/www.liainfraservices.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#primaryimage"},"thumbnailUrl":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg","articleSection":["Docker"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/","url":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/","name":"How docker manages its image layers? - Blog | Liainfraservices","isPartOf":{"@id":"https:\/\/www.liainfraservices.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#primaryimage"},"image":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#primaryimage"},"thumbnailUrl":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg","datePublished":"2025-03-18T04:22:29+00:00","dateModified":"2025-04-05T11:23:50+00:00","description":"Docker image layer, how docker manages its image layers, Docker image layer tutorial, docker layers","breadcrumb":{"@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#primaryimage","url":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg","contentUrl":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2025\/03\/feature-image.jpeg","width":1600,"height":900},{"@type":"BreadcrumbList","@id":"https:\/\/www.liainfraservices.com\/blog\/how-docker-managed-its-image-layers\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.liainfraservices.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Docker","item":"https:\/\/www.liainfraservices.com\/blog\/category\/docker\/"},{"@type":"ListItem","position":3,"name":"How docker manages its image layers?"}]},{"@type":"WebSite","@id":"https:\/\/www.liainfraservices.com\/blog\/#website","url":"https:\/\/www.liainfraservices.com\/blog\/","name":"Blog | Liainfraservices","description":"","publisher":{"@id":"https:\/\/www.liainfraservices.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.liainfraservices.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.liainfraservices.com\/blog\/#organization","name":"Blog | Liainfraservices","url":"https:\/\/www.liainfraservices.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.liainfraservices.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2021\/10\/lia-logo-b-e1635340384244.png","contentUrl":"https:\/\/www.liainfraservices.com\/blog\/wp-content\/uploads\/2021\/10\/lia-logo-b-e1635340384244.png","width":308,"height":96,"caption":"Blog | Liainfraservices"},"image":{"@id":"https:\/\/www.liainfraservices.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.liainfraservices.com\/blog\/#\/schema\/person\/b5a729cb152dd3bc7f07550ca9d223e4","name":"Partho","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/6c5fc8918cc5dbc844eccbeaaf854eef27d2c79ab17ff0022304f712805d6959?s=96&d=mm&r=g","caption":"Partho"},"description":"Partho Das, founder of Lia Infraservices, has 15+ years of expertise in cloud solutions, DevOps, and infrastructure security. He provides consultation on architecture planning, DevOps setup, Kubernetes, and cloud migrations. Partho holds multiple AWS and Azure certifications, along with CISCO CCNA &amp; CCNP. Connect on LinkedIn","sameAs":["https:\/\/www.linkedin.com\/in\/partho-dev\/"]}]}},"_links":{"self":[{"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/posts\/5308","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/comments?post=5308"}],"version-history":[{"count":4,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/posts\/5308\/revisions"}],"predecessor-version":[{"id":5336,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/posts\/5308\/revisions\/5336"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/media\/5318"}],"wp:attachment":[{"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/media?parent=5308"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/categories?post=5308"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.liainfraservices.com\/blog\/wp-json\/wp\/v2\/tags?post=5308"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}