Hello!
On Sun, Jan 12, 2014 at 11:19 AM, develephant.net wrote:
> I am installing the latest release 1.5.8.1 and I am getting the following
> error when launching:
>
> nginx: [emerg] could not build the types_hash, you should increase either
> types_hash_max_size: 1024 or types_hash_bucket_size: 32
>
Oh, your CPU cache line size is detected (by the nginx core) to be
really small, 32 bytes, so the default types_hash_max_size can easily
get exceeded.
> I do not receive this error with the last version; 1.4.3.6
>
I think this is because the standard nginx 1.5.8 core adds more
entries to its mime.types file (86 entries vs 80 entries in nginx
1.4.3). That should be why you did not exceed the limit when using
ngx_openresty 1.4.3.6 (with nginx 1.4.3 bundled).
Will you test the standard nginx 1.5.8 source distribution on your
side to confirm this? See
http://nginx.org/
If it is indeed the case, maybe you can write to the nginx mailing
list and ask the nginx team to raise the default limit for
types_hash_max_size?
I'm not sure if we should patch the nginx core to raise the default
types_hash_max_size setting in openresty :)
> Any recommendations on what I should be setting this "types_hash_max_size"
> or how to make it work like the last version?
>
Increasing types_hash_max_size is the recommended approach. See
http://nginx.org/en/docs/hash.html
Thanks for the report!
Best regards,
-agentzh