I'm getting a "request header too large" error on my application after installing Istio. Can the additional headers added by Istio be too large?
Asked
Active
Viewed 971 times
1 Answers
2
Requests coming to your Pod
are handled by Envoy
(with a sidecar). You could try to modify it's configuration to support bigger headers.
There is a Github issue that could be your starting point:
Hi all, in case it helps, with Istio 1.5, this works:
$ cat envoyfilter3.yaml
apiVersion: networking.istio.io/v1alpha3 kind: EnvoyFilter metadata: name: hcm-tweaks namespace: istio-system spec: configPatches: - applyTo: NETWORK_FILTER # http connection manager is a filter in Envoy match: context: GATEWAY listener: filterChain: filter: name: "envoy.http_connection_manager" patch: operation: MERGE value: typed_config: "@type": "type.googleapis.com/envoy.config.filter.network.http_connection_manager.v2.HttpConnectionManager" xff_num_trusted_hops: 5 max_request_headers_kb: 90
Main difference versus the doc: removed WorkloadSelector, removed sni, added type_config."@type"
Please remember that this is a working example on Istio
version 1.5
. You'll need to modify in accordance with the Istio release notes.
Additional resources:

Dawid Kruk
- 8,982
- 2
- 22
- 45
-
Thanks for the solution @Dawid Kruk . Could it possible that the headers added by Istio were so big that it caused this issue? – RMNull Feb 10 '21 at 10:55
-
Without more information about your infrastructure/your application/your `Istio` configuration it could be hard to pinpoint the actual issue. I would rather go a way that your application is sending too big headers. – Dawid Kruk Feb 11 '21 at 12:58