Repository navigation
[KUBE-APISERVER] Error from server (RequestEntityTooLarge Request entity too large: limit is 3145728 #105863
Description
What happened?
I'm trying to push a large .yaml file (over 3 MB, less than 4 MB) with kubectl.
kubectl apply -f viya4-sasdeployment.yaml -n sasoperator
In response I've got :
Error from server (RequestEntityTooLarge): error when creating "viya4-sasdeployment.yaml": Request entity too large: limit is 3145728
To get proper debug I've done this with verbosity level 7 do determine what service is a bottleneck.
root@vmkub01:/home/gabos# kubectl apply -f viya4-sasdeployment.yaml -n sasoperator -v 7
I1024 15:26:54.488727 3449581 loader.go:372] Config loaded from file: /root/.kube/config
I1024 15:26:54.490443 3449581 round_trippers.go:432] GET https://10.0.110.99:6443/openapi/v2?timeout=32s
I1024 15:26:54.490463 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:54.490481 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:54.490494 3449581 round_trippers.go:442] Accept: application/[email protected]+protobuf
I1024 15:26:54.543938 3449581 round_trippers.go:457] Response Status: 200 OK in 53 milliseconds
I1024 15:26:55.184873 3449581 round_trippers.go:432] GET https://10.0.110.99:6443/api/v1/namespaces/sasoperator/secrets/sas-viya
I1024 15:26:55.186073 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:55.186107 3449581 round_trippers.go:442] Accept: application/json
I1024 15:26:55.186140 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:55.191114 3449581 round_trippers.go:457] Response Status: 200 OK in 4 milliseconds
I1024 15:26:55.198460 3449581 round_trippers.go:432] PATCH https://10.0.110.99:6443/api/v1/namespaces/sasoperator/secrets/sas-viya?fieldManager=kubectl-client-side-apply
I1024 15:26:55.198511 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:55.198539 3449581 round_trippers.go:442] Accept: application/json
I1024 15:26:55.198562 3449581 round_trippers.go:442] Content-Type: application/strategic-merge-patch+json
I1024 15:26:55.198585 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:55.208301 3449581 round_trippers.go:457] Response Status: 200 OK in 9 milliseconds
I1024 15:26:55.260091 3449581 round_trippers.go:432] GET https://10.0.110.99:6443/apis/orchestration.sas.com/v1alpha1/namespaces/sasoperator/sasdeployments/sas-viya
I1024 15:26:55.260157 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:55.260193 3449581 round_trippers.go:442] Accept: application/json
I1024 15:26:55.260206 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:55.267102 3449581 round_trippers.go:457] Response Status: 404 Not Found in 6 milliseconds
I1024 15:26:55.267538 3449581 round_trippers.go:432] GET https://10.0.110.99:6443/api/v1/namespaces/sasoperator
I1024 15:26:55.267555 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:55.267564 3449581 round_trippers.go:442] Accept: application/json
I1024 15:26:55.267573 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:55.270827 3449581 round_trippers.go:457] Response Status: 200 OK in 3 milliseconds
I1024 15:26:55.331689 3449581 round_trippers.go:432] POST https://10.0.110.99:6443/apis/orchestration.sas.com/v1alpha1/namespaces/sasoperator/sasdeployments?fieldManager=kubectl-client-side-apply
I1024 15:26:55.331778 3449581 round_trippers.go:438] Request Headers:
I1024 15:26:55.331790 3449581 round_trippers.go:442] Accept: application/json
I1024 15:26:55.331808 3449581 round_trippers.go:442] Content-Type: application/json
I1024 15:26:55.331835 3449581 round_trippers.go:442] User-Agent: kubectl/v1.21.5 (linux/amd64) kubernetes/aea7bba
I1024 15:26:55.347992 3449581 round_trippers.go:457] Response Status: 413 Request Entity Too Large in 16 milliseconds
I1024 15:26:55.348328 3449581 helpers.go:216] server response object: [{
"kind": "Status",
"apiVersion": "v1",
"metadata": {},
"status": "Failure",
"message": "error when creating "viya4-sasdeployment.yaml": Request entity too large: limit is 3145728",
"reason": "RequestEntityTooLarge",
"code": 413
}]
F1024 15:26:55.348394 3449581 helpers.go:115] Error from server (RequestEntityTooLarge): error when creating "viya4-sasdeployment.yaml": Request entity too large: limit is 3145728
In my opinion the limit is hardcoded and I cannot change this.
As you can probably see, I'm trying to push a SAS Viya 4 deployment which generates files over 3 MB.
There is no way to split the file in smaller ones, there are 2 main sections "secret" and "deployment"
Secret is about 4-5 KB.
Is there any workaround ?
What did you expect to happen?
To allow apply files bigger than 3 MB
How can we reproduce it (as minimally and precisely as possible)?
Try to push random .yaml file with size 3MB + via kubectl
Anything else we need to know?
No response
Kubernetes version
Details
$ kubectl version
Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.5", GitCommit:"aea7bbadd2fc0cd689de94a54e5b7b758869d691", GitTreeState:"clean", BuildDate:"2021-09-15T21:10:45Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.5", GitCommit:"aea7bbadd2fc0cd689de94a54e5b7b758869d691", GitTreeState:"clean", BuildDate:"2021-09-15T21:04:16Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"}
Cloud provider
Details
Self-Hosted Ubuntu 20.04 LTSOS version
Details
# On Linux:
$ cat /etc/os-release
# paste output here
$ uname -a
# paste output here
# On Windows:
C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture
# paste output here
Activity
neolit123 commentedon Oct 24, 2021
this is by design and not a bug. the limit is hardcoded i don't think there are any plans to increase it or make it configurable.
/kind feature
/remove-kind bug
/sig api-machinery
n2243 commentedon Oct 24, 2021
Sorry, 1st time on github :|
caesarxuchao commentedon Oct 26, 2021
+1 to @neolit123 's comment.
/triage accepted
k8s-triage-robot commentedon Jan 24, 2022
The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.
This bot triages issues and PRs according to the following rules:
lifecycle/staleis appliedlifecycle/stalewas applied,lifecycle/rottenis appliedlifecycle/rottenwas applied, the issue is closedYou can:
/remove-lifecycle stale/lifecycle rotten/closePlease send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle stale
k8s-triage-robot commentedon Feb 23, 2022
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.
This bot triages issues and PRs according to the following rules:
lifecycle/staleis appliedlifecycle/stalewas applied,lifecycle/rottenis appliedlifecycle/rottenwas applied, the issue is closedYou can:
/remove-lifecycle rotten/closePlease send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle rotten
k8s-triage-robot commentedon Mar 25, 2022
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.
This bot triages issues and PRs according to the following rules:
lifecycle/staleis appliedlifecycle/stalewas applied,lifecycle/rottenis appliedlifecycle/rottenwas applied, the issue is closedYou can:
/reopen/remove-lifecycle rottenPlease send feedback to sig-contributor-experience at kubernetes/community.
/close
k8s-ci-robot commentedon Mar 25, 2022
@k8s-triage-robot: Closing this issue.
Details
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
MotaOcimar commentedon Dec 7, 2023
I'm facing the same thing and, although regarding the configmaps size limitation I found something documented, I didn't find anything documented about the other Kuberntes yaml manifests.
So is this documented somewhere? And what would be the source cause of this limitation?
MotaOcimar commentedon Dec 8, 2023
As Adam Acosta answered on slack:
Thank you Adam Acosta.
Thanks also to @mrbobbytables for replying on the community forum.