-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
max depth exceeded #414
Comments
The overlay2 storage driver can at maximum have 125 layers, so I suspect that that's what you're running into (error message is defined here; https://github.com/moby/moby/blob/8e610b2b55bfd1bfa9436ab110d311f5e8a74dcb/layer/layer.go#L53) First of all, I would recommend trying to optimize your images / Dockerfile, as mounting this many layers can affect performance (it will take longer to start the container, as all layers have to be mounted, and modifying files inside the container may be less performant) We should document this though, and (if possible) make the error message more clear. / cc @dmcgowan @ahh-docker |
Yes, would be good if the error is documented and explained why. I could have one script as well installing and set everything in 10 steps, instead of 125 layers, but layers have cache and etc.. are more useful. I find this 125 layer limitation stupid, maybe because I don't understand it and it is not documented |
@thaJeztah can you please file me at documentation issue for this in docker.github.io? Thanks. |
@thaJeztah I was not aware of that drawback. |
It's the total amount of layers; note that not every step in a Dockerfile creates a new layer, only ( If I'm not mistaken, the current limit of 125 layers is due to the kernel's |
Thanks. My question was more about the performance impact at runtime. Do you have references about that? |
if it is the case, about the performance impact, I really think now it became a bad design. |
1 |
I feel, this arbitrary restriction based on kernel restrictions should be re-evaluated as incompatible kernels will become less and less prevalent. I mean, from a naive perspective, a list of arguments should almost always be replaceable by a temp file or even a named pipe, where the arguments are pushed through separated by zero-bytes. Naively, I don't know the first thing about docker internals. |
Expected behavior
Build image
Actual behavior
Error
max depth exceeded
Steps to reproduce the behavior
I am building an image, which inherits from another image, which inherits from a third image. I get this error, which is not documented at all? Is there any documentation / info about this?
Output of
docker version
:Output of
docker info
:The text was updated successfully, but these errors were encountered: