You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What happened:
When creating an ingress with exactly 46 character long hostname, the ingress controller logs an error message:
2020/01/31 10:47:48 [emerg] 4436#4436: could not build server_names_hash, you should increase server_names_hash_bucket_size: 64
nginx: [emerg] could not build server_names_hash, you should increase server_names_hash_bucket_size: 64
nginx: configuration file /tmp/nginx-cfg525869296 test failed
This only happens, when the longest host-name of all ingress rules in the cluster have 46 characters.
What you expected to happen:
Ingress deployment works and nginx-ingress-controller does not throw an error message.
I assume, that the server_names_hash_bucket_size calculation algorithm calculates a wrong size on edge cases of server-name-lengths. One example for this edge case is the length of 46, see tests of 322be61
How to reproduce it:
Precondition: running kubernetes cluster and an installed ingress-controller
The issue here is nginx.ingress.kubernetes.io/from-to-www-redirect: "true" because the new hostname www.01234567891234567890123456789012345678.test.de is not taken into account in the call to nginxHashBucketSize.
NGINX Ingress controller version: 0.24.1
complete image url:
quay.io/kubernetes-ingress-controller/nginx-ingress-controller:0.24.1
Kubernetes version (use
kubectl version
):What happened:
When creating an ingress with exactly 46 character long hostname, the ingress controller logs an error message:
This only happens, when the longest host-name of all ingress rules in the cluster have 46 characters.
What you expected to happen:
Ingress deployment works and nginx-ingress-controller does not throw an error message.
I assume, that the server_names_hash_bucket_size calculation algorithm calculates a wrong size on edge cases of server-name-lengths. One example for this edge case is the length of 46, see tests of 322be61
How to reproduce it:
Precondition: running kubernetes cluster and an installed ingress-controller
create a default http backend
create a test-ingress
test-ingress has a host with exact 46 characters
Anything else we need to know:
A workaround for that is to configure the ingress controller via configMap described at nginxinc/kubernetes-ingress#34 (comment)
/kind bug
The text was updated successfully, but these errors were encountered: