kaniko: chown: Value too large for defined data type
Kaniko build fails (randomly) with Value too large for defined data type
Dockerfile snippet:
FROM <repo>ubuntu:latest
WORKDIR /opt/docker
ADD opt /opt
RUN ["chown", "-R", "test_nobody:test_nobody", "."]
Build error :
INFO[0021] Taking snapshot of files...
INFO[0023] RUN ["chown", "-R", "test_nobody:test_nobody", "."]
INFO[0023] cmd: chown
INFO[0023] args: [-R test_nobody:test_nobody .]
chown: .: Value too large for defined data type
error building image: error building stage: waiting for process to exit: exit status 1
Kaniko : gcr.io/kaniko-project/executor:debug Build Env: Jenkins - Kubernetes
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 21
- Comments: 23 (10 by maintainers)
Currently using kaniko is a bit unfortunately, because it still failes most builds (for us) on k8s clusters.
The reason as above written is a broken busybox/uclibc coming from distroless (which is i686 and breaks on hitting 64bit inodes)
The fix for us was to just add an additional layer over
gcr.io/kaniko-project/executor:debuglikeWould be nice if this problem could finally be fixed after so many months.
Meanwhile I’ve build an Alpine Linux image with kaniko that works quite well.
Maybe this might help you, too.
https://gitlab.com/griffinplus/gitlab-kaniko
EDIT: If you use
/kaniko/executorinstead of thekaniko-buildwrapper, the image behaves just the same as the original image.Ran into this issue trying to build images with kaniko in a GitLab managed EKS Kubernetes cluster.
https://gitlab.com/griffinplus/gitlab-kaniko did not work, since it does not seem to have the amazon-ecr-credential-helper embedded and I do need to push to AWS ECR.
The quick and easy workaround from @gebi did the trick. Thanks @gebi!
I’ve implemented it here https://github.com/lmakarov/kaniko and using
lmakarov/kanikoas the build image in GitLab for the time being.Does anyone have a somewhat similar issue in GKE cluster where the build goes through but the image build misses chown-ing a folder ? Im referring to #1079
i have the same issue 😦 kaniko 0.12.0, gke 1.14.3
have to build my own kaniko build…
UPDATE: custom kaniko image doesn’t resolve the issue. I have to use bare metal k8s cluster, kaniko doesn’t work in GKE 😦((