Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just updated nginx to 0.8.50 (as provided by the nginx development PPA), but now I'm facing a problem. I can't restart my server anymore, as it says 'Testing nginx configuration: [emerg]: could not build the types_hash, you should increase either types_hash_max_size: 1024 or types_hash_bucket_size: 32'. The thing is, it worked perfectly fine before. I don't know what could have triggered the error.

What I tried:

  • Increasing the types_hash_bucket_size/types_hash_max_size values, I'm currently using server_names_hash_bucket_size 512; server_names_hash_max_size 2048, which should be more than enough for my (max) 20 vhosts. But when running config test, the problem persists.
  • Also, I tried disabling some of my vhosts. When I disable them all, the problem is gone. When I load one the problem is there, it does not matter which config I try.

My Config:

I hope someone can help me out here, I'm quite lost.

share|improve this question
up vote 5 down vote accepted

So, this was really stupid. Since I couldn't find anything about types_hash_bucket_size / types_hash_max_size in the docs, I figured the variable names where wrong and should be server_names_hash_bucket_size / server_names_hash_max_size, which are mentioned in the wiki. I was wrong, the variable names where right, and after increasing them everything went back to normal.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.